Subversion Repositories NaviCtrl

Rev

Rev 531 | Rev 533 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 531 Rev 532
Line 101... Line 101...
101
volatile FC_t FC;
101
volatile FC_t FC;
102
volatile u32 SPIWatchDog = 15000; // stop Navigation if this goes to zero
102
volatile u32 SPIWatchDog = 15000; // stop Navigation if this goes to zero
103
volatile u32 SD_WatchDog = 15000; // stop Logging if this goes to zero
103
volatile u32 SD_WatchDog = 15000; // stop Logging if this goes to zero
104
u32 CountGpsProcessedIn5Sec = 0,CountNewGpsDataIn5Sec = 0, FreqGpsProcessedIn5Sec = 0, FreqNewGpsDataIn5Sec = 0;
104
u32 CountGpsProcessedIn5Sec = 0,CountNewGpsDataIn5Sec = 0, FreqGpsProcessedIn5Sec = 0, FreqNewGpsDataIn5Sec = 0;
105
u8 NewWPL_Name = 0;
105
u8 NewWPL_Name = 0;
106
u32 MaxRadius_in_m = 0;
106
u32 MaxWP_Radius_in_m = 0;
107
s8 ErrorMSG[25];
107
s8 ErrorMSG[25];
Line 108... Line 108...
108
 
108
 
109
//----------------------------------------------------------------------------------------------------
109
//----------------------------------------------------------------------------------------------------
110
void SCU_Config(void)
110
void SCU_Config(void)
Line 335... Line 335...
335
                sprintf(ErrorMSG,"Magnet error    ");
335
                sprintf(ErrorMSG,"Magnet error    ");
336
                newErrorCode = 22;
336
                newErrorCode = 22;
337
                DebugOut.StatusRed |= AMPEL_COMPASS | AMPEL_NC;
337
                DebugOut.StatusRed |= AMPEL_COMPASS | AMPEL_NC;
338
                UART_VersionInfo.HardwareError[0] |= NC_ERROR0_COMPASS_VALUE;
338
                UART_VersionInfo.HardwareError[0] |= NC_ERROR0_COMPASS_VALUE;
339
        }
339
        }
340
        else if(((ErrorCheck_BL_MinOfMaxPWM == 40 && (FC.StatusFlags & FC_STATUS_FLY)) || ErrorCheck_BL_MinOfMaxPWM == 39) && !ErrorCode)
340
        else if(((ErrorCheck_BL_MinOfMaxPWM == 40  || ErrorCheck_BL_MinOfMaxPWM == 39) && (FC.StatusFlags & FC_STATUS_FLY)) && !ErrorCode)
341
        {
341
        {
342
                LED_RED_ON;
342
                LED_RED_ON;
343
                sprintf(ErrorMSG,"ERR:Motor restart  ");
343
                sprintf(ErrorMSG,"ERR:Motor restart  ");
344
                newErrorCode = 23;
344
                newErrorCode = 23;
345
                DebugOut.StatusRed |= AMPEL_BL;
345
                DebugOut.StatusRed |= AMPEL_BL;
Line 361... Line 361...
361
                DebugOut.StatusRed |= AMPEL_BL;
361
                DebugOut.StatusRed |= AMPEL_BL;
362
        }
362
        }
363
        else if((NCFlags & NC_FLAG_RANGE_LIMIT) && (FC.StatusFlags & FC_STATUS_FLY) && !ErrorCode)
363
        else if((NCFlags & NC_FLAG_RANGE_LIMIT) && (FC.StatusFlags & FC_STATUS_FLY) && !ErrorCode)
364
        {
364
        {
365
                LED_RED_ON;
365
                LED_RED_ON;
366
                sprintf(ErrorMSG,"ERR:GPS range  ");
366
                sprintf(ErrorMSG,"ERR:GPS WP range ");
367
                newErrorCode = 25;
367
                newErrorCode = 25;
368
                DebugOut.StatusRed |= AMPEL_NC;
368
                DebugOut.StatusRed |= AMPEL_NC;
369
        }
369
        }
370
        else if((!SD_SWITCH || (SDCardInfo.Valid == 0)) && Parameter.GlobalConfig3 & CFG3_NO_SDCARD_NO_START && !(FC.StatusFlags & FC_STATUS_FLY))
370
        else if((!SD_SWITCH || (SDCardInfo.Valid == 0)) && Parameter.GlobalConfig3 & CFG3_NO_SDCARD_NO_START && !(FC.StatusFlags & FC_STATUS_FLY))
371
        {
371
        {