Skip to main content

Libraries Needed

PyKey needs a number of libraries to be available on the board for it to run.

Library/ModuleImport (with link to docs)Files/Folder needed
Default Modules
Saved Keymnap Definitionsimport os
GPIO Definitionimport board
GPIO Accessimport digitalio
Key Matrix and Switchesimport keypad
Basic Sound/Buzzerimport pwmio
PWM/Dimming LEDsimport pwmio
RGB LEDs - color wheelimport rainbowio
Rotary Encodersimport rotaryio
Sleep/delayimport time
USB Human Interface Device Definitionimport usb_hid
Adafruit CircuitPython Library Bundle
Keyboard USB HIDfrom adafruit_hid.keyboard import Keyboardadafruit_hid
RGB LEDs - Accessimport neopixelneopixel.mpy

PyKey uses libraries from the Adafruit CircuitPython Library Bundle 7.x. These are pre-compiled libraries in mpy format (a binary format representing the pre-compiled Python code)

Installing Libraries is as simple as copying the necessary files into the lib folder of your CircuitPython device.