News:

  • December 05, 2024, 04:43:24 AM

Login with username, password and session length

Author Topic: BARCODE READING THRU fo-CP128 MODULE  (Read 3346 times)

JBYERS

  • Newbie
  • *
  • Posts: 2
BARCODE READING THRU fo-CP128 MODULE
« on: December 10, 2009, 03:42:49 PM »
I am reading 2 barcodes thru a focp128 module the information is being written to 2 different v memory locations I need to verify the barcodes match but only a select portion of the barcode, the ANSII format stored in V-mem only allows me to verify pairs of numbers and I may need to verify on an odd character start position in the barcode string, i tried splitting the code with OutL and OutM instructions this did not work consistently and would require lots of code, and the code length is variable, any suggestions greatly appreciated.

b_carlton

  • Internal Dev
  • Hero Member
  • ****
  • Posts: 606
    • thePLCguy
Re: BARCODE READING THRU fo-CP128 MODULE
« Reply #1 on: December 10, 2009, 03:52:36 PM »
You might think about performing the matching tests in the BASIC module. Its string handling capabilities are much greater. Then pass a Go/No-Go signal back to the CPU. If you are matching against a number of possibilities you could also pass a number corresponding to which item matches. You will still have some complex code, but that's the price for a complex operation.
An output is a PLC's way of getting its inputs to change.

Controls Guy

  • Internal Dev
  • Hero Member
  • ****
  • Posts: 3581
  • Darth Ladder
Re: BARCODE READING THRU fo-CP128 MODULE
« Reply #2 on: December 10, 2009, 05:28:45 PM »
I agree with Bernie.  Dealing with string in ladder is a pain, especially if there's a basic module available.  That's a much better way to go.
I retract my earlier statement that half of all politicians are crooks.  Half of all politicians are NOT crooks.  There.

JBYERS

  • Newbie
  • *
  • Posts: 2
Re: BARCODE READING THRU fo-CP128 MODULE
« Reply #3 on: December 11, 2009, 07:22:36 AM »
I am very new to the basic module is there a good resource for learning the programing basics, I generally poke around with the Directsoft ladderlogic to solve problems in existing programs and eventually find solutions by trial and error, this has led me to creating new systems and each scenario seems to get more complex.
thanks again.