Skip to main content
TPham.10
Associate II
September 28, 2018
Question

I can't clear RCC flag (RCC_ClearFlag in stm32f103)

  • September 28, 2018
  • 1 reply
  • 886 views

Hi guys!

I have a problem with stm32f103, I want to check MCU Reset cause, I use RCC_GetFlagStatus is ok, after that i'll clear rcc flag but It's not working & MCU not working when user RCC_ClearFlag. If i remove RCC_ClearFlag function then MCU work normal but RCC Register Reset don't clear so i don't know cause MCU reset.

I try RCC -> CSR |=0x01000000 set RMVF to clear flag but it also not working

Can you help me, thank a lot!

    This topic has been closed for replies.

    1 reply

    TPham.10
    TPham.10Author
    Associate II
    September 28, 2018

    I debug then see clear reset flag success but after that MCU not working if reset again or on/off power. remove funtion RCC_ClearFlag and program again turn off all power and turn on again mcu will working.