Project

General

Profile

Statistics
| Revision:

root / trunk / code / projects / colonet / utilities / manual_control / manualControlRobot / photovore.h @ 13

History | View | Annotate | Download (686 Bytes)

1 13 emarinel
#ifndef _PHOTOVORE_H_
2
#define _PHOTOVORE_H_
3
4
5
#define PHOTORESISTOR_LEFT AN1 //might be the opposite (Eugene)
6
#define PHOTORESISTOR_RIGHT AN2
7
8
//#define LIGHT_THRESHOLD 150 //hard coded for now...calculate dynamically later
9
#define LIGHT_THRESHOLD 210 //hard coded for now...calculate dynamically later
10
11
void do_photovore (void);
12
unsigned char get_light_status (unsigned char me);
13
void set_light_status (unsigned char robot, unsigned char lightstatus);
14
15
16
void sense_light (void);
17
inline char light_threshold(void);
18
19
20
//define an array of length MAX_ROBOTS that has
21
//1 if robot at index i can see the light, and 0
22
//if it cannot
23
//unsigned char robot_enlightenment[MAX_ROBOTS];
24
25
#endif