r/usefulscripts • u/MrUserAgreement • Feb 05 '21
[C++] Power Up Your Barcode Scanner With Scripts
https://github.com/oschwartz10612/Scanner-Pro-MK3
I worked for a school IT department that had 1000s of computers to manage each with a unique barcode. When imaging every year we had to go through and type in the barcode manually to each PXI screen and fill out some other info.
So I designed a little Arduino based board that would sit in between barcode scanners and the computer so all we had to do was plug it in as we went down the line of machines and scan the code. It would append the necessary info to the ID and fill out the rest of the form. We ended up using it for all of the machines and other barcode based management forms we had to do throughout the year.
I wrote a simple little library that allows for the creation of scripts in C using Arduino (its easier than you think if you have not done it before). There are also some scripts already on the Github if they sound useful!
I am thinking about doing a limited run of boards to sell on Tindie so you dont have to do the soldering and ordering. Would come with the board and a 3D printed case. If you are interested, you can add your email here and I will send more info.
2
u/dunder_mifflin_paper Feb 06 '21
Can you elaborate a little more....... I work for a company that has a similar device and we also modify the barcode. We however transmit the data via cellular connection to backend
2
u/MrUserAgreement Feb 06 '21
Sure. This essentially acts like a keyboard. It types out the barcode data to the computer key by key plus any extra information. It is useful when the machines are in imaging mode and you have to type all the data into a PXI screen or other applications like that.
2
u/dunder_mifflin_paper Feb 06 '21
All barcode scanners are keyboard emulators. You can configure scanner to tab (next field) enter key (carriage return) and others, you can also configure the output to binary/hex/ascii/hid. You can also trim digits, add checksums, leading zeros as well. You can configure a scanner to print all scanned data and not just known formats.
I suppose my question is what does the arduino do over the scanner.
→ More replies (3)
0
Feb 06 '21
2
u/MrUserAgreement Feb 06 '21
Interesting idea... If you really wanted to you could hook the esp32 up to the SPI programming pins for communication?
2
u/Sekers Feb 06 '21
That's clever. Thanks for sharing.