Posts tagged ·



DIY Arduino Debug Shield

Comments Off

Debugging with LEDs; it’s probably even more primitive than debugging with printf statements. However, to get a very immediate feedback on what’s happening, or which pins are in use, it can be useful. So what better way then than a ~$2 homemade shield to pop on top of your existing project.

DealExtreme supplies all the parts needed: A versatile prototyping shield board with holes and wires in sensible locations; a bag of assorted LEDs; resistors; and header pins. (The board and headers in this project used 6x and 8x header pins, to fit with the older Duemilanove. The Uno another other boards have slightly different pin layouts, so plan ahead).

Now, I’m not an expert at soldering, nor product design, but this shield does the job, and already helped in programming my next project. Lesson learnt: Lay out the components all the way before heading off with the iron. I should have gone with the 3mm LEDs all the way. Or, maybe surface mount could have worked. Next time.

Comments Off

16×2 LCD and button shield

Comments Off

I recently picked up this 16×2 character LCD and button shield from DealExtreme. It is similar to the Hitachi based shields and displays sold elsewhere, but with a slightly different pin-out. It still fits right onto the Uno or Duemilanove. For only $6 it’s almost a must in any project toolkit. What’s more, it’s compatible with the LiquidCrystal Arduino library, and very easy to get started with. Just note the modified pin connections, and you’re set to go.

The sketch below will display “hello world”, a counter, and the value of the button presses on the screen. Furthermore, you can use the up and down button to adjust the back-light brightness. Just an example; I’m sure there are unlimited uses for this screen.

Please note, the button values was what I read from my shield, through the analog pin. Although it seems very consistent, other shields might give different readings. It’s probably a good idea to shift off the two least significant bits to allow for some leeway.

// Code under GPL; please see full file for details.

#include <LiquidCrystal.h>

LiquidCrystal lcd(8, 9, 4, 5, 6, 7);

void setup() {
  pinMode(10, OUTPUT);  // for backlight adjustment
  lcd.begin(16, 2);

  lcd.print("Hello World!");

int button_value;

int light = 100;

void loop() {
  lcd.setCursor(0, 1);
  button_value = analogRead(A0);
  if (button_value == 132)
    light = min(light + 1, 255);
  if (button_value == 306)
    light = max(light - 1, 0);
  analogWrite(10, light);  

  String tmp = " ";
  tmp += light;
  tmp += " ";
  tmp += button_value;
  tmp += "   ";  // erase previous digits

  lcd.setCursor(4, 1);  

Comments Off

Arduino adapter shield for the RPi

Comments Off

The H recently wrote about the AlaMode board which lets you use Arudino compatible shields with the Raspberry Pi. The board connects to the GPIO headers of the RPi, and exposes the familiar pin-set of the Arudino Uno on top. The AlaMode board also contains a real time clock, which it can provide as an add-on to the RPi which as none.

In fact, from the picture, it looks like the board is a full fledged Arudino itself, with an Atmel 328P chip on top. It should mean that you can program it on-board, directly from the RPi.

The board is selling for $45, but is out-of-stock at SeeedStudio.

Comments Off

Panorama Robots


It somehow seems inevitable; if you are into photography and electronics, you want to build a panorama robot. Coupled with very good software to stitch and render a panorama image, the results can be breathtaking even with little effort. For the stitching software, I recommend Hugin, the open source panorama stitcher. On a modern OS; just go yum / apt-get install hugin. For a good intro into setting up and shooting the single frames which goes into your panorama, see Robert. Cailliau’s article.

Once you’ve taken a few pictures, maybe five or even ten with a fairly wide angle lens, you realize that you can get even more detail if you use a zoom lens. Maybe 200 or 300mm. However, now you have to take hundreds of pictures to cover the same area in your finished panorama. This is were the robots come in.

The pocket camera on the turn table below is a very cheap solution; about 15 Euros. I have not found a specific product or manufacture name, though. It shows up in searches for “Panorama Drehteller“. Next to it is a more professional solution, the Gigapan Systems Epic 100 Panorama Robot. It can take a DSL, and pan both horizontally and vertically. You need both if you plan on using a 200mm lens.

So if you’re only into photography, and not DIY and soldering, those are maybe some of the solutions you’d go for. However, if you are able to build one yourself, what is stopping you? Nothing, it seems, judging by the number of home made panorama bots. Here is a Lego Mindstorms competition to build a pano bot with the winners from 2008. Here is a Jason Babcock’s second go at a panoramic turntable, using ULN2004A and BX-24 micro-controller.  And here is T. Emrich’s system which looks like a very solid setup, and clever control: His early work resulted in a horizontal rotation only solution. Later on, he built the GigaPanBot or Gigapixel Panorama Robot with complete freedom on both axis, seen in the picture below. Maybe most impressive, is how the whole system fits into his camera bag.

So what if you want to build your own. Well, nothing is stopping you, and there is plenty of parts to pick up to make a simple first system. Babcock’s first attempt was using a stepper motor from an old fax. Or you could buy a new stepper motors for less than 20 Euros.

To help you on your way, there’s the DollyShield, which I spotted on the Arduino Shield List. It includes control of two DC motors, shutter remote for the camera, joystick buttons and a LCD. “It is designed to provide an inexpensive and easy-to-use interface for two-axis motion control integrated with a camera.”

Arduino Shield List

Comments Off

Jon Oxer has launched a site to catalogue all Arudino shields: Arduino Shield List ( At the time of writing, there are “pin usage details for 166 shields from 70 makers, and counting!”

Comments Off