The following video is a step by step of the changes that I have made in the code of Oleg Mazurov and description of the operation of barcode scanner. The example to control USB keyboard also find it on the USB Host Shield library 2.0 with the name “USBHIDBootKbd”. If your code reader does not match the above information after verification, is posible that you may not implement the code that we work here, so is important to check with your example of USB Host Shield 2.0 library called “USB_desc”.įor the USB_desc example appears in the example menu, you must first attach the USB Host Shield 2.0 library in the libraries folder of Arduino software.īasically what Oleghe Mazurov did in his code was to take the communication code of a USB keyboard, he make some modifications to the barcode reader and adding LCD control code. Download: USBHostShield2.zip, Version 2.0 (works with Teensy) USBHostShield1.zip, Version 1.0 (modified for Teensy) Only one version should be copied to your Arduino libraries folder.
Keyboard or mouse can be connected to Arduino with the shield, wireless communication can be done with bluetooth dongle, you can connect to barcode reader and even your phone.MAX3421 is used on board as USB host/SPI converter IC.
It is necessary to consider the recommendation of Oleg Mazurov in verifying the parameters of our device, which identify the CLASS and communication PROTOCOL as follows: Intf. The USB Host Shield, by Oleg Mazurov, allows you to connect other USB devices. Arduino USB Host Shield is a board which gives USB interface features to Arduino board and possibility to stack USB devices to Arduino. The goal is to do away with an Uno-sized shield and go smaller, such as with Arduino Nano or Trinket, if possible. Now I am migrating the project to read MIDI data from MIDI port (with optocoupler circuit).
The following is the code from Oleg Mazurov with the modifications that I have made to work with my barcode scanner and other different bar codes scanners:īar Code Scanner + Arduino Host Shield code Arduino USB Host Shield board - Let your Arduino support Android phone Support Google Android ADK function, support Android phone: G1, Nexus One, Nexus S, Motorola Droid X (Phone system needs upgrading to Android 2.3.4, Tablet PC need to upgrade to Android 3. I started with Arduino Uno with USB Host Shield (reading MIDI data from USB) and finished a working demo. In this test I used the code that kindly shows us Olegon Mazurov on their website and I have made some modifications, because it did not work well for my barcode scanner “Datalogic QuickScan” and I have not found more information on the web about the use of barcode readers with the USB port connected to a separate host as USB Host Shield of Arduino. In the world industry, a lot of products are identified by barcodes, is one of the most effective methods to identify products, papers, stickers, among many other things, is for this reason that implementing a system for reading bar codes independent of a computer allows greater flexibility to these devices, is why I wanted to bring this little test that will allow many projects related to barcodes, be more flexible and portable.ĭeveloping an Arduino project with BarCode Scanner + Arduino USB Shield