root / trunk / code / projects / traffic_navigation / validTurns-test.c @ 1886
History | View | Annotate | Download (502 Bytes)
1 |
#include <dragonfly_lib.h> |
---|---|
2 |
#include "intersectData.h" |
3 |
#include "validTurns.h" |
4 |
|
5 |
#define TEST_VALIDTURNS
|
6 |
|
7 |
#ifdef TEST_VALIDTURNS
|
8 |
|
9 |
int main(){
|
10 |
|
11 |
dragonfly_init(ALL_ON); |
12 |
orb1_set_color(YELLOW); |
13 |
|
14 |
initializeData(); |
15 |
|
16 |
int barcode = 0; |
17 |
|
18 |
if (validateTurn(barcode, ILEFT)==ILEFT) orb1_set_color(GREEN);
|
19 |
|
20 |
delay_ms(100);
|
21 |
orb1_set_color(PINK); |
22 |
delay_ms(50);
|
23 |
|
24 |
if (validateTurn(barcode, IUTURN)==IUTURN) orb1_set_color(GREEN);
|
25 |
|
26 |
delay_ms(100);
|
27 |
orb1_set_color(RED); |
28 |
delay_ms(50);
|
29 |
|
30 |
while (1){} |
31 |
|
32 |
} |
33 |
|
34 |
#endif
|