AP_NOTIFY: RTK GPS visual notification through faster blink

This commit is contained in:
Niels Joubert 2014-06-01 01:07:20 -07:00 committed by Andrew Tridgell
parent 398f32d538
commit a251d0010a

View File

@ -209,9 +209,25 @@ void ToshibaLED::update_colours(void)
// flashing blue if disarmed with no gps lock // flashing blue if disarmed with no gps lock
switch(step) { switch(step) {
case 0: case 0:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = brightness;
}
break;
case 1: case 1:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = TOSHIBA_LED_OFF;
}
break;
case 2: case 2:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = brightness;
}
break;
case 3: case 3:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = TOSHIBA_LED_OFF;
}
break;
case 4: case 4:
_red_des = TOSHIBA_LED_OFF; _red_des = TOSHIBA_LED_OFF;
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D) { if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D) {
@ -225,9 +241,27 @@ void ToshibaLED::update_colours(void)
} }
break; break;
case 5: case 5:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = TOSHIBA_LED_OFF;
}
break;
case 6: case 6:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = brightness;
}
break;
case 7: case 7:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = TOSHIBA_LED_OFF;
}
break;
case 8: case 8:
if (AP_Notify::flags.gps_status >= AP_GPS::GPS_OK_FIX_3D_DGPS) {
_green_des = brightness;
}
break;
case 9: case 9:
// all off // all off
_red_des = TOSHIBA_LED_OFF; _red_des = TOSHIBA_LED_OFF;