Hi, I have a project with ESP32-S2 that emulates a HID USB keyboard and is connected to a PC. I use the "USBHIDKeyboard" library for this. Everything works as it should, all characters and function keys can be sent. I just don't know how to read the status LEDs of the internal keyboard in the PC. I always need to send keys with CAPS-LOCK and NUM-LOCK turned on. Sending these keys also works well, the problem occurs when, by default, CAPS-LOCK is not turned off on the PC keyboard. Then, by sending, it turns off. I just need to know the status of NUM and CAPS LOCK before sending the keys. In some libraries there is a ".getLedStatus ()" function, but these cannot be used with ESP32-S2.
Thanks in advance for any advice or directions in the right direction on how to solve this problem.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.