Electronic – Barcode Scanner to Arduino/Interfacing

barcodeinterface

I've got an old barcode scanner that I've decided that I want to connect to an Arduino Uno(for the purposes of wireless transmission). After poking around I've found some information that states that basically it should act like an old AT Keyboard. I haven't even gotten to the coding part of it, but my findings with a scope are providing me what I think are garbage waveforms. This uses the old DIN5 connector, which has clock and data lines.

I have:
Vcc – 5V
Gnd – gnd
clock – 2(on attached scope waveform)
data – 1

This is the waveform I get on scanning. Otherwise they both hold at 5V.
waveform1

From my understanding, the clock line is supposed to, well, be a clock!

I have looked at the following resources trying to figure this out.
http://www.hardwarebook.info/AT_Keyboard/Mouse_protocol
http://retired.beyondlogic.org/keyboard/keybrd.htm
I can't seem to find anything for the particular model of scanner I have (Unitech MS283). There exist no manuals online that I can find.

I guess the question here is; is there any sort of circuit that I'd need, or some control from the PC that's missing in my testing? And if this does turn out to be the actual signal, where should I look for programming for this?

Thanks in advance for the help.

Best Answer

Clock and data are open-drain on the old AT keyboards. Put some pullup resistors (like 4K7 on each) and have another go at it.

Okay, given that you actually had the resistors, how about that 5kSa/s on your scope waveform. I'd expect to see more like 1Gsps on a proper scope.

Those angled lines are just the scope connecting the dots with really horrible horizontal resolution.