Revision 423
fixed robot slave and cleaned up some wireless stuff
robot_slave.c | ||
---|---|---|
8 | 8 |
#include <dragonfly_lib.h> |
9 | 9 |
#include <colonet_dragonfly.h> |
10 | 10 |
#include <wireless.h> |
11 |
#include <wl_token_ring.h> |
|
11 | 12 |
#include <serial.h> |
12 | 13 |
#include <stdio.h> |
13 | 14 |
|
... | ... | |
20 | 21 |
wl_init(); |
21 | 22 |
colonet_init(); |
22 | 23 |
|
23 |
|
|
24 |
//orb_set_color(YELLOW); |
|
25 |
orb_set_color(GREEN); |
|
26 |
usb_puts("test!\n"); |
|
24 |
wl_token_ring_register(); |
|
27 | 25 |
|
28 |
while(1) { |
|
29 |
wl_do(); |
|
26 |
if (wl_token_ring_join() == 0) { |
|
27 |
orb_set_color(GREEN); |
|
28 |
//usb_puts("test!\n"); |
|
29 |
|
|
30 |
while(1) { |
|
31 |
wl_do(); |
|
32 |
} |
|
33 |
} else { |
|
34 |
orb_set_color(RED); |
|
30 | 35 |
} |
31 |
|
|
36 |
|
|
37 |
while(1); |
|
38 |
|
|
32 | 39 |
return 0; |
33 | 40 |
} |
Also available in: Unified diff