Page 1 of 1

[BluePill] USB Keyboard example doesn't work

Posted: Mon Mar 10, 2025 11:30 am
by kurtzweber
Hi

I'm trying to make the USB Keyboard example work with a BluePill board but I'm facing some issues.

First of all, I'm not using any bootloaders (I read that they can cause some issues in this scenario), I'm uploading the sketch using a serial adapter connected to pin A9 and A10 and "STM32CubeProgrammer (serial)" as programmer.

I also enabled "HID Keyboard and mouse" in the USB support menu.

The "KeyboardMessage.ino" sketch compiles and uploads to the board, but when I connect the board to my laptop, only a "STM Serial" device appears (with a yellow question mark):

Image

Can you help?

An additional question: my project should act as a USB gamepad... is there a library to implement such a HID device or am I forced at the moment to stay with keyboard or mouse?

Thanks!