- Hands-On Robotics Programming with C++
- Dinesh Tavasalkar
- 67字
- 2021-06-24 15:30:32
Smart light – working with digital sensor
After writing our first C/C++ program for Raspberry Pi, we can now write a program that will take input from an LDR sensor and turn the LED on or off. For this project, you will need the following hardware components:
- 1 LDR sensor module
- 1 LED
- Raspberry Pi
- 5 female-to-female connecting wires
First, let's explore how the LDR sensor works.
推薦閱讀