Wednesday 22 July 2015

Shake Flashlight: STEM summer 2015

This project doesn't use Arduino yet.  We can use Arduino later to collect quantitative data about the voltage that is produced by shaking the light using analogRead.  It takes some fancier programing and circuitry to make an Arduino measure amperage.


Today students created a device that generated electrical current.

Students here are creating the coil.

After students create the coil they sanded off some of the insulation from each end of the wires and added an LED.  Shaking a neodymium magnet in the PVC tube produced a current through the wire.

Here is a video of a final product.

This isn't a very efficient flashlight.  Students will be asked this year how are ways they can make this flashlight better.

During this class session students were also shown a brief demonstration of how Arduino and Processing program to read the voltage produced from the shaking motion.  I will post about the details that that later.


Traffic Light: STEM Summer 2015

This lesson started with a mini lecture of what were LEDs, resistors, and how breadboards worked.


(If you are teaching your students about the resistor color code. Follow this link to a great Resistor Color Code Game)

Students then built the traffic light circuit with the arduino below.


Screen Shot 2015-07-13 at 3.24.09 PM.png


Students then wrote and uploaded a sample program. They played with the lines of code in the void loop to turn on and off all three lights.

Students then made the lights simulate a real traffic light.  The following was their challenge.

  • Make the yellow light flash on and off 5 times. (one second on one second off)
  • Then the Green light goes on for 10 seconds.
  • Next the Yellow light goes on for 3 seconds.
  • Last the Red light is on for 7 seconds.
  • The program then loops back to the blinking yellow light.



Last the students worked on modifying a program to simulate a walk button in the traffic light system. They used the following program to modify.

Students added their traffic light program into the else brackets and changed the line of code for if the button was pressed.

Students realized that to make the walk button to work you had to hold it down because of all the delays in their traffic light program.  Additionally after you held down the button the traffic light went from red to yellow.  Maybe the program should just stay red longer.  Some students took out the yellow turning on when the button was pressed.

Keep following.  There will be more about using the clock on the board to make a more realistic traffic light.