mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-01-16 18:30:57 +00:00
boardloader: use PVD level 4
This commit is contained in:
parent
30ddb53c11
commit
a08f18c2ce
@ -65,13 +65,12 @@ void periph_init(void)
|
|||||||
__HAL_RCC_GPIOD_CLK_ENABLE();
|
__HAL_RCC_GPIOD_CLK_ENABLE();
|
||||||
|
|
||||||
// enable the PVD (programmable voltage detector).
|
// enable the PVD (programmable voltage detector).
|
||||||
// select the "2.7V" threshold (level 5). the typical electrical
|
// select the "2.6V" threshold (level 4).
|
||||||
// characteristic values are similar to BOR level 3.
|
|
||||||
// this detector will be active regardless of the
|
// this detector will be active regardless of the
|
||||||
// flash option byte BOR setting.
|
// flash option byte BOR setting.
|
||||||
__HAL_RCC_PWR_CLK_ENABLE();
|
__HAL_RCC_PWR_CLK_ENABLE();
|
||||||
PWR_PVDTypeDef pvd_config;
|
PWR_PVDTypeDef pvd_config;
|
||||||
pvd_config.PVDLevel = PWR_PVDLEVEL_5;
|
pvd_config.PVDLevel = PWR_PVDLEVEL_4;
|
||||||
pvd_config.Mode = PWR_PVD_MODE_IT_RISING_FALLING;
|
pvd_config.Mode = PWR_PVD_MODE_IT_RISING_FALLING;
|
||||||
HAL_PWR_ConfigPVD(&pvd_config);
|
HAL_PWR_ConfigPVD(&pvd_config);
|
||||||
HAL_PWR_EnablePVD();
|
HAL_PWR_EnablePVD();
|
||||||
|
Loading…
Reference in New Issue
Block a user