The above picture shows a circuit we were to construct consisting of 3 resistors, an LED, a pushbutton switch and a 2N3904 transistor. Initially, the LED is not lit, but when the pushbutton switch is engaged a small positive voltage flows into the base of the transistor which allows current to flow from the collector to the emitter. This current lights up the LED.
This particular circuit is essentially the same as the previous one but with the pushbutton switch removed. Instead of a pushbutton switch, a small positive voltage is flowing through my finger which then reaches the base of the transistor. The LED lights up but not nearly as bright as it had before.
In this exercise, we were to program the Arduino microcontroller to simply make an LED blink on and off. A loop was set up to turn the LED on for one second and then off for one second.
Using the Arduino microcontroller, we were also able to light up four LEDs one after another in a pattern similar to the lights on K.I.T.T. The program was not much different from the previous except that four pins were used as output and the delay time was decreased to 100 ms.
Also, we finished building our squarebot. After it was completed, Tommy programmed it and we were ready to drive around. I imagine that soon we will have to program it ourselves for the firefighting robot competition.
No comments:
Post a Comment