Driving USB Peripherals With Arduino

arduino-driving-USB-keyboard

Circuits@Home have managed to host a USB keyboard with an Arduino and display the keyboard inputs on a character LCD. This uses the USB host shield we covered in August. That host shield includes a MAX3421 which is used here to drive the character LCD.

The control code for the keyboard ends up being fairly simple. The keyboard is polled for entries. The HID input is then examined and converted to ASCII codes for use with the LCD screen. This could make for an excellent controller or debugger for embedded systems. The Arduino, shield, and LCD could be integrated into the keyboard itself with an I/O port for connecting to your project. Commands can be typed out and sent through the I/O port when enter is pressed, with feedback displayed on the screen.

The example code provided with this project lays out the framework for hosting peripherals. We’re looking forward to more projects, and code libraries that take advantage of this new functionality.

Arduino USB Host Shield

UsbHostShield

Circuits@Home has been journaling their development of a USB host mode shield for Arduino, which could bring the platform a veritable explosion of mass storage, keyboard input and countless other peripheral options (and a corresponding raft of new hacks). Currently at the prototype stage, a ready-made shield and library are forthcoming, so keep checking back. Meanwhile, for embedded developers wanting to learn the ropes of USB, the in-progress articles will likely provide some valuable insights.

[thanks Kersny]

Forknife, Android G1 Controlled Robot

g1bot

When we first saw [Jeffrey Nelson]’s G1 based robot we immediately wondered what the transport for the controls was. The G1‘s hardware supports USB On-The-Go, but it’s not implemented in Android yet. It turns out he’s actually sending commands by using DTMF tones through the headphone adapter. The audio jack is connected to a DTMF decoder that sends signals to the bot’s Arduino. He wrote client/server code in Java to issue commands to the robot. You can find that code plus a simple schematic on his site. A video of the bot is embedded below.

Continue reading “Forknife, Android G1 Controlled Robot”