blob: 5b37587c54a803ed3755e63f1fcfa295c1d6cb3e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
#ifndef PIN_H
#define PIN_H
/* Number of user configurable I/O pins */
#define PIN_MAX 11
typedef enum {NONE, INPUT, INPUT_PULLUP, OUTPUT, OUTPUT_TIMER} pinmode_t;
int pin_config(int pin, pinmode_t mode);
pinmode_t pin_config_get(int pin);
int pin_read(int pin);
void pin_write(int pin, uint8_t val);
int pin_clockdiv_set(int pin, unsigned long divider);
long pin_clockdiv_get(int pin);
#endif /* PIN_H */
|