Arduino
Transmission
Today we’re going to learn how to add other sensors to your Arduino. We are going to use a photoresistor or simply a light sensor in today’s lesson. This little component can sense how much light is hitting it. Using some arduino code we’ll be able to take that data and turn off our LED automatically.
Ascent Checklist
- Clean workspace
- Arduino Uno + USB Cable
- Breadboard
- Photoresistor (Light Sensor)
- 3 More Jumper Cables
- 1 More Resistor (10 Kilohm)
- LED Light
Video placeholder - needs to be updated with actual Arduino light sensor tutorial
Links
- Read Sensor - We will use this simple code to read the Light Sensor.
- Sensor LED Trigger - Using this code you can turn your LED on or off depending on how much light your Light Sensor gets.
Mission
-
Add Light Sensor - Follow Alice and Ji as they add the light sensor to their Arduino and breadboard set up. Use the code above to learn how to read the light sensor. Make sure everything works before moving on to the next mission.
-
Turn LED On/Off Using Light Sensor - Use the code in the video to learn how to turn off your LED from the Light Sensor data. Try to do this on your own if you get stuck you can use the code listed above.