cancel
Showing results for 
Search instead for 
Did you mean: 

Beginner problem with NUCLEO-L4R5ZI and blinking LED

jeffry159
Associate

Hi,

I'm realy new to this and I'm using NUCLEO-L4R5ZI with Ac6 System Workbench for STM32. I've found the board and initialized all peripherals with their default settings inside STM32CubeMX. Then I've generated the code for System Workbench and imported it inside.

Inside the main while loop I've written just two lines of code for toggling the LED which I assume are correct.

while (1)
  {
 
  /* USER CODE END WHILE */
 
  /* USER CODE BEGIN 3 */
	  HAL_GPIO_TogglePin(GPIOB, GPIO_PIN_7);
	  HAL_Delay(500);
 
  }
  /* USER CODE END 3 */

I try to flash the file nothing happens (not blinking on any of the User LEDs). Project builds itself without any errors. Only error I get is while flashing, but its finishes successfully. Below is the whole log from programing.

Another thing is when I try to program my board with default example everything works just fine and the log is still the same (even with that error).

Any help would be appreciated!

1 ACCEPTED SOLUTION

Accepted Solutions
Khouloud GARSI
Lead II

Hi @jeffry159​ ,

You're using the HSE oscillator as a clock source. However, on the Nucleo 144 board, the crystal is not provided.

You may use the HSI or MSI instead.

Khouloud.

View solution in original post

3 REPLIES 3
Khouloud GARSI
Lead II

Hi @jeffry159​ ,

Pay attention to the clock configuration. I suspect that's the cause of the issue.

You're using STM32CubeMX, you may share a screenshot of the "clock configuration" window.

Khouloud.

jeffry159
Associate

Here is my clock configuration window.0690X000006Bw1wQAC.png

It seems there are some differences, not sure what is each branch means yet. So should I try modifing the clock setting inside STM32CubeMX with working code as guide or is there any other way to set it "right" ?

Khouloud GARSI
Lead II

Hi @jeffry159​ ,

You're using the HSE oscillator as a clock source. However, on the Nucleo 144 board, the crystal is not provided.

You may use the HSI or MSI instead.

Khouloud.