arpruss / USBComposite_stm32f1

USB Composite library for STM32F1 (HID, Serial, MIDI and XBox360 controller)
Other
382 stars 76 forks source link

Support for OS to send led status #3

Closed Senna-chan closed 6 years ago

Senna-chan commented 6 years ago

I am trying to revive a old keyboard and your library works like a charm but I am missing the ability to get the led status report. Is it implemented and if so how can I get that?

P.S. What is the status on Consumer. Every time I try to send a keypress the stm32(Blue pill) freezes

arpruss commented 6 years ago
  1. Does the LED status report go from the keyboard to the PC or the PC to the keyboard?

  2. Did you try the consumer example? It worked for me.

arpruss commented 6 years ago

Somehow the Consumer.cpp file never got committed to the repository. Fixed.

Senna-chan commented 6 years ago

From https://docs.mbed.com/docs/ble-hid/en/latest/api/md_doc_HID.html it says that the os is sending an output record to the device. After seeing that I guess that the report descriptors for the keyboard needs to be changed.

arpruss commented 6 years ago

Added keyboardwithleds example (and updated the library code to allow LEDs to work without constant polling).