AP_Math: fixed example build

This commit is contained in:
Andrew Tridgell 2013-08-05 12:37:51 +10:00
parent a33573352e
commit 9cb6c987d4

View File

@ -73,11 +73,11 @@ static void test_one_offset(const struct Location &loc,
loc2 = loc;
uint32_t t1 = hal.scheduler->micros();
location_offset(&loc2, ofs_north, ofs_east);
location_offset(loc2, ofs_north, ofs_east);
hal.console->printf("location_offset took %u usec\n",
(unsigned)(hal.scheduler->micros() - t1));
dist2 = get_distance(loc, loc2);
bearing2 = get_bearing_cd(&loc, &loc2) * 0.01;
bearing2 = get_bearing_cd(loc, loc2) * 0.01;
float brg_error = bearing2-bearing;
if (brg_error > 180) {
brg_error -= 360;