Comparing Barcode bits to HMI

Big_Robo

Member
Join Date
Nov 2016
Location
England
Posts
81
Hello,

Im here to ask all you well learned professionals a few questions which im struggling with. Im a noob and trying to learn all i can.

I have programmed a barcode scanner which scan and puts the result into 12bits in a DB. I want the sum of all 12 bits to get a final number. How do i go about doing that (in LAD would be a benefit)


Thankyou.
 
What model of controller are you using ?

When you say "DB", do you mean a "database" or do you mean a Siemens "data block" ?

What is the address format of the field or element in which your data is stored ?

This might be as simple as a series of "ADD" instructions or a datatype conversion.
 
AHello sorry I didn't know what info was needed

It is stored in a Siemens Data Block.

I'm recieving ASCII code from scanner and putting that into a Data Block that transfering that into another block in 12bits

IMG_20180110_143434.jpg
 
Last edited:
Can you describe what your desired out come is?

You are currently reading 12 BYTES (not bits) of data. This DATA is ASCII (Char).

Are you looking to sum up the BYTE values as if they Integers? I don't see why you would need to do this.

Or are you looking to take the ascii chars that spell out somethign like "PR00:1033713B" and concatenate it into a string?
 
Hi Rob, assume this is related to your other thread of getting a Keyence SR1000 talking to an S7-300? Please clarify if not.

As well as there being sample AutoID file on barcodereader.oom there should be sample siemens files... are you using that?

I can post LAD but it will be in AB, but you can see what conversion is needed.
 
Hello, thankyou for the responses I am sorry I'm really a noon to this stuff.

Yes I want the 12 bytes to read some like pro: 10086479 so I can then compare that to a similar string number in the HMI.
I've had no luck with the keyence examples.
 

Similar Topics

I’m running a micro 820 to measure a tank level, then turning on equipment at certain levels. I have an analog input (4-20) that I’m storing and...
Replies
10
Views
269
How do you go about implementing, on the M580 PLC, how many days, hours, minutes before a predefine event in the future? The RRTC_DT yields the...
Replies
3
Views
1,804
This is a Citect SCADA question I have Six variables of type REAL (Float) to compare and determine (identify) which variable has the highest...
Replies
4
Views
1,406
I have currently made a logic to read Serial input from a barcode scanner. The situation is that I need to read the barcode from the machine and...
Replies
5
Views
2,036
Hello, We are using Schneider SCADAPack 357 and Trimble Acutime 2000GPS. We are getting the data as a string(ASCII) from...
Replies
3
Views
1,470
Back
Top Bottom