A step-by-step tutorial to build, in a very simple way, a funny car park with automatic barrier and display-counter with your Intel® Galileo!
» Recommended age: 15+
» Recommended age (to play with the car park): 3+ :)
» Minimum setup time: 30 minutes
» Video demonstration:http://youtu.be/ubVouDPWo6o
» Stuff You’ll need:
► 1 (one) Intel® Galileo (we recommend Galileo Gen 2, but you can also use a Galileo 1st Gen)
► 1 (one) breadboard
► 2 (two) push-buttons
► 1 (one) servo-motor (we have used a Servo Tower Pro SG90 9G)
► 1 (one) seven-segment display (common cathode (CC))
► some jumper wires M/F, M/M and F/F
► some resistors
► Step 1 - Connect and test the 7 segment display
► Step 2 - Connect and test the servo-motor
► Step 3 - Connect the push-buttons (using servo and display)
► Step 4 - Hardware review & schematic
► Step 5 - Coding
► Step 6 - Transfer the sketch on Galileo...and enjoy you car park!
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.
Step 1: Step 1 - Connect and Test the 7 Segment Display
To connect the 7 segment display, we need 7 outputs for each segment. Each segment is identified with a letter, from “a” to “g”.
So, you have to connect the numbered outputs on the board.
Now connect each numbered terminal on the Galileo to the “a” unique terminal of the 7 segment display (we have used this order way: 2 to “a”, 3 to “b”, and so on like we have done). Obviously, use some M/F jumper wires for it.
Next, connect the common terminal in the display to the board’s GND terminal, and use a F/F jumper wires to insert a resistor in this connection from the display to the board.
Now you should test the display to be sure that everything is ok. Transfer this sketch (see the attachment) on the Galileo, it simply shows on the display the numbers from 0 to 9 with a 500ns of delay to each others.
If the display works, we can go to the next step!
Step 2: Step 2 - Connect and Test the Servo-motor
Now it’s time to test your servo-motor. Don’t unplug the display Remember that:
► the red cable is tipically used for the power, so we recommend a M/M red jumper wire to connect this cable to the Volts;
► the black cable is tipically used for the ground, so we recommend a M/M black jumper wire to connect this cable to the GND;
► the yellow cable is tipically used for the signal, so we recommend a M/M yellow jumper wire to connect this cable to a logic pin cable on the board (we have used the pin “10”).
Once these connections are done, you can test your servo running this sketch (see the attachment) on Galileo: it simply performs a movement of 90 degrees of the servo. Don’t worry about the display, in this test it will not turn on.
If the servo works, we can pass at the step 3!
Step 3: Step 3 - Connect the Push-buttons (using Display and Servo)
Don’t unplug both the display and the servo, we will use them to test the push-buttons. Let’s connect them in this way! Take also your breadboard.
► Put one push-button in the breadboard;
► put a resistor with one end into the Volts cable and the other end connected with one of the terminals of the button;
► connect the other corresponding terminal to GND. The corresponding terminal is usually on the same side as the first one;
► connect the first terminal (the one with the resistor) to pin “11”.
Repeat the last 4 instructions to put another push-button on the breadboard, you have to connect this one to pin “12”.
Step 4: Step 4 - Hardware Review & Schematic
Well done, you have successfully built the car park! :) Your park should be similar to the one showed in the picture below (in the picture, the board is an Intel Galileo Gen 1 and the display has a resistor for each segment; anyway, these differences are not so important).
Step 5: Step 5 - Coding
See the attachment to get the ultimate sketch!
Step 6: Step 6 - Transfer the Sketch on Galileo…and Enjoy Your Car Park!
Great work! If you want, you can add all the feature you want to your car park!
Take note: if you use a Galileo Gen 1, then you might need to use an additional power supply because the Galileo Gen 1 could not provide the energy required for the servo-motor and the display; for this reason, we recommend to use a Galileo Gen 2, which provides enough power for all components!
You can find the project here on Fritzing: http://fritzing.org/projects/automatic-barrier
We hope it has been simple for you! Enjoy! :)
by: Valentina Lipari & Giovanni Meo - Students in Computer Science at Università Degli Studi di Napoli “Federico II”