Untitled
Never
#include <Arduino.h> const int SENSOR_PIN = 4; const int RELAY_PIN = 2; void setup() { Serial.begin(9600); Serial.println("Projects Planner"); Serial.println("HC-SR501 sensor with relay"); pinMode(SENSOR_PIN, INPUT); pinMode(RELAY_PIN, OUTPUT); } void loop() { int motion = digitalRead(SENSOR_PIN); if (motion) { Serial.println("Motion detected"); digitalWrite(RELAY_PIN, LOW); } else { Serial.println("===nothing moves"); digitalWrite(RELAY_PIN, HIGH); } delay(500); }
Raw Text
-
Veil of the Verdant Vale: Secrets That Thrive
4 sec ago
-
sasfasfasf
3 min ago
-
asdfadfsdf
9 min ago
-
bgjay
23 min ago
-
dfdv r vcfv
27 min ago
-
SEGÚN
27 min ago
-
17 TERABYTE PREMIUM ÇP FOR SALE
35 min ago
-
The Future of Personalized Medicine: Tailoring Treatments to Individuals
38 min ago
-
Adult Telegram Channels
41 min ago
-
Lament of the Lost Lamb: Echoes in the Emptiness of the Field
41 min ago