diff --git a/adafruit_hid/keyboard.py b/adafruit_hid/keyboard.py index d55a916..28ad492 100644 --- a/adafruit_hid/keyboard.py +++ b/adafruit_hid/keyboard.py @@ -168,6 +168,9 @@ def led_on(self, led_code): from adafruit_hid.keycode import Keycode import time + # Initialize Keybaord + kbd = Keyboard(usb_hid.devices) + # Press and release CapsLock. kbd.press(Keycode.CAPS_LOCK) time.sleep(.09)