Arduino Diorama

Introduction: Arduino Diorama

This diorama uses an Arduino Uno for the hardware, and one small breadboard to put all the components on. I had acces to an Arduino Sparkfun kit, but you can buy the parts seperately as well.

The diorama itself can be personalized as much as you like, this instructable is mostly for the hardware. I will explain a little about how I made my diorama though.

The video of my diorama can be found here:

Supplies

- Software:
Free, downloadable software: https://www.arduino.cc/en/software

- Hardware:
Sparkfun kit, extra wiring (and soldering iron and tin) and aluminium foil/tape, or separate parts:

- 1 Arduino Uno with USB cable
- 1 DC-motor
- 1 motor driver
- wiring
- soldering iron and soldering tin
- 3 LED lights
- aluminium foil/tape
- 1 "10K ohm" resistor
- motor driver
- 3 "330 ohm" resistors

- Diorama materials:

- cardboard box, painted black
- cardboard plate that fits in the box
-foam and paint for decoration
-reusable straw for the street lights

Step 1: Arduino Code:

First step is to download Arduino here: https://www.arduino.cc/en/software

To get the DC motor, the LED lights, the aluminium button and the potentiometer to work, I made the following code (see file). In the code, wherever a scentence starts with //, I wrote an explanation about the different parts of the code. These parts are of no influence on the code itself. Copy and paste this code in an Arduino file.

To check if the code works, you will need to build the hardware. See next steps.

Step 2: Building Hardware

In this drawing all the parts are shown and where they have to be connected. There is a more detailed explanation in the following steps.

Step 3: DC Motor and Potentiometer

First I connected my DC motor and potentiometer. You also need a motor driver for this. (see images).

wires to - from:

motor/motor driver/arduino

vm to Vin

vcc to +

GND to -

A01 to wire on motor

A02 to wire on motor

PWMA to pin 3

AI2 to pin 4

AI1 to pin 5

STBY to pin 6

potentiometer/arduino:

the potentiometer has 3 pins itself. the middle one goes directly to arduino: analog pin A2

the other two go to + and - on the breadboard.

Step 4: Led Lights

I used three led lights for street lights, that will go on when the potentiometer is turned on.

One of the images explains how to connect the lights to the breadboard and the arduino.

The pins on the Arduino Uno I used are pin 11,12 and 13.

Step 5: Aluminium Button/sensor

The "road" exists out of two aluminium circles, that, when they are connected, they will act as a button that overrides the potentiometer and so the orange car. The red car has aluminium on the bottom, and acts as the bridge between the two parts of the road.

One part of the aluminium road is wired to pin 8 on the arduino uno board. The other one is connected to the - on the breadboard, via a 10K ohm resistor, just like a button would. (See image step 2 for wiring.)

To connect the road to the arduino below, I used some tape with aluminium on it connected to wiring, and made slots right next to the aluminium road parts. I slid the other side of the tape through the slots and connected them on the surface.

Step 6: Soldering

When all the components are added and work, the ones that need to be extended to reach the right spot in the diorame, need to be soldered to extra wiring.

In my version of the diorama these are:

-the 3 leds

-the potentiometer

It is also possible to use the wiring like the one on the photo with the (blue) potentiometer, which is a less permanent solution.

Step 7: Building the Diorama

For the streetlights I used a hard plastic reusable straw (from Ikea) that I cut in three equal parts, and made a plastic top for the streetlights. I drew road stripes between the aluminium parts to make it look more like a road.

I used some foam to make a double bottom in the box to create space for the breadboard and the arduino.

The boulders are made from different types of (mattress) foam, as an experiment.

I also used foam clay (silk clay) around the "tree", and painted them to make them look like rocks.

The fencing by the streetlights are painted hot glue on plastic.

The car that goes around is held by the iron wire connected to the DC motor. I needed to be able to disconnect the parts so I DIY-ed a connection for this with some cardboard and plastic that fits snug on the motor, but when you want it to be more permanent, I recommend just (hot) gluing the wire to the motor, being careful not to glue it stuck on the floor.

Big vs Small Challenge

Participated in the
Big vs Small Challenge

Be the First to Share

    Recommendations

    • Colors of the Rainbow Contest

      Colors of the Rainbow Contest
    • Barbecue Speed Challenge

      Barbecue Speed Challenge
    • Arduino Contest

      Arduino Contest

    Comments