mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-22 01:12:31 +00:00
stm32: board_reset, change backup register
Change to be coherent with the change on NuttX upstream, in the future STM32_BKP_BASE will be removed. This is using the definition over stm32_rtc.h interface.
This commit is contained in:
committed by
Beat Küng
parent
76aa044105
commit
2b81331f8a
@@ -40,6 +40,7 @@
|
||||
#include <px4_config.h>
|
||||
#include <errno.h>
|
||||
#include <stm32_pwr.h>
|
||||
#include <stm32_rtc.h>
|
||||
#include <nuttx/board.h>
|
||||
|
||||
|
||||
@@ -61,7 +62,7 @@ int board_set_bootload_mode(board_reset_e mode)
|
||||
}
|
||||
|
||||
stm32_pwr_enablebkp(true);
|
||||
*(uint32_t *)STM32_BKP_BASE = regvalue;
|
||||
*(uint32_t *)STM32_RTC_BKR(0) = regvalue;
|
||||
stm32_pwr_enablebkp(false);
|
||||
return OK;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user