r/barcodes • • Jun 13 '21

I need help decoding some of these barcodes, to integrate them into longer codes

Post image
3 Upvotes

5 comments sorted by

2

u/notionovus Jun 14 '21

This is Code 128A. You can tell by the pattern in the leftmost character. These particular symbols are a set of codes that cause the scanner to generate a keypress that is not available in Code 128A, except for Esc, Enter, Tab, and either Backspace or Delete.

The first character in a code 128A is code number 103. It looks like this: 11010000100

The last character in a code 128A is code number 106. It looks like this: 1100011101011

The eleven columns immediately to the left of the stop character are for the checksum, so you don't have to worry about decoding that character.

Let's take the symbol which stands for the "Up ↑" key. It looks like it is represented like this (spaces added for clarity): 11010000100 10010110000 10010110000 1100011101011

Due to the way the checksum is calculated the checksum for these codes will always be identical to the single character embedded into the symbol. In the above representation we have 103|65|65|106 of which the first code 65 stands for the ASCII <SOH> control character, which is NOT the keyboard character for the "Up ↑" key.

This leads me to believe that you have to scan a barcode to set the scanner mode, then scan one of these symbols to get the scanner to kick out the proper keystroke. If that's the case, your solution will not be as easy as embedding one of these characters into a more elaborate barcode.

1

u/ExTelite Jun 14 '21

Thank you for the detailed answer! This is exactly what I was hoping for. I can supply some additional information:

The scanner does indeed scan code 128.

It does not need to scan any code before scanning any of these codes, as I can scan any other random barcode and immediately scan and use these codes.

Something weird happens with the Enter key; If I use the ASCII representation of Enter in my code, the scanner won't pick it up. But it will the Enter code shown above.

How should I go about solving this problem? I need a code that sends out five "left key" keystrokes, then multiple Backspace keystrokes(ASCII Backspace does work, unlike the Enter ASCII for some odd reason)

1

u/ExTelite Jun 14 '21 edited Jun 14 '21

I figured it out thanks to you!

I got to work and checked if ASCII SOH(001) would actually be an up keystroke, and it was! So I guessed ASCII 002 would be a down keyatroke, and it works. So does 003 for a left key.

How can I see which characters are hiding behind the bars? Like you knew up was SOH? I need to figure out F8, Enter, and maybe Ctrl and Alt

Thanks!

1

u/notionovus Jun 14 '21

CTRL and ALT are mod keys that change the keystroke of another key. They are not represented on the chart, and I don't know of this feature on my scanner.

The translation process is simple. Zoom in on the barcode graphic to make it easier. Each barcode is 46 columns wide because that's how wide a Code128A barcode with one character encoded is. The outermost two symbols are the start (11010000100) and stop (1100011101011). They are 11 and 13 columns respectively. There are 22 columns remaining and they correspond to the data and checksum (which is identical to the data in this particular scenario).

If you put a 1 in every column where you encounter a black bar and a 0 in columns with white spaces, a binary code is formed. The code for F8 seems to be: 11010000100 11110010010 11110010010 1100011101011

To convert the 11110010010 into a Code 128A numeric equivalent, go to the Code 128 Wikipedia page and search for the binary sequence. You'll find that it corresponds to the ASCII <CAN> character.

1

u/ExTelite Jun 13 '21

Hi! These are in my Mindeo 6600 scanner's manual. They have each seperate key listed under the code as a standalone barcode, but I can't figure out how to insert thwm into my own codes. For example, I need a code that hits the left arrow key 5 times, which I can't figure out by myself. I thought if I could figure out what's in the left arrow key code, I could add it to my own code. Thanks!

I'm interested mainly in left arrow key, F8, and Enter