Code for autonomous rover for Sparkfun AVC. DataBus won 3rd in 2012 and the same code was used on Troubled Child, a 1986 Jeep Grand Wagoneer to win 1st in 2014.
Dependencies: mbed Watchdog SDFileSystem DigoleSerialDisp
Diff: SystemState.h
- Revision:
- 1:cb84b477886c
- Parent:
- 0:a6a169de725f
- Child:
- 3:42f3821c4e54
--- a/SystemState.h Mon May 27 13:26:03 2013 +0000 +++ b/SystemState.h Tue May 28 13:58:35 2013 +0000 @@ -1,7 +1,7 @@ #ifndef _SYSTEMSTATE_H #define _SYSTEMSTATE_H -#define SSBUF 0x2F +#define SSBUF 0x3F // 0b0000 0011 1111 1111 /** System State is the main mechanism for communicating current realtime system state to * the rest of the system for logging, data display, etc. @@ -36,7 +36,8 @@ * rrEncSpeed right rear encoder speed * encHeading estimated heading based on encoder readings ****** Estimated Position and Heading - * estHeading estimated heading in degrees, this is the robot's reference for heading + * estLagHeading estimated heading in degrees, lagged to sync with gps + * estHeading estimated current heading * estLatitude estimated latitude in fractional degrees (e.g., 39.123456) * estLongitude estimated longitude in fractional degrees (e.g., -104.123456) * estNorthing some algorithms use UTM. Estimated UTM northing @@ -66,18 +67,11 @@ float gpsSpeed_mps; float gpsHDOP; int gpsSats; - - double gpsLatitude2; - double gpsLongitude2; - float gpsCourse_deg2; - float gpsSpeed_mps2; - float gpsHDOP2; - int gpsSats2; - float lrEncDistance, rrEncDistance; float lrEncSpeed, rrEncSpeed; float encHeading; float estHeading; + float estLagHeading; double estLatitude, estLongitude; //double estNorthing, estEasting; float estX, estY; @@ -86,10 +80,7 @@ float distance; float gbias; float errAngle; - float leftRanger; - float rightRanger; - float centerRanger; - float crossTrackErr; + float steerAngle; } SystemState; #endif \ No newline at end of file