Skip to content

Commit

Permalink
brain/brainre1: make RCC flags like other targets
Browse files Browse the repository at this point in the history
This was preventing reset reasons from properly displaying-- because
the reset reason flags were cleared before the alarms library was
initialized.
  • Loading branch information
mlyle committed Jul 17, 2016
1 parent e817068 commit c346404
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions flight/targets/brain/fw/pios_board.c
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,6 @@ void PIOS_Board_Init(void) {
PIOS_HAL_Panic(PIOS_LED_ALARM, PIOS_HAL_PANIC_FILESYS);
#endif /* PIOS_INCLUDE_FLASH */

RCC_ClearFlag(); // The flags cleared after use

/* Initialize UAVObject libraries */
UAVObjInitialize();

Expand All @@ -285,6 +283,7 @@ void PIOS_Board_Init(void) {

/* Initialize the alarms library */
AlarmsInitialize();
PIOS_RESET_Clear();

/* Initialize the task monitor library */
TaskMonitorInitialize();
Expand Down
3 changes: 1 addition & 2 deletions flight/targets/brainre1/fw/pios_board.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,8 +275,6 @@ void PIOS_Board_Init(void) {

#endif /* PIOS_INCLUDE_FLASH */

RCC_ClearFlag(); // The flags cleared after use

/* Initialize UAVObject libraries */
UAVObjInitialize();

Expand Down Expand Up @@ -316,6 +314,7 @@ void PIOS_Board_Init(void) {

/* Initialize the alarms library */
AlarmsInitialize();
PIOS_RESET_Clear();

/* Initialize the task monitor library */
TaskMonitorInitialize();
Expand Down

0 comments on commit c346404

Please sign in to comment.