My Dream Interior Collage
Do you want to make an easy preview of how your dream interior would look like?
I am not only explaining to you how to make 2D picture elements into a 3D model, but I am also learning you a simple, beginning way to work with Arduino.
With Arduino we will use a LED sensor, a button, LED's and a DC motor that moves horizontal.
STEP 1: WHAT DO WE NEED?
THE PHYSICAL COMPUTING
- Arduino Uno
- DC motor + motor driver
- 2 LED's (color preferred)
- A button
- A LDR sensor (Light Dependent Resistor)
- 2x 10K ohm resistor
- 2x 330 ohm resistor
THE OBJECT/MAQUETTE
- Pictures of interiors
- Scissor
- Glue
- 7x mica sheets A4 format
- 2x cardboard 5mm 200x300mm
- Cutter knife
- Ruler
STEP 2: ARDUINO CODE
First of all we will start to make de software code to make the setups work. You can just copy and paste this code into your program to make your diorama work. I used the symbol "//" for extra information of the code to make it more understandable for you.
ARDUINO CODE
//motor
const int standBy = 10;
const int PWMA = 3;
const int AIN1 = 9;
const int AIN2 = 8;
//led
const int buttonPin = 2;
const int ledPin1 = 12;
const int ledPin2 = 13;
//ldrsensor
const int ldrPin = A0;
int buttonState = 0; // button not pressed
void setup() {
pinMode(buttonPin, INPUT); // button pressed to make the motor work
pinMode(PWMA, OUTPUT);
pinMode(AIN1, OUTPUT);
pinMode(AIN2, OUTPUT);
pinMode(standBy, OUTPUT);
void loop() {
int ldrStatus = analogRead(ldrPin); //ldr light sensor
if (ldrStatus <= 800) { //value dependent on the incidence of light environment
digitalWrite(ledPin1, HIGH); // if value is lower or equal to 800, the light will go on
digitalWrite(ledPin2, HIGH);
Serial.print("Its DARK, Turn on the LED : "); //check in your serial motor what the right value is
Serial.println(ldrStatus);
} else { // if the value is higher than 800
digitalWrite(ledPin1, LOW); // the light will go off
digitalWrite(ledPin2, LOW);
Serial.print("Its BRIGHT, Turn off the LED : ");
Serial.println(ldrStatus);
}
buttonState = digitalRead(buttonPin); // read if button is 0 or 1
if (buttonState == HIGH) { // if button is on/pressed
Serial.println ("Button is pressed");
forward(150); // the motor will go on (0)
delay(1200); // all values here are dependent on what your distances are en how long you want it to stop!
stop();
delay(1200);
back(150); // the motor will go back (1)
delay(1200);
stop();
delay(1200);
} else {
Serial.println ("Button is not pressed"); // if the button is not pressed, the motor will stop
stop(); } }
void forward(int spd) {
runMotor(spd, 0); // one direction, right
}
void back(int spd) {
runMotor(spd, 1); // second direction, left
}
void runMotor(int spd, int dir) { // direction and speed of the motor install
digitalWrite(standBy, HIGH);
boolean dirPin1 = LOW;
boolean dirPin2 = HIGH;
if (dir == 1) { //direction change
dirPin1 = HIGH;
dirPin2 = LOW; }
digitalWrite(AIN1, dirPin1);
digitalWrite(AIN2, dirPin2);
analogWrite(PWMA, spd);
}
void stop() {
digitalWrite(standBy, LOW); }
STEP 3: HARDWARE
Now that you have your Arduino code, you are ready to make the hardware part to the installation to see if it actually works! How exciting!
The aim is to press a button and the motor is rolling and stopping. The ldr-lightsensor detects if it is bright or dark outside and the lights go off and on.
Here is a schedule of the wires. You can just do the same ports as I did, just like the code!
STEP 4: MODEL MAKING
Now that you have the software and hardware, the next step would be to build the model of your dream interior. Collect your favorite photo's of interiors and start to cut the elements that you would like!
Now we want to make the photos 3D looking. You glue the elements on different mica sheets. The more mica sheets you are using, the more your model is going to look like 3D. Now that you have glued, it is time to cut 'slices' through the cardboard every centimeter. !Do not cut all the way through! The intention is to slide the mica sheets in the slice cuts of the cardboard. If necessary, use glue to fix it.
For the motor, we also need to make a model. The motor turns in central and in our model and so we need to make a construction so the model person goes left-right. First of all we need to 3D-print 2 cilinders of 1cm width and 2cm high with a little hole in. One of the cilinders needs to fit on the pin of the motor. The other cilinder, depending on the distance, needs to fit in a stick. To connect the two cilinders you need a rope or string. The final step is to make a model man on the rope or string and you are done! You have accomplished your ideal dream interior with a walking man and a lightsensor!