Smart "Disco" Lamp - Thiago Fornarini, Joaquin Racamato, Geronimo Signore

by Thiago Fornarini in Circuits > Arduino

168 Views, 0 Favorites, 0 Comments

Smart "Disco" Lamp - Thiago Fornarini, Joaquin Racamato, Geronimo Signore

WhatsApp Image 2022-11-14 at 21.10.24.jpeg
descarga (1).png
ETRR logo.png

Hello! Our names are Joaquin Racamato, Thiago Fornarini, and Geronimo Signore. We live in Campana, a city 90km from CABA (autonomous city of Buenos Aires). We are in 3rd Year or 9th Grade in the US, and we are 14 and 15. We are studying at the Escuela Tecnica Roberto Rocca of Argentina.

We are very excited to make this project because It’s very interesting and we learn a lot doing projects with Arduinos and programation. Our project involves the teachers of English (in our case B1+ Carolina Di Palma) and Technology Innovation(Manuel Djerdjian, Juan Lusardi, Belen Torres and Daniel Barrios). We need to make an smart lamp with leds, Arduino, batteries, servo motors and resistors. We have to publish a tutorial of how to make the product, but you have to know about sketches and all the staff needed, aplicating the IRAM standars. Also you need to know OnShape to do the 3D product and the parts of it . Our lamp Is made with cardboard and it can rotate on the 2 axes, the Y one and the X one, it can rotate because of the servomotors, located in strategic locations for the correct use of them.


WE RECOMEND THAT THE FIRST THING YOU SHOULD DO IS READ THE LAST STEP, "RECOMENDATIONS", AND OF COURSE, THE WHOLE INSTRUCTABLE BEFORE YOU CARRY OUT THE PROJECT.

Supplies

servo.jpg
LEDs.jpg
12615-02_Full_Size_Breadboard_Split_Power_Rails.jpg
311bGhoaiPL._SX342_.jpg
s-l500.jpg
uno.jpg
A_few_Jumper_Wires.jpg
WhatsApp Image 2022-11-14 at 21.35.50.jpeg
WhatsApp Image 2022-11-14 at 21.35.21.jpeg
WhatsApp Image 2022-11-14 at 21.33.59.jpeg
WhatsApp Image 2022-11-14 at 21.33.39.jpeg
WhatsApp Image 2022-11-14 at 21.33.19.jpeg

MATERIAL THAT YOU NEED, HOW MANY AND WHY...

. Sheets of paper - Sketches and Croquis

. Pencil - To draw Sketches and Corquis

. A computer with OnShape - 3D model and fabrication bluepints

. A lot of fiberboard - The case


Electronic Components:


2 Servomotor - Its function is to rotate the Lamp Head and a rotary base. 

8 Leds - Emit colored light trough electrical energy.

1 Breadboard - Conect all the components 

8 Resistor of 220 Ohms - 2x7mm- Opposes the energy through the component

Some Screws - Screws connect one part to the other 

1 Arduino UNO - Hold all the programming + provides your circuits 5v

10-12 Wires - Conect all the components to the Arduino UNO/Breadboard


Shell:

For the shell we did some blueprints, so it's easier to you build it. To see them, you have to click in +9, in the images.


EVERYTHING IS IN MM - 1 inch = 25.4 millimetre

Espesor = Thickness

Sketches

WhatsApp Image 2022-11-16 at 12.07.57.jpeg
WhatsApp Image 2022-11-16 at 12.08.35.jpeg
WhatsApp Image 2022-11-16 at 12.05.28.jpeg
WhatsApp Image 2022-11-16 at 12.07.20.jpeg

These are the first sketches of our lamp, from here we defined the proportions of the lamp and we had an idea. Also here, you should undestand how each part work individually and together.

Croquis

WhatsApp Image 2022-11-16 at 12.23.22.jpeg
WhatsApp Image 2022-11-16 at 12.23.56.jpeg
WhatsApp Image 2022-11-16 at 12.23.39.jpeg

In this part we determinated measures of the lamp and we drawed it considering the IRAM standards for a correct draw. With IRAM standards we mean, draw properly the numbers and lines of the draw.

You will see, that the fourth part of the lamp doesn't has a croqui, because it wasn't on our minds at that point of the project.

3D Modeling

WhatsApp Image 2022-11-16 at 13.38.08.jpeg
WhatsApp Image 2022-11-16 at 13.36.57.jpeg
WhatsApp Image 2022-11-16 at 13.36.16.jpeg
WhatsApp Image 2022-11-16 at 13.35.29.jpeg
WhatsApp Image 2022-11-16 at 13.41.16.jpeg
WhatsApp Image 2022-11-16 at 13.38.50.jpeg

In this point, we added the 4th part of the lamp, the "Connection". The name is Connection because is the connection between the roof and the lamp.

If you did'nt undestand something about the lamp, here you clear your doubts.

Link:​

https://cad.onshape.com/documents/aaa9c525930f34dffdb9da91/w/21b05e574dd47b1859a663ef/e/e50b44d58529a856c903067f?renderMode=0&uiState=633dbf6a1c23f3078b1fab38 

Build It the Case, Anchor and Connection of the Components

WhatsApp Image 2022-11-09 at 22.55.09 (3).jpeg

In the second step, we already did the holes needed for the anchor of the components and the conection of the case, with glue in heach part nedeed, (you can know were to stick the fibreboard looking at the blue prints in the first step).

In the video you can see how we connected the servomotor to 1 side of the hexagon, so then when we are going to stick it with glue, the whole hexagon could move properly.

We connected the wires to the Leds wheling with tin, that is a strong union between this 2 components, so we recomend to do it like us. And then, of course, insulate them with insulating tape.

Pogramattion, the Code and Our Experience

codigo-fuente.jpg

We are using a C++ block language for the programmation in Tinkercad, and you can translate it to C++ and then upload it to the Arduino. We chose it because we have always worked with it and It’s intuitive for new developers, also Arduino only uses C++ code. Each block has a different statement, condition, or event. To program the step by step of a task, the blocks must fit in an orderly and logical way. When they are put together, they fit together like Lego pieces or puzzles and stacks or sequential chains of blocks are created, small programs. 

When we started with the programation of the lamp, we had clear the objetives and we knew about programattion, so it was easier to start with it, no big difficulties. The first step was the progrmation of the leds, not very difficult, just turn them on and off, waiting a while bettween on and off. The second step was the programattion of the servomotors, that was a bit harder, because we didn't knew how the movement was going to be. So we decided to move it randomly between 0° and 180°, waiting 1 second between each move.


This is the code that we wrote, you can modify it in your favor:

// C++ code

//

#include <Servo.h>


Servo servo_13;


Servo servo_12;


void setup()

{

 pinMode(1, OUTPUT);

 pinMode(2, OUTPUT);

 pinMode(3, OUTPUT);

 pinMode(4, OUTPUT);

 pinMode(5, OUTPUT);

 pinMode(6, OUTPUT);

 pinMode(7, OUTPUT);

 pinMode(8, OUTPUT);

 servo_13.attach(13, 500, 2500);

 servo_12.attach(12, 500, 2500);

}


void loop()

{

 digitalWrite(1, HIGH);

 digitalWrite(2, HIGH);

 digitalWrite(3, HIGH);

 digitalWrite(4, HIGH);

 digitalWrite(5, HIGH);

 digitalWrite(6, HIGH);

 digitalWrite(7, HIGH);

 digitalWrite(8, HIGH);

 delay(500); // Wait for 150 millisecond(s)

 digitalWrite(1, LOW);

 digitalWrite(2, LOW);

 digitalWrite(3, LOW);

 digitalWrite(4, LOW);

 digitalWrite(5, LOW);

 digitalWrite(6, LOW);

 digitalWrite(7, LOW);

 digitalWrite(8, LOW);

 delay(500); // Wait for 150 millisecond(s)

 servo_13.write(random(1, 190 + 1));

 servo_12.write(random(1, 190 + 1));

You should be able to copy and paste this on ARDUINO IDLE, and if it is all connected like we are telling you, it will work!

Recomendations and Answering Questions

WhatsApp Image 2022-11-14 at 22.49.32.jpeg

If there is any doubt at this point, we will answer it here, please in the coments of the Instructable, write your coments. :D

WE RECOMEND TO DO THE CIRCUIT AT THE SAME TIME AS THE REST OF THE CASE. THAT'S WHY WE DID IT BOTH OF THE THINGS, 1 STEP.


Here is the circuit with the connections, you must connect it like us if you are going to use the same code.


THAT WAS ALL, THANK YOU. WE HOPE THAT YOU CAN MAKE IT LIKE US :DDD

The end.