This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| electronic:pir:sr505 [2018/08/24 01:44] – [Related datasheets] tony | electronic:pir:sr505 [2026/09/06 20:09] (current) – tony | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| {{ : | {{ : | ||
| - | ^< | + | ^ PIR Description |
| ^Model|**MH-SR505 (HC-SR505)**| | ^Model|**MH-SR505 (HC-SR505)**| | ||
| - | ^Manufacturer|Szytf ?| | + | ^Manufacturer| | |
| ^Operating voltage|4.5 - 20V| | ^Operating voltage|4.5 - 20V| | ||
| ^Quiescent Current|60µA| | ^Quiescent Current|60µA| | ||
| Line 15: | Line 15: | ||
| ^Sensor lens size|10mm| | ^Sensor lens size|10mm| | ||
| - | ====Related datasheets==== | + | Arduino test code: |
| + | < | ||
| + | #define LED 13 //Assume the Arduino has an LED on D13 | ||
| + | |||
| + | void setup() { | ||
| + | pinMode(PIR_MOTION_SENSOR, | ||
| + | pinMode(LED, | ||
| + | digitalWrite(LED, | ||
| + | } | ||
| + | |||
| + | void loop() { | ||
| + | int sensorValue | ||
| + | if(sensorValue | ||
| + | digitalWrite(LED, | ||
| + | else | ||
| + | digitalWrite(LED, | ||
| + | }</ | ||
| + | \\ | ||
| + | |||
| + | ==== Datasheets | ||
| * {{: | * {{: | ||
| * [[https:// | * [[https:// | ||
| - | \\ | ||
| \\ | \\ | ||
| + | * Module schematic similar to this:\\ | ||
| + | {{https:// | ||
| + | |||
| + | \\ | ||
| ---- | ---- | ||
| - | ===== Examples | + | ===== Examples ===== |
| {{: | {{: | ||
| Line 32: | Line 54: | ||
| {{: | {{: | ||
| - | {{: | + | {{: |
| + | (The resistor labeled 180 (18Ω ?) actually appears to measure about 150k) | ||
| - | {{https:// | + | {{:electronic:pir: |