Have been trying to get the blink sketch to work on my STM32G491 Nucleo board (NUCLEO-G491RE), but it refuses to work, although the board programs successfully.
Tools Version
Arduino IDE : 2.3.2
Core: STM32 MCU Based Boards by STMicroelectronics v2.7.1
output log
Sketch uses 15988 bytes (3%) of program storage space. Maximum is 524288 bytes.
Global variables use 1288 bytes (0%) of dynamic memory, leaving 129784 bytes for local variables. Maximum is 131072 bytes.
-------------------------------------------------------------------
STM32CubeProgrammer v2.15.0
-------------------------------------------------------------------
ST-LINK SN : 002400293532510531333430
ST-LINK FW : V3J13M4
Board : NUCLEO-G491RE
Voltage : 3.29V
SWD freq : 8000 KHz
Connect mode: Under Reset
Reset mode : Hardware reset
Device ID : 0x479
Revision ID : Rev Z
Device name : STM32G491xC/E
Flash size : 512 KBytes
Device type : MCU
Device CPU : Cortex-M4
BL Version : 0xD2
Memory Programming ...
Opening and parsing file: Blink.ino.bin
File : Blink.ino.bin
Size : 16.10 KB
Address : 0x08000000
Erasing memory corresponding to segment 0:
Erasing internal memory sectors [0 8]
Download in Progress:
File download complete
Time elapsed during download operation: 00:00:00.584
RUNNING Program ...
Address: : 0x8000000
Application is running, Please Hold on...
Start operation achieved successfully
Code: Select all
#define LED_BUILTIN PA5
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
Settings attached. Any tips on getting it to work would be highly appreciated.LD2 USER
This green LED is a user LED connected to STM32G4 I/O PA5 (SB6 ON) corresponding to the ARDUINO® D13.
To light LED LD2, a high logic state “1” must be written in the corresponding GPIO PA5. A transistor is used to
drive the LED LD2. LD2 consumption does not impact the VDD STM32G4 power measurement, since LD2 is
isolated from it.