Hackster is hosting Hackster Holidays, Ep. 6: Livestream & Giveaway Drawing. Watch previous episodes or stream live on Monday!Stream Hackster Holidays, Ep. 6 on Monday!
Hendra Kusumah
Published © LGPL

Xiao NAH Macropad

A macropad built around the xiao footprint

BeginnerFull instructions provided6 hours1,451
Xiao NAH Macropad

Things used in this project

Hardware components

Seeed XIAO RP2040
Seeed Studio Seeed XIAO RP2040
×1
Seeed XIAO BLE nRF52840 Sense
Seeed Studio Seeed XIAO BLE nRF52840 Sense
×1
3.6V 0.5W Zener Diode
3.6V 0.5W Zener Diode
×16
MX Switch
×1

Software apps and online services

Arduino IDE
Arduino IDE
Circuitpython

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Solder Wire, Lead Free
Solder Wire, Lead Free

Story

Read more

Schematics

top

bottom

Code

code.py

Python
print("Starting")

import board
from kmk.hid import HIDModes
from kmk.kmk_keyboard import KMKKeyboard
from kmk.keys import KC
from kmk.scanners import DiodeOrientation

keyboard = KMKKeyboard()

keyboard.col_pins = (board.D6,board.D5,board.D4,board.D3,)
keyboard.row_pins = (board.D10,board.D9,board.D8,board.D7,)
keyboard.diode_orientation = DiodeOrientation.COL2ROW

keyboard.keymap = [
    [KC.A, KC.B, KC.C, KC.D,
     KC.E, KC.F, KC.G, KC.H,
     KC.I, KC.J, KC.K, KC.L,
     KC.M, KC.N, KC.O, KC.P,
     ]
]

if __name__ == '__main__':
    keyboard.go()

Credits

Hendra Kusumah

Hendra Kusumah

30 projects • 129 followers
Love hacking and making new things from IoT to robotics

Comments