TransWikia.com

Using an ATTiny85 and DigiKeyboard.h, can I detect when USB HID is connected?

Arduino Asked by Bobby Tables on January 4, 2022

I am building a project to send HID keystrokes to a computer with an ATTiny85. I want to detect when the USB communication is working, in order to turn on a LED saying that everything is good. If USB stops working, I want a watchdog to turn the LED off. Ideally it would also attempt to reconnect automatically.

DigiUSB has the DigiUSB.available() method, but DigiKeyboard does not, and I can’t seem to use both headers in the same program because of conflicts. How can I do this without DigiUSB?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP