Skip to content

STM32F103C8T6 & ArduinoIDE "Failed uploading: no upload port provided" #18

@Bruur-vr

Description

@Bruur-vr

Hello all,

I've been tinkering with some STM32F1 boards since 2 weeks now. I want to use them for a project but seem to fail to program anything (except a blink through ST-link).

I searched the forums for a solution but everything I tried has led to the same result. I try to upload the proved Blink program through arduino IDE:


Sketch uses 23948 bytes (36%) of program storage space. Maximum is 65536 bytes.
Global variables use 4392 bytes (21%) of dynamic memory, leaving 16088 bytes for local variables. Maximum is 20480 bytes.
Failed uploading: no upload port provided

If i'm not mistaken then I can only upload with arduino IDE (over USB) after flashing a bootloader unto the Blue Pill. I got the HID bootloader out of BluePill-Plus-master\SDK\STM32F103C8T6\Arduino\Bootloader.

I tried:
Different methods of uploading bootloader:

  • Bootloader mode by pressing Boot0 (onboard LED does not flash) > Connect ST-link to PC > downloaded .bin (STMprogrammer [Full chip erase, download file, verify, software reset enabled) > Boot 0 not pressed (Becomes pulled down: GND through 10k R) > press reset.
    That works (LED fast blink & see attached image of USB viewer)
  • Bootloader mode by pressing Boot0 & PA0 (onboard LED does not flash) > Connect ST-link to PC > downloaded .bin (STMprogrammer [Full chip erase, download file, verify, software reset enabled) > Boot 0 & PA0 not pressed (PA0 becomes floating, and Boot0 becomes pulled down: GND through 10k R) > disconnect.
    It gives the same result as pressing only Boot0, as expected (STM's AN2606 Application note page 22 says both are a pattern to enter bootloader).

Different methods of uploading Blink:

  • (after downloading with STlink) Arduino IDE > connect USB C cable > settings as in image > download BLINK (proviced by WeAct, onboard LED = PB2) > error.
  • (after downloading with UART converter)Arduino IDE > connect USB C cable > settings as in image > download BLINK (proviced by WeAct, onboard LED = PB2) > error.
  • (after downloading with UART converter)Arduino IDE > connect USB C cable > Press and hold boot0, hit reset once (LED turns off) > settings as in image > download BLINK (proviced by WeAct, onboard LED = PB2) > error.

Items used:

  • STM32F103C8T6 BluePill+ from official WeAct
  • ST link V2 (probably clone, but has been working without fail)
  • AZDelivery CP2102 USB to TTL converter
  • STMprogrammer to flash HID bootloader
  • HID bootloader provided by this github.
  • Arduino IDE 2.3.1 (& now downgraded to 2.2.1, to see if it fixes anything)
  • ST32M (official) core
  • USB C data cable (I can upload from phone with the same cable)

Arduino settings used:
Settings in IDE

I can find the device in device manager under HID devices (named: USB input device), and USB device viewer can read the HID bootloader on it.
USB viewer

I have no clue where to look, would someone be so kind as to help me with this issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions