cancel
Showing results for 
Search instead for 
Did you mean: 

stm32u575zi - Unable to jump to system bootloader

haresh05
Associate

I want to use the uart interface from system bootloader to update the application in stm32u575.

For that I am trying to jump to the bootloader from the application. I have checked the bootloader address from an2606 document. Below is the code I am using.

 

#define BOOT_ADDR 0x0BF90000 // my MCU boot code base address
#define MCU_IRQS 125u // no. of NVIC IRQ inputsvoid JumpToBootloader(void)

void jumpToBootloader() {
void (*SysMemBootJump)(void) = (void*)(*((volatile uint32_t*) (BOOT_ADDR + 4U)));
 __set_MSP(*(uint32_t *)BOOT_ADDR);

/* Disable all interrupts */
 __disable_irq();

/* Set the clock to the default state */
 HAL_UART_DeInit(&huart1);
 HAL_RCC_DeInit();
 HAL_DeInit();


/* Clear Interrupt Enable Register & Interrupt Pending Register */
for (uint8_t i = 0; i < (MCU_IRQS + 31u) / 32; i++)
 {
 NVIC->ICER[i]=0xFFFFFFFF;
 NVIC->ICPR[i]=0xFFFFFFFF;
 }

/* Disable Systick timer */
 SysTick->CTRL = 0;
 SysTick->LOAD = 0;
 SysTick->VAL = 0;

/* Re-enable all interrupts */
 __enable_irq();
 SysMemBootJump();
}

 

 

After this to verify I am checking in STM32CubeProgrammer, if device is detected in dfu under usb mode.

But it always shows "No DFU detected".

 

Can anyone help what I am doing wrong or missing?

2 REPLIES 2
Rim LANDOLSI
ST Employee

Hello @haresh05  and welcome to the community,

 

Could you download the DFU USB driver from this site which allows the device to be enumerated as an "STM Device in DFU Mode" and check if the problem persists?

 

Thanks,

Rim.

Chhetri
Associate

Hi,
Any solution to this I'm currently stuck with the same issue?

Thanks.

R.C