Skip to main content
MTapu.1
Associate
April 28, 2023
Question

Timer and uart does not work at the same stime

Hello,

In my code there are custom bootloader part and user application part. I init watchdog timer and refresh watchdog timer in the bootloader part and user app part. The code goes to user app from bootloader by jumping address. Likewise, The code goes to booloader part from user app part bu jumping use app address. There is no problem when the code jumping from bootloader part to user app part. But there is a ridiculous problem when it jumping from user app to bootloader part. The problem is it stuck in uart interrupt after uart initialization in the bootloader part. When ı look at interrupt flag, I see uart frame error is set. How to overcome this problem.

Sincereley,

This topic has been closed for replies.

5 replies

Senior III
April 28, 2023

You must deinitialize UART before jump to bootloader

Dudo
MTapu.1
MTapu.1Author
Associate
April 28, 2023

I have already done.

Senior III
April 28, 2023

Could you paste your code related to deinitialize before jump to bootloader?

Dudo
MTapu.1
MTapu.1Author
Associate
April 28, 2023

HAL_UART_MspDeInit(&huart1);

//deinit other communication peripherals

HAL_RNG_MspDeInit(&hrng);

HAL_RTC_MspDeInit(&hrtc);

HAL_ICACHE_DeInit();

SCB->VTOR = (sIAPStartAddress);

JumpToBootloader();

Senior III
April 28, 2023