A simple CircuitPython project for the Adafruit NeoKey Trinkey M0 that launches your GitHub profile page with a single button press.
This project turns your NeoKey Trinkey into a quick-launch button for your GitHub profile. Simply press the button, and it will automatically open Firefox and navigate to your GitHub page.
- One-button GitHub launch - Press the button to instantly open your GitHub profile
- Visual feedback - Blue LED indicates ready state, green LED flashes when button is pressed
- USB HID Keyboard - Uses HID keyboard emulation to interact with your computer
- Automatic browser launch - Opens Firefox and navigates to your GitHub URL
- Adafruit NeoKey Trinkey M0
- Cherry MX-compatible mechanical key switch (soldered to the board)
- Windows PC with Firefox installed
- CircuitPython 10.0.3+
- Required CircuitPython libraries (see Installation section)
.
├── code.py # Main program file (runs automatically on boot)
├── lib/ # CircuitPython libraries
│ └── adafruit_neokey/ # NeoKey hardware support library
│ ├── __init__.py
│ └── neokey1x4.mpy
├── boot_out.txt # CircuitPython boot output (system file)
└── README.md # This file
- Download the latest CircuitPython UF2 file for NeoKey Trinkey M0 from circuitpython.org
- Double-click the reset button on your NeoKey Trinkey to enter bootloader mode
- Drag the downloaded
.uf2file onto theTRINKEYBOOTdrive - Wait for the device to restart - you should see a
CIRCUITPYdrive
- Download the Adafruit CircuitPython Library Bundle (match your CircuitPython version)
- Extract the bundle
- Copy the following libraries from the
libfolder to yourCIRCUITPY/lib/folder:adafruit_hid/(for keyboard emulation)adafruit_neokey/(for NeoKey hardware support - already included in this repo)
- Copy
code.pyto the root of yourCIRCUITPYdrive - Ensure the
lib/adafruit_neokey/folder is in yourCIRCUITPY/lib/directory
Edit code.py and change line 78 to your desired GitHub URL:
layout.write("https://github.com/MAX-P0W3R") # Change this to your GitHub usernameOr modify it to open any URL you prefer.
- Plug your NeoKey Trinkey into a USB port on your Windows PC
- The LED will turn blue, indicating the device is ready
- Press the mechanical switch button
- The LED will briefly flash green
- Firefox will automatically launch and navigate to your GitHub profile
This project uses Pull.DOWN configuration for the button. If your switch behaves differently, you may need to adjust:
- Pull.DOWN (current):
False= not pressed,True= pressed - Pull.UP:
True= not pressed,False= pressed
To change, modify line 23 in code.py and adjust the button logic accordingly.
To use a different browser, modify the launch sequence in code.py (around line 66):
- Firefox (current):
layout.write("firefox") - Chrome:
layout.write("chrome") - Edge:
layout.write("msedge")
- Blue
(0, 0, 50): Ready/idle state - Green
(0, 255, 0): Button pressed / action executing
To change colors, modify the pixel.fill() calls in code.py.
- Check that your switch is properly soldered to the board
- Verify the switch is connected to the correct pins
- Try the diagnostic script (if included) to test button detection
- Check the serial console output for error messages
- Ensure Firefox is installed and accessible via Run dialog (Win+R → "firefox")
- Adjust the timing delays in
code.pyif your computer is slow - Check that no other applications are intercepting keyboard input
Connect via serial console (115200 baud) to see debug messages:
- "=== Starting NeoKey Trinkey ===" - Device initialized
- "Button configured with Pull.DOWN" - Button ready
- "*** BUTTON PRESSED! ***" - Button detected
- "*** Command sent! ***" - Keyboard commands sent
- Mu Editor - Recommended IDE for CircuitPython
- CircuitPython Serial Console Guide
This project is open source. Feel free to modify and use as needed.
Pull requests and issues are welcome! If you have improvements or find bugs, please open an issue or submit a PR.
This project uses USB HID keyboard emulation. Use responsibly and only on your own devices. The author is not responsible for any misuse of this code.
MAX-P0W3R
- GitHub: @MAX-P0W3R
Made with ❤️ using CircuitPython and Adafruit hardware



