Skip to main content
Associate II
April 22, 2025
Solved

STM32H723 GPIO Lock set after reset

  • April 22, 2025
  • 4 replies
  • 1126 views

I have a Nucleo-H723ZG board.  The GPIO lock bits are set at reset so I cannot set up the ports.  See Attached screenshot.  I can run code just fine and the original demo code did toggle the LEDs.

Am I missing something here? 

Best answer by waclawek.jan

> all of the GPIOA registers report 0xABFFFFFF

 

That's sign of GPIOA clock not being enabled in RCC.

JW

4 replies

TDK
Super User
April 22, 2025

Since all of the GPIOA registers report 0xABFFFFFF, I'm more inclined to believe this is a debugger/IDE issue.

"If you feel a post has answered your question, please click ""Accept as Solution""."
NiramasAuthor
Associate II
April 22, 2025

The memory dump shows the same values.

mƎALLEm
Technical Moderator
April 22, 2025

Hello @Niramas and welcome to the ST community,

I'm confused. You said:


@Niramas wrote:

I can run code just fine and the original demo code did toggle the LEDs.


The LEDs are toggling even the lock bits are set after reset?

To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.
NiramasAuthor
Associate II
April 22, 2025

The screenshot is not from the demo it is from our SW.  Notice it is stopped at the reset vector though.

NiramasAuthor
Associate II
April 22, 2025

The demo came pre loaded on the device and is gone now.

waclawek.jan
Super User
April 22, 2025

> all of the GPIOA registers report 0xABFFFFFF

 

That's sign of GPIOA clock not being enabled in RCC.

JW

TDK
Super User
April 22, 2025

I had always thought GPIOA clock was required to be enabled for SWD to be active and was therefore enabled by default. Testing it now, it clearly (a) isn't enabled by default and (b) doesn't need to be enabled for SWD to work.

"If you feel a post has answered your question, please click ""Accept as Solution""."
waclawek.jan
Super User
April 28, 2025

@TDK,

The exact effect of GPIO clock is not very clear from the documentation. I've seen hinted somewhere (in relationship to power consumption reduction), that you need it only to access the registers (which implies also that you need it to be able to read pins set as Input and change state of those set as Output), but once those are set e.g. to AF, you can switch the GPIO clock off - the muxes are set and the peripherals to which signals are connected use their own clock to sample or drive the signals.

JW

NiramasAuthor
Associate II
April 22, 2025

++++ Problem Solved ++++

 

Thank You