2

I've been trying to figure out how to upload a code to a STM32103c8T bulepill board. My setup is

1- MacOs Catalina 2- STM32103c8T bulepill board 3- SLAB UART USB-TTL CP2012 V3.0 4- Platformio IDE 5- STM32 CUBE Programmer software which detects and connects to my board through UART. meaning that It has no problem connecting but there are issue with setting up the Platformio

BTW I am new to the ARM world and I bought this board to examine its speed and deep sleep and interrupt, I mean all the things that an Arduino Uno can't do.

The thing is I have no idea on how to setup the platformio.ini File to comunicate with the board using the UART method and not requesting ST-link dongle!

What I have now in Platformio.ini is:

[env:bluepill_f103c8]

platform = ststm32
board = bluepill_f103c8
framework = arduino
upload_protocol = stlink
upload_port = tty.slab_usbtoUART

and when trying to upload the program i get:

Uploading .pio/build/bluepill_f103c8/firmware.elf xPack OpenOCD, x86_64 Open On-Chip Debugger 0.10.0+dev-00378-ge5be992df (2020-06-26-12:31) Licensed under GNU GPL v2 For bug reports, read http://openocd.org/doc/doxygen/bugs.html

debug_level: 1

hla_swd

none separate

Error: open failed

in procedure 'program'

OpenOCD init failed

shutdown command invoked

[upload] Error 1

I just need help getting the system talk to each-other and see each-other

P.S. I want to go as bareMetal as possible and not to use arduino firmware HAL

The_M_Code
  • 127
  • 2
  • 10

1 Answers1

1

You can use the following configurations:

upload_protocol = serial
upload_port = COMX/ttyx //whichever applies
  • That works for genericSTM32F103C8 board. According to the documentation bluepill_f103c8 board doesn't have that upload protocol. – Radzor Jun 24 '23 at 01:08