You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
561 B
561 B
PIR Sensor (Interface to ESP8266)
-
Schematic
-
- GPIO12 : PIR Out
- VCC : 3.3 / 5V
- GND : GND
-
Sample Arduino Code
int inPin = 12; void setup() { // put your setup code here, to run once: Serial.begin(9600); pinMode(inPin, INPUT); } void loop() { // put your main code here, to run repeatedly: int val = digitalRead(inPin); Serial.print("*Detected = "); Serial.println(val); Sleep(500); }
