Revision 1401
Tested rangefinders to see if they are #define'd correctly. See data/rangefinder for details.
trunk/code/projects/test/test_rangefinder.c | ||
---|---|---|
46 | 46 |
// orbs RED when IR2 reads -1 |
47 | 47 |
// orbs GREEN when IR2 gets a useable reading |
48 | 48 |
// times out after TEST_TIME elapsed |
49 |
while (rtc_get() - start_time < TEST_TIME) {
|
|
50 |
distance = range_read_distance(IR2);
|
|
49 |
while (1) {
|
|
50 |
distance = range_read_distance(IR5);
|
|
51 | 51 |
// unusable reading |
52 | 52 |
if (distance == -1) |
53 | 53 |
orb_set_color(RED); |
trunk/code/projects/test/main.c | ||
---|---|---|
13 | 13 |
// RUN_TEST(testlcd); |
14 | 14 |
// RUN_TEST(testlights); |
15 | 15 |
// RUN_TEST(testmotors); |
16 |
// RUN_TEST(testrangefinder);
|
|
16 |
RUN_TEST(testrangefinder); |
|
17 | 17 |
// RUN_TEST(testtokenring); |
18 |
RUN_TEST(testwireless); |
|
18 |
// RUN_TEST(testwireless);
|
|
19 | 19 |
} |
20 | 20 |
|
21 | 21 |
return 0; |
trunk/code/projects/mapping/auto/Makefile | ||
---|---|---|
105 | 105 |
# gnu89 = c89 plus GCC extensions |
106 | 106 |
# c99 = ISO C99 standard (not yet fully implemented) |
107 | 107 |
# gnu99 = c99 plus GCC extensions |
108 |
CSTANDARD = -std=gnu99
|
|
108 |
CSTANDARD = -std=gnu89
|
|
109 | 109 |
|
110 | 110 |
# Place -D or -U options here |
111 | 111 |
CDEFS += -DF_CPU=$(F_CPU)UL |
Also available in: Unified diff