Example of scanned barcode result

LK/ELK/VK/PK/OK/MX/GLK/EGLK/GVK/GLT Series

Moderators: Henry, Mods

Post Reply
zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Example of scanned barcode result

Post by zigzak »

Not sure how well this will come out - but if I scan a barcode with the following number in it "5018677033943" I get the result in my comms program "5
Regards,
David Spink
www.zigzak.co.uk

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

OK, having tried very hard to get this barcode thing to work I've now managed to capture the "keycodes" generated when a barcode is scanned. The unit is returning a consistent list of codes so there must be a connection.

The barcode number is 5018677033943
The actual keycodes returned are (in decimal): 43, 153, 102, 116, 100, 134, 48, 101, 104, 59, 101, 118, 150.

As you can see this IS the correct number of codes, but they just don't seem to correspond to the numbers I would expected to have been "typed". The barcodes has three 3's in it - but a different code is returned for each occurance - namely 104, 59, and finally 150.

This is driving me bonkers!!!
Regards,
David Spink
www.zigzak.co.uk

bladerunner
LCD!
Posts: 10
Joined: Tue Oct 15, 2002 10:19 pm

Post by bladerunner »

Not my area of expertise, but IIRC, on a standard PC, the keyboard returns "scan codes" and the BIOS then converts them to "key codes". Scan codes are simple for things like alpha keys, but more complex for the "F" keys. There is one scan code when a key is pressed and another when it is released.

Here is a reference: http://www.beyondlogic.org/keyboard/keybrd.htm

My guess is that the LCD is interpreting your scanner data as "scan codes" and then doing its best to convert them into key codes.

Maybe.

If you hook your scanner into a regular PC (with none of the "scanner" software loaded) and put the focus in note pad, and scan a barcode, does it work then, even if no "scanner" software at all is loaded on the PC? I am thinking that maybe on the PC there is a driver loaded that does some conversion from scan codes to alpha.

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

Hi Bladerrunner - thanks very much for your comments.

To answer the question - yes, if I connect the scanner to a normal PC and then scan the barcode with the focus on Word or Notepad then the characters of the barcode are "typed" into the application. There is no driver loaded or required for this.

The details of the actual scanner I'm using is here - http://www.ganedatascan.com/specs/1000.asp
Regards,
David Spink
www.zigzak.co.uk

bladerunner
LCD!
Posts: 10
Joined: Tue Oct 15, 2002 10:19 pm

Post by bladerunner »

Hmm. I dono then. Must be the LCD doing some weird stuff. What else is in the system besides the LCD and scanner? Why not just get a USB or RS232 scanner and have the scanner data stream bypass the LCD?

Mat-Moo
LCD Guru
Posts: 502
Joined: Wed Jan 16, 2002 4:00 pm
Contact:

Post by Mat-Moo »

I would guess that the scanner is sending data too fast to the LCD. What speed are you connecting to the lcd at 19200? You could also try manually polling the keyboard by clearing and polling it? Also check what the scanner sens as some will emulate a keyboard (key up and key down) rather than raw data of the values read. Most scanners are configurable (I've worked with a few and have a LK404 here, if you have a spare scanner I can take a look)
## # Mat # ##
LCDC - Drive it to the edge baby!
http://www.lcdc.cc
Matthew@DPS.uk.com
DPS Ltd. (Not MO!)

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

Hi guys,
Thanks for all the postive comments!

Bladerunner - the reason I want the keyboard and LCD combined into one input into the PC is because I eventually want 1 PC to control possibily 4 screens/keyboard/barcode scanners at one time. I'm working on a system to control jobs in a workshop and want an LCD Display, Keyboard, and scanner on each desk. I had considered the option of seperate keyboard connections but this would get complicated for multiple USB keyboards as they would all appear as Human Interface Devices - another option would then be some kind of serial connected keyboard - but one of the main ideas was to use as standard parts as possible.

mat - I'm connecting, I think, at 19200 but I'd need to check - The actual connection to the PC is via a USB port as I'm using a USB/Serial converter on the end of the LCD serial lead. I have messed around with the settings for the scanner until I'm blue in the face to be honest - I've tried adjusting the inter-character delay, and keyboard "region", etc. I do have a spare scanner as we have 5 or 6 of them which are already used for an older system directly via PC keyboard sockets which works great!
Regards,
David Spink
www.zigzak.co.uk

bladerunner
LCD!
Posts: 10
Joined: Tue Oct 15, 2002 10:19 pm

Post by bladerunner »

I wonder if you could get something like this to work in conjunction with a simpler LCD module:

http://www.solutions-cubed.com/solution ... EY2003.htm

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

Hi Bladerunner,

That looks pretty good - thanks for the pointer. However on first look it doesn't seem to support a full PC keyboard - which is what I need. I'll have a look at all the various info. they seem to have on that site.

Thanks again
Regards,
David Spink
www.zigzak.co.uk

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

Still have not resolved my barcode input problems - however the link I'm enclosing include details of interfacing a PS/2 Keyboard, and LCD directly with a single PC Serial port for use as a "terminal" - which is exactly what I'm trying to do.

The module the page describes actually seems pretty similar to MO's LK404-AT only the display is only 2 lines instead of 4. However there are very detailed instructions of exactly how the module was made including a list of parts to build your own!

Hope MO don't mind me posting this link - but since you've discontinued your only AT-Keyboard interface module it shouldn't be a problem?

http://www.ezl.com/~rsch/projects.htm
Regards,
David Spink
www.zigzak.co.uk

zigzak
LCD!
Posts: 15
Joined: Sat Jan 15, 2005 3:18 pm
Location: Scotland, UK.
Contact:

Post by zigzak »

Just thought I'd post to say that I seem to have solved my barcode scanning problems.

I tried another make of barcode scanner and it all worked perfectly. The scanner which worked is a Unitech MS-265-1, the scanner which doesn't work is a CipherLabs 1000-K for the record.

Thanks for all the suggestions, etc.
Regards,
David Spink
www.zigzak.co.uk

Mat-Moo
LCD Guru
Posts: 502
Joined: Wed Jan 16, 2002 4:00 pm
Contact:

Post by Mat-Moo »

Sorry I didn't get to help much, been kinda busy :(
## # Mat # ##
LCDC - Drive it to the edge baby!
http://www.lcdc.cc
Matthew@DPS.uk.com
DPS Ltd. (Not MO!)

Post Reply