USB-Keyboard With Arduino And V-USB Library, An Example
Maybe your like
This is another short example of a demo application that makes use of the V-USB library together with an Arduino. I show, how an USB keyboard functionality can be implemented.
The motivation: The V-USB library provides a quite simple possibility to realize USB devices with arbitrary USB descriptors. This is useful, for example, if the device that you want to connect to can only handle certain types of USB devices. The V-USB library allows you to implement exactly the device descriptor that can be understood by the other device.
This exemplary project is a summary from various sources. I do not want to repeat all the detailed explanations from these sources in the following, but rather show how to build a working example. For a deeper understanding I give a list of usefull links that should help for an understanding at the end of this post.
This example makes use of the Arduino 1.0 IDE and the fifth alpha release of the V-USB library. To setup the USB keyboard, we need the following parts:
- 1 Arduino board. I have a Duemilanove, but I assume that any other board (even any other ATMEGA controller?) would also do.
- For the USB interface:
- 1x USB “B” female socket
- 1x 2K2 (i.e., “2.2 kilo Ohms”) resistor, 1/4W
- 2x 68R (i.e., “68 Ohms”) resistor, 1/4W
- 2x 3.6V Zener diode, 1/4W
For the button:
- 1x switch/push button etc.
- 1x 10K resistor
For the assembling, we need a breadboard and some jumper wires. I used these schematic for setting up the button circuit:

For connecting the USB socket, I used this schematic:
To give you an idea about how everything could look after assembling, here is my circuit:

More details about this small USB keyboard project can be found in the book “Practical Arduino“. If you feel that you lack some more basic understanding of the Arduino and microelectronics, the short book “Getting started with Arduino” provides a really nice introduction to these topics. Detailed tutorials about the V-USB library can also be found in the blog of Joonas Pihlajamaa.
Tag » Arduino V-usb Keyboard
-
Julianschuler/USBKeyboard: Arduino Library To Add HID ... - GitHub
-
Connect A USB Keyboard With An Arduino - Arduino Project Hub
-
Connect Arduino UNO To USB Keyboard
-
V-USB And Arduino - Microcontrollers
-
USB-Keyboard With Arduino And V-USB Library, An Example - Pinterest
-
Arduino UNO As A USB Keyboard (HID Device) [Anything ... - YouTube
-
Arduino V-USB / HID 14 Channel Data Logger
-
How To Make A Arduino HID Keyboard : 18 Steps - Instructables
-
Learn More | Trinket USB Keyboard - Adafruit Learning System
-
Vusb Arduino Shield - Fritzing
-
A Firmware-Only USB Driver For Atmel(r) AVR(r) Microcontrollers
-
Connect A USB Keyboard With An Arduino
-
Usb-keyboard · GitHub Topics
-
How To Use The V-USB Library To Emulate A Keyboard On The Arduino ...