34 #include "dev/pir-sensor.h"
36 #include "dev/hwconf.h"
38 const struct sensors_sensor pir_sensor;
40 static unsigned int pir;
43 HWCONF_PIN(PIR, 1, PIR_IRQ());
44 HWCONF_IRQ(PIR, 1, PIR_IRQ());
51 sensors_changed(&pir_sensor);
62 configure(
int type,
int value)
72 if(!PIR_IRQ_ENABLED()) {
73 irq_port1_activate(PIR_IRQ(), irq);
78 irq_port1_deactivate(PIR_IRQ());
91 return PIR_IRQ_ENABLED();
96 SENSORS_SENSOR(pir_sensor, PIR_SENSOR,
97 value, configure, status);