Sensor LDR
Sensor LDR
```cpp
Const int LDR_PIN = A0; // LDR connected to analog pin A0
Int sensorValue = 0;
Void setup() {
Serial.begin(9600); // Initialize serial communication
}
Void loop() {
sensorValue = analogRead(LDR_PIN); // Read the input on LDR
pin
Serial.println(sensorValue); // Print the value to the Serial Monitor
Delay(1000); // Wait for a second
}
```
### Applications:
- Automatic street lighting systems
- Light-sensitive alarms
- Solar garden lights
2
https://novaappai.page.link/FGxee8AwT6iyPo4o6