cancel
Showing results for 
Search instead for 
Did you mean: 

Write and read on Secure Flash Memory - STM32U575ZIT6 Project and TrustZone

OTM98
Associate II

Hello everyone,

I hope this message finds you well. I'm currently working on a project based on the STM32U575ZIT6 microcontroller and have successfully read and written to the flash memory with TrustZone disabled. Now, I am looking to enable TrustZone and perform read and write operations within the secure flash memory zone.

I was wondering if anyone could provide guidance or share information on how to read and write on the secure flash memory on the STM32U575ZIT6 and if there's a way to determine the address range of the secure flash memory. Any insights or advice on this matter would be greatly appreciated.

Thank you in advance for your assistance!

Best regards,

1 ACCEPTED SOLUTION

Accepted Solutions
Jocelyn RICARD
ST Employee

Hello @OTM98 ,

The flash base address is 0x08000000.

When using TrustZone, you can access to same flash location using 0x0C000000 address. This is actually an alias.

You can find this mapping in the reference manual RM0456 Rev4 in Table 3 page 133 for instance.

Regarding your actual concern I would recommend having a look to the example provided in the CubeFW U5:

STM32Cube_FW_U5_V1.4.0\Projects\NUCLEO-U575ZI-Q\Examples\FLASH\FLASH_EraseProgram_TrustZone\

Best regards

Jocelyn

View solution in original post

2 REPLIES 2
Jocelyn RICARD
ST Employee

Hello @OTM98 ,

The flash base address is 0x08000000.

When using TrustZone, you can access to same flash location using 0x0C000000 address. This is actually an alias.

You can find this mapping in the reference manual RM0456 Rev4 in Table 3 page 133 for instance.

Regarding your actual concern I would recommend having a look to the example provided in the CubeFW U5:

STM32Cube_FW_U5_V1.4.0\Projects\NUCLEO-U575ZI-Q\Examples\FLASH\FLASH_EraseProgram_TrustZone\

Best regards

Jocelyn

Thank you for your detailed explanation and guidance. I appreciate your assistance in addressing the concerns related to the flash base address and the use of TrustZone. The information you provided, including the reference to the mapping in the reference manual and the example in the CubeFW, is valuable and will be helpful in resolving the issue.

Once again, thank you for your support and guidance.

Best regards,