The Arduino platform is quite useful for making a quick prototype or when you’re getting started with embedded programming as a hobby. There are a number of shields available to extend a board’s capabilities but there is also a lot that can be done without any extra peripherals.
In this series I will demonstrate how you can flash the Arduino Uno with new firmware and have it emulate another type of device belonging to the USB Human Interface Device class (i.e. keyboard, mouse, joystick and so on). Using this knowledge (and the tools mentioned below) you too can create your very own input device be it a keyboard, joystick or even something like Hak5’s Rubber Ducky.
I will cover:
- What software and hardware is required
- How to use the software in a Windows 7 64-bit environment (should be the same in other versions of Windows as well)
- Resources for firmware
- What to do when things go wrong
I will be using an Arduino Uno R3 (non-SMD) which features an Atmega16U2 (small chip by the USB connection) and Atmega 328P (larger chip). The steps below may vary if your board is different but the process overall will be approximately the same. I would strongly encourage you to read through to the end of the article before connecting your board and following the steps to decrease the risks to your sanity (and Arduino board).
This first post will get you all set up with the software and hardware you will need. Let’s get started!
You will need
This tutorial’s aim is to give you an idea of the process which you will need to follow to be able to flash your Arduino with new firmware. As your projects develop you will find you require more hardware (and possibly software) than is mentioned below.
- Arduino board (I am using an Arduino Uno R3)
- USB Cable (to connect your board to the computer)
- Header jumper (or wire to connect two headers)
- Arduino IDE (install from from Arduino.cc)
- DFU Programmer
- Windows: install from Atmel FLIP
sudo apt-get install dfu-programmer
- Arduino firmware (so you can restore your board to function as an Arduino)
- Firmware for the device you want to emulate; some examples here
- Arduino sketch with the logic for your peripheral (you can skip this for this tutorial
The next post in this series will cover flashing your Arduino board with the new firmware.