cancel
Showing results for 
Search instead for 
Did you mean: 

MCU Boot Issue - STM32L0

Jagannathan
Associate

We are using the STM32L071KZU6 in one of our designs and are facing an issue with bootloader communication over I2C. Specifically, some boards fail to enter the bootloader or respond on the I2C bus, while others function normally. Below are the details of our observations:

  1. The MCU is programmed by a CX3 host over I2C.
    On some boards, the MCU does not respond to the I2C address with an ACK during bootloader flashing.
  2. We have monitored BOOT0, nRST, and I2C lines on both working and non-working boards, and the signal waveforms appear identical.
  3. In boards where the issue occurs, once the device successfully flashes even once (randomly), it continues to function correctly thereafter with no further flashing issues.
  4. We have tried various I2C clock frequencies, ranging from 400 kHz down to 10 kHz, with no consistent improvement.

All other electrical and mechanical aspects (including pull-ups on I2C, supply stability, and reset timing) have been reviewed and appear nominal.

We would appreciate your assistance in identifying possible causes or further debugging steps for this inconsistent behavior with the bootloader over I2C.

Thanks and Best Regards,

Jagannathan R

1 REPLY 1
Ozone
Principal

I don't have any specific experience with the STM32L071, to put that upfront.

But you are speaking about the ROM bootloader code here, implemented by ST.
I'm pretty sure they will not publish the source code here, and point you to the documentation and respective ANs instead.

I would try the following things:
  - repeat the attempts to send the initial ID value to get into the BL
  - vary the timing before starting the communication
  - try a reset (via nRST) after a failed attempt, and retry


I have experienced a few surprises when dealing with sparsely documented ROM bootloaders of other (proprietary) architectures.