Skip to main content
PGall.4
Associate
April 4, 2023
Solved

Hi everyone! I want to know when the MCU STM32L4A is in system bootloader (by using a LED). Is this possible? Many thanks!

  • April 4, 2023
  • 6 replies
  • 1500 views

..

This topic has been closed for replies.
Best answer by Peter BENSCH

Welcome, @PGall.4​, to the community!

If you are talking about the internal bootloader in each STM32, its activity cannot be indicated with an LED.

However, if you write your own bootloader, you have all the freedom, but also the disadvantage of losing user flash.

Does it answer your question?

Regards

/Peter

6 replies

Peter BENSCH
Peter BENSCHBest answer
ST Technical Moderator
April 4, 2023

Welcome, @PGall.4​, to the community!

If you are talking about the internal bootloader in each STM32, its activity cannot be indicated with an LED.

However, if you write your own bootloader, you have all the freedom, but also the disadvantage of losing user flash.

Does it answer your question?

Regards

/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Tesla DeLorean
Guru
April 4, 2023

Have a GPIO / LED that lights after reset​, have your code clear it.

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
Peter BENSCH
ST Technical Moderator
April 4, 2023

Good idea, but requires a little extra hardware, e.g. an external flipflop.

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
PGall.4
PGall.4Author
Associate
April 4, 2023

Hi Peter!

Yes, I was talking about internal bootloader. We wanted to ensure that the MCU wasn't in that state with a visual indication,

Many thanks!

waclawek.jan
Super User
June 12, 2023

I know this is a 2 month old thread resurrected probably by this badly handled spamming wave, but maybe this is a topic worth another answer.

The default bootloader sets pullups/pulldowns on some pins. AN2606 probably does not deal with this adequately and ST for whatever weird reason refuses to publish the bootloader sources, but you can disassemble/single-step the bootloader to see which ones - e.g. UART Rx pins. The pullups/pulldowns are nominally 40kOhm, and these days there are LEDs out there which light up quite adequately with currents like that.

Whether it's worth to spend a pin on this function is a question for OP to decide.

JW

Peter BENSCH
ST Technical Moderator
June 12, 2023

Very good idea that is worth pursuing.

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.