The purpose of this project is to know how a semaphore works, how to change from one color to another, this project uses the programming language of Arduino.
Materials:
Arduino UNO
3 LEDs (1 yellow, 1 red and 1 green)
1 Protoboard
Male-male jumper cables
3 Resistors (220 ohm)
Arduino IDE software
Process
Put the LEDs in red, yellow and green order.
In the cathode parts (short leg of the led) there we put the resistors a resistance for each led and at the end of the resistance send a cable to the negative of the protoboard since that part goes to ground so that nothing burns the anode part (long leg of the led)
We put a jumper cable for each led since those cables will go to the Arduino board, now we will connect the Arduino to the propoboard
First we must power the Arduino and send that power to the propoboard so we look for the section of the Arduino where the voltage (5 V) and ground (GND) compartment is and we connect it to the breadboard to the space that corresponds to the 5v goes in the propoboard red line (+) and GND should be on the blue line (-).
5. Once that is done, now we decide in the digital part of the Arduino in which space each led should go, without forgetting where it is connected
6. Once this is done we go to the Arduino software and declare our variables where each led is, for example:
red int = 11;
yellow int = 12;
green int = 13;
7.Once I declare that And when you put that then you will see that that is already part of the code we follow the code that is on the tindercad page that is the link, there you will see the project model in flat form and the code that specifies what to do
<iframe width="725" height="453" src="https://www.tinkercad.com/embed/1aRmgS9Fw52?editbtn=1" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe>
Comments