Closed Oliver0804 closed 2 months ago
Hi @Oliver0804,
I see you're using an stlink probe to upload the firmware. Could you please try to lanuch a debugging session to figure out if the firmware evens starts.?
board_upload.offset_address =0x08000000
I believe this line is unnecessary, this address is used by default.
Hi , @valeros Thank you for your response.
Attached is the result of compiling with the settings I added.
In fact, I didn't include them initially, but the LED still couldn't blink properly.
Hi @Oliver0804,
I see you're using an stlink probe to upload the firmware. Could you please try to lanuch a debugging session to figure out if the firmware evens starts.?
board_upload.offset_address =0x08000000
I believe this line is unnecessary, this address is used by default.
So what about debugging, have you tried lanching a debugging session.
After entering Debug mode, I noticed that it stopped at:
if (HAL_RCC_OscConfig(&RCC_OscInitStruct) != HAL_OK) {
Error_Handler(); <--stop here
}
In the Arduino IDE you selected a different board, so what's your board exactly? Is it STM32F030F4 Demo Board?
In the Arduino IDE you selected a different board, so what's your board exactly? Is it STM32F030F4 Demo Board?
In the Arduino IDE, I chose the "Generic F030F4px" board, but in PlatformIO, the closest option available is the "demo_f030f4" board.
I noticed that the difference might be whether to use an external oscillator, but currently, the hardware I'm successfully running on Arduino IDE doesn't have an external oscillator.
Unfortunately, the Generic F0 targets are not supported at the moment and the closest board doesn't mean it will work. As you correctly mentioned, there is probably a discrepancy in the clock configuration, as STM32F030F4 Demo Board indeed has an external oscillatior.
@valeros Thank you for your reply. However, I'm wondering if it's possible to work with the platform in ArduinoIDE. So, is the board manager used by PlatformIO different from STM32duino's? https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json
So, is the board manager used by PlatformIO different from STM32duino's?
That's true, PlatformIO supports its own set of boards that may not cover all targets available in STM32duino.
I see, thanks, I'll close this issue first, thanks for your help!
I downloaded using the Arduino IDE, and it successfully made the LED blink, just to confirm that my hardware is fine. However, when I use the Arduino framework under PlatformIO, it doesn't work properly, and I get logs like this.
The logs show that the code has been successfully flashed, but the LED doesn't blink as expected, unlike the Arduino version.
Could it be that I'm missing some settings in the .ini file?