mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-02-18 08:54:15 +01:00
OP-815 changed PIOS_WDG_RegisterFlag to reset the WDG to prevent timeouts during module initialization
This commit is contained in:
parent
a4faa22c4b
commit
153db89663
@ -69,7 +69,7 @@ int main()
|
||||
* (see pios_board.c for your arch)
|
||||
* */
|
||||
PIOS_Board_Init();
|
||||
PIOS_WDG_Clear();
|
||||
|
||||
#ifdef ERASE_FLASH
|
||||
PIOS_Flash_Jedec_EraseChip();
|
||||
#if defined(PIOS_LED_HEARTBEAT)
|
||||
|
@ -94,6 +94,9 @@ uint16_t PIOS_WDG_Init()
|
||||
*/
|
||||
bool PIOS_WDG_RegisterFlag(uint16_t flag_requested)
|
||||
{
|
||||
// flag are being registered so we are in module initialization phase
|
||||
// clear the WDG to prevent timeout while initializing modules. (OP-815)
|
||||
PIOS_WDG_Clear();
|
||||
|
||||
/* Fail if flag already registered */
|
||||
if(wdg_configuration.used_flags & flag_requested)
|
||||
|
@ -98,7 +98,10 @@ uint16_t PIOS_WDG_Init()
|
||||
*/
|
||||
bool PIOS_WDG_RegisterFlag(uint16_t flag_requested)
|
||||
{
|
||||
|
||||
// flag are being registered so we are in module initialization phase
|
||||
// clear the WDG to prevent timeout while initializing modules. (OP-815)
|
||||
PIOS_WDG_Clear();
|
||||
|
||||
/* Fail if flag already registered */
|
||||
if(wdg_configuration.used_flags & flag_requested)
|
||||
return false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user