2.5 Dragster Race
Car Track with Timing Circuit
Car Track with Timing Circuit
What to Expect
Today your group will create a race track for the micro:bit dragster that you created in a previous session. Our goal for today is to create a dragster race track for your micro:bit dragster with a timing circuit similar to the one in the image below. The drag strip race course will be controlled by a micro:bit. This circuit will record how long it took your car to travel over the race distance. You can even use this information to calculate the average speed of your car.
Connections
In the last two activities, we built a micro:bit-powered dragster race car and a set of countdown lights. Today we will build the drag race track itself. In the next activity, we will combine all three of these components (dragster, countdown lights, and race track) to make an automatic drag race that you control with the push of one button. A standard National Hot Rod Association (NHRA) drag race track is ¼ mile long, with a timing circuit to measure the time that the dragster race car took to complete the course. See Figure 1 for an example of a drag race track. Notice the two large billboard signs at the far end of the race track. These signs display the time that it took for each race car to complete the course.
Figure 1. Drag race strip. Image courtesy of Drag Illustrated
Materials
Materials to complete one dragster race track (work in teams of approximately four people):
micro:bit
USB cable to connect the micro:bit to a computer
Micro:bit battery pack
About 6 ft. of speaker wire (red and black wires attached together)
4 Alligator clips (2 Black, 1 Red, 1 Green)
About 6 ft. of copper tape
4 standard pieces of paper (notebook paper or printer paper)
Tape measure
Wire strippers
Cut out four strips of copper tape that are each about 11 inches long.
2. Peel the copper tape off the adhesive backing of two strips of copper tape and attach them to a piece of paper in the horizontal direction with a very small gap in between them, as shown. **Hint: peel the copper tape off and apply the copper tape to the paper a few inches at a time. It will be difficult to handle if you peel all of the copper tape off the backing at once. The two strips of copper tape should be separated by a very small gap of about 1/8 - 1/16 inch. The copper strips should be very close together, but make sure the pieces of copper tape do not touch each other.
3. Repeat the previous step once more. You should now have two pieces that look like step 2. One will be the start line, and one will be the finish line.
Now, cut two approximately 3-foot long sections of speaker wire (speaker wire has both a red and black wire)
4. Separate (peel apart) about two inches of the red and black wires on both ends of both of the speaker wires you just cut, and use wire strippers to strip about half an inch of insulation off of the ends.
5. Take one piece of paper with two copper tape strips, one piece of speaker wire, and a roll of tape (e.g. clear Scotch tape, electrical tape, etc.). On one end of the speaker wire, tape the red wire to one piece of copper tape, and tape the black wire to the other piece of copper tape. It does not matter which color wire is taped to which copper strip.
6. Repeat step 5 for the other piece of paper with copper tape and the other piece of speaker wire. You should now have two pieces that look alike. One will be the Start line, and the other will be the Finish line.
7. Next, we will connect the other ends of the speaker wires (the ends that are not connected to the copper tape). On the other end of one speaker wire connect one of the exposed individual wires (it doesn’t matter which one) to the GREEN alligator clip. Then,
connect the other exposed individual wire to a BLACK alligator clip. This will be the starting line of your track.
8. On the other end of the other speaker wire connect one of the exposed individual wires (it doesn’t matter which one) to the RED alligator clip. Connect the other exposed individual wire to a BLACK alligator clip (not the same one as in the previous step)
This will be the Finish line of your track.
Make sure that the alligator clips are not touching each other.
9. Next, we will connect the other ends of the alligator clips to the micro:bit.
Connect the other end of the GREEN alligator clip to P0 on your micro:bit. Connect the other end of the RED alligator clip to P1 on your micro:bit. Connect the other end of both BLACK alligator clips to GND on your micro:bit
10. Tape down the pieces of paper about 6 feet apart (distance can vary) on the ground. The paper connected with the GREEN alligator clip is your Start line and the paper connected with the RED alligator clip is your Finish line.
11. To complete the dragster race track, we need something to complete the circuit between the two copper strips when the micro:bit dragster crosses either the Start or the Finish line. Cut out 10 pieces of copper tape that are each about 2 inches long. Take another blank piece of paper, and five of the 2-inch copper tape pieces. Tape the pieces of copper tape down the center of the sheet of paper as shown. Repeat this step again so that you have two pieces like the image shown above.
12. Take one of the pieces of paper that you just made with the 2-inch strips of copper tape running down the middle. Tape the piece of paper (copper tape side down) over the Start line of your track, but tape it so that it has a slight “hump” in the middle. The copper strips on the top and bottom paper should be at right angles to each other. See image for an example. When the race car drives over the paper, it will press down on the top piece of paper, causing the copper strips on the top paper to complete the circuit between the two copper strips on the bottom piece of paper.
13. Repeat the process from the previous step on the Finish line of your track. An example of a completed race track is shown.
Program the micro:bit
Finally, we need to program the race track’s micro:bit so that it will start a timer when the car crosses the start line, stop the timer when a car crosses the finish line, and display the time that it took the car to complete the course.
14. Go to the code for this circuit by clicking here: Dragster Race Course Timer. Click “Edit” in the upper right corner of the screen. Pause here, and take a moment to think about what this code will do. Note that your starting line circuit is connected to “P0”, and your finish line circuit is connected to “P1”.
15. In the simulator window on the left side of the screen, use your cursor to click on the “P0” input, then wait a few seconds and click on the “P1” input. What do the scrolling LEDs say? The results scroll past quickly. You can click on the “A” button to make them appear again.
16. Connect your micro:bit to the computer with the USB cable and download the code to your micro:bit (instructions). Then connect the micro:bit to its battery pack, and make sure the alligator clip wires are connected. Test the fully completed circuit by pressing on the Start line (completing the circuit to “P0”), wait a few seconds, and then press on the Finish line (completing the circuit to “P1”). You should see the resulting time scrolling on your micro:bit. To see the result again, press the “A” button.
17. You can now use your micro:bit dragster race car to test out the track! Make sure that the race car is aligned straight with the track, and the swivel wheel is pointing straight ahead when it starts the race.
A summary of how this code works:
When something conductive bridges the gap between the two pieces of copper tape at the starting line:
Pin P0 will be “pressed” or activated
The starting time will be recorded internally
A picture of an arrow will appear on the micro:bit LEDs
When something conductive bridges the gap between the two pieces of copper tape at the finish line:
Pin P1 will be “pressed” or activated
The finish time will be recorded internally
The elapsed time will be calculated by subtracting the start time from the finish time, and converting from microseconds to seconds
The elapsed time in seconds will display on the micro:bit LEDs
When the “A” button is pressed:
The elapsed time will appear on the micro:bit LEDs again
Troubleshooting If the race track circuit is not working properly:
Check that the copper strip on the top piece of paper is pressed firmly onto the two copper strips on the bottom paper when the car drives across it.
Check that the wires are taped securely to the copper strips, and that all alligator clip wires are connected securely.
Check that the micro:bit is powered (either by the USB cable or a battery pack).
Think about it
What would happen if your car went backwards down the track, crossing the finish line and then the start line?
Feedback Link
How did you feel about this activity? Change the emoji to show your feelings.
Next Activity Congratulations on building a working drag race strip! In the next activity, we will combine the previous three components together: a micro:bit race car, a countdown circuit, and the drag race track. With the push of one button, the countdown circuit will count down to the start of the race and start the race car in motion, and the race track circuit will time the car between the start line and finish line of the track.