cancel
Showing results for 
Search instead for 
Did you mean: 

NUCLEO-H7S3L8 HSE times out

qua
Senior

I am trying to set up a basic USB project on a NUCLEO-H7S3L8. It works okay with the HSI, but I need the HSE. I can see that the board has a 24MHz crystal fitted and resistors on SB14 and SB15. It's unmodified from the factory.

HAL_RCC_OscConfig() always returns with a timeout when trying to activate the HSE. I've tried various settings but can't get it to work.

I have attached my .ico file. The code is just what CubeMX generates. Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions

So here ioc , only using internal flash.

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

View solution in original post

26 REPLIES 26
AScha.3
Super User

Did you set it like this ?

AScha3_0-1759756684796.png

+ in clock tree set the 24M

AScha3_1-1759756733437.png

It should work then. (My H7S3 does.)

 

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

qua_0-1759757349801.png

 

qua_1-1759757370871.png

Looks like it is set correctly.

Did you set it like this ?

AScha3_1-1759758741512.png

 

... and USB:

AScha3_0-1759758704754.png

 

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

qua_0-1759760790473.png

 

So to check, the HSE crystal is ok , running, do a simple test:

make new -> stm32 project -> select just the H7S3L8H cpu -> give it a name, finish.

Then

- set only for "boot" , so its all in flash

- set RCC HSE , LDO, scale0

- set HSE 24M , clock tree to 600M core, etc.

- set debug trace async

- cortexM7 all caches on

(if you like, set port pin toggle an onboard led)

- generate code

- compile + debug

-- it should run (mine does).

 

If you feel a post has answered your question, please click "Accept as Solution".
mƎALLEm
ST Employee

Hello,

I tested your ioc file and generated a project and it's working fine from my side on a NUCLEO-H7S3L8.

May be you need to check OSC_OUT pin with an oscilloscope:

mALLEm_0-1759829316359.png

I suspect an issue in your board.

Do you have another board that you can run the test with?

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.
qua
Senior

AScha.3 that works for me too.  mƎALLEm I can see a 24MHz sine wave on that pin.

I have made some progress though. I found that certain settings that CubeMX says are okay don't actually seem to work. I initially had the HSE divided by 12 into the PLLs. Changing it to divided by 2 (and adjusting the multiplier to give 600MHz) allows it to get past setting the system clock.

It's odd that the timeout is with setting up the HSE rather than the PLL, and odd that it works for other people. I will continue to investigate.

qua
Senior

I think this is that old issue with CubeMX where sometimes it just doesn't build working code, but if you change things enough eventually whatever needs to be fixed gets fixed and the code is okay. Copying the .ico file to a new project works for me too.

I am not able to use USB CDC to work, but it's probably the same sort of bug.


@qua wrote:

Copying the .ico file to a new project works for me too.


Is there any specific difference in the path?

Did you detect any difference in the generated code between both cases?

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.