Project

General

Profile

Statistics
| Branch: | Revision:

root / scout_avr / src / cliffSensor.h @ c06735bb

History | View | Annotate | Download (434 Bytes)

1
#ifndef _CLIFFSENSOR_H_
2
#define _CLIFFSENSOR_H_
3

    
4
#include <avr/io.h>
5
#include <avr/interrupt.h>
6

    
7
void cliffSensor_init(void);
8
bool read_cliffSensor_front(void);
9
bool read_cliffSensor_left(void);
10
bool read_cliffSensor_right(void);
11

    
12
/* The returned result is in the form of left_front_right; For example, if both left
13
   and front sensors detect a cliff, the returned value is 0b110 */
14
unsigned char read_cliffSensor_all(void);
15

    
16
#endif