33#include "lib/sensors.h"
34#include "dev/hwconf.h"
35#include "dev/button-sensor.h"
36#include "isr_compat.h"
40static struct timer debouncetimer;
41static int status(
int type);
43HWCONF_PIN(BUTTON, 2, 7);
44HWCONF_IRQ(BUTTON, 2, 7);
49 if(BUTTON_CHECK_IRQ()) {
66configure(
int type,
int c)
71 if(!status(SENSORS_ACTIVE)) {
73 BUTTON_IRQ_EDGE_SELECTD();
94 return BUTTON_IRQ_ENABLED();
100 value, configure, status);
#define CLOCK_SECOND
A second, measured in system clock time.
void timer_set(struct timer *t, clock_time_t interval)
Set a timer.
int timer_expired(struct timer *t)
Check if a timer has expired.
SENSORS & button_sensor
Exports global symbols for the sensor API.