bootloader: disable clocks after domains used

This commit is contained in:
King Kévin 2020-06-14 19:02:37 +02:00
parent a310fb402a
commit e85af656d3
1 changed files with 3 additions and 0 deletions

View File

@ -62,6 +62,9 @@ void main(void)
dfu_force = true; // DFU mode forced
}
#endif // defined(DFU_FORCE_PIN)
rcc_periph_clock_disable(RCC_AFIO); // disable alternate function domain to put it back to default
rcc_periph_reset_pulse(GPIO_RST(DFU_FORCE_PIN)); // reset pin GPIO domain
rcc_periph_clock_disable(GPIO_RCC(DFU_FORCE_PIN)); // disable pin GPIO domain
}
// start application if valid