cancel
Showing results for 
Search instead for 
Did you mean: 

STM32U5A5 Nucleo, issue with CubeMX warning related to RCC and PWR setting

Riscy
Senior

I have Nucleo STM32U5A5 board where I experiment with the USBX interface based on demo code. I then created new project to experiment with GPDMA. Both IDE and MX are updated at the time of 30/Nov/23. 

It keep on repeating RCC/PWR setup warning or issue when I run generate code. When I went back to demo code: Ux_Device_CDC_ACM, I also generated the code from CubeMX with added USART2. It produce same RCC/PWR error. It seen to point to PWR privilege and RCC privilege (with !) on it. I have not activated trustzone. 

Can you advise what should I do about it, is there bug in these or workaround?

11 REPLIES 11
TDK
Guru

And what is the warning? Hover over it for more information.

Yellow warnings generally do not indicate issues and can be ignored. Red errors show actual issues.

If you feel a post has answered your question, please click "Accept as Solution".
Riscy
Senior

I attached some snapshots in a PDF file. 

I made 2nd new project to experiment more and I found the warning on RCC/PWR happened after I adjusted the clock tree from 4Mhz to 160Mhz. 

there no yellow box or red box in list and clock tree as shown. 

Trustzone is disabled. 

 

TDK
Guru

Doesn't look like you show the clock tree in the PDF. Presumably the error is in there.

Can you attach your IOC file. Rename it from .ioc to .txt to get around the inexplicable forum filter.

 

At a guess, increase the power regulator voltage scale to 1 to allow for higher clock speed.

TDK_0-1701447077009.png

 

If you feel a post has answered your question, please click "Accept as Solution".

Attached IOC with TXT

I checked the power parameter via RCC and found to be on Power Regulator Voltage Scale 1.

 

 

 

TDK
Guru

Okay, I can replicate. I can't really explain why that's happening, but changing RCC parameter to bypass, then back to crystal gets rid of the RCC warning. And unchecking and rechecking any option in PWR gets rid of the PWR warning. It then generates code without warning.

If you feel a post has answered your question, please click "Accept as Solution".
TDK
Guru

It looks like the toolchain parameter is not properly set in the IOC file that you sent. Setting it to STM32CubeIDE fixes the issue.

 

TDK_1-1701449544172.png

 

If you feel a post has answered your question, please click "Accept as Solution".
Riscy
Senior

Before I generated the code, I edited it with Visual Code and added as you indicated

ProjectManager.PreviousToolchain=STM32CubeIDE

I then saved the file and generated code via STM32CubeIDE, which still reports the error below.

  - Main Config: These peripherals still have some not configured or wrong parameter values: [PWR, RCC]

I inspected the ioc file and it reverted back to blank. 

ProjectManager.PreviousToolchain = 

How to generate code without clearing it?

Thanks

 

 

 

TDK
Guru

Did you also remove the isbadioc line?

File that works for me is attached.

 

If you feel a post has answered your question, please click "Accept as Solution".
Riscy
Senior

Ok

I have removed the isbadioc line (via Visual code) but now it mask out the Generate Code in the context menu from ioc filename in the STM32CubeIDE. I feel it outsmarted me to make progress!.