Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27,735 changes: 27,735 additions & 0 deletions hackpads/ChadPad/CAD/HackPad v0.step

Large diffs are not rendered by default.

Binary file added hackpads/ChadPad/PCB/gerbers.zip
Binary file not shown.
29 changes: 29 additions & 0 deletions hackpads/ChadPad/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
## ChadPad Macropad
This is my submission for the HackPad YSWS event. I have to admit, the design is lacking and could be way more polished, but I learned about HackPad 3 days before the submission date and therefore had a limited amount of time.

The ChadPad includes 9x Choc V2 switches, each with its own SK6812 MINI LED for backlighting. There are also 4 additional RGB LEDs which can be programmed as indicators (Show if user is muted, deafened, etc.). The case includes channels which guide the light from the indicator LEDs to the top panel, with the idea that 3D printed icons can be inserted into the slots, and lit up by the LEDs. The current firmware has limited support for the LEDs, which will be rectified when I am able to debug it with the physical device.

Im quite happy with how the design turned out, despite its shortcomings. If I had more time to work on it, I would definitely improve the case (I´ll probably print an improved version) and the firmware (Honestly I have no clue whether it will work or not, its quite hard to write firmware that you cant test). In hindsight, changing the switch layout to a matrix type would also be an improvement.

## PCB Screenshots

![Schematic Screenshot](https://cdn.hack.pet/slackcdn/3ce64c73d192c096a010f3dfe9e93135.png)
![PCB Screenshot](https://cdn.hackclubber.dev/slackcdn/d8379c542c32ca6b37fe968bdc94ba31.png)
![PCB-3D Screnshot](https://cdn.hackclubber.dev/slackcdn/8480b65bd1dd608ebc7b952a1d726b12.png)

## Case and instructions

![Case Screenshot](https://cdn.hackclubber.dev/slackcdn/9a77b300d45a2d4c367fcc823e627208.png)
![Case Bottom Screenshot](https://cdn.hack.pet/slackcdn/cce73c40b190106827b52dcfc2e812e7.png)

## BILL OF MATERIALS
9x Choc V2 switches (ideally blue but does not really matter)
9x White 1U DSA keycaps
13x SK6812 MINI-E LEDs
1x SEEED XIAO RP2040
1x 3D printed case (ideally white, black also works)
1x PCB (ideally purple or black)


## DISCLAIMER
Even though the submission requirements ask that DRC runs without issues, for some reason it complains about clearance on the XIAO pins, this is not an issue that would affect the function of the PCB, it is most likely an issue with me modifying the footprint and messing something up. If you do run DRC on the PCB, please ignore the XIAO pad errors. I attempted to fix it, but unfortunately I was unsuccessful.
65 changes: 65 additions & 0 deletions hackpads/ChadPad/firmware/firmware.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
import board
import digitalio
import adafruit_hid.keycode
from adafruit_hid.keyboard import Keyboard
import neopixel
import time

buttons = [
digitalio.DigitalInOut(board.P26),
digitalio.DigitalInOut(board.P7),
digitalio.DigitalInOut(board.P3),
digitalio.DigitalInOut(board.P27),
digitalio.DigitalInOut(board.P29),
digitalio.DigitalInOut(board.P4),
digitalio.DigitalInOut(board.P28),
digitalio.DigitalInOut(board.P1),
digitalio.DigitalInOut(board.P2),
]

for button in buttons:
button.switch_to_input(pull=digitalio.Pull.UP)


num_pixels = 13
pixels = neopixel.NeoPixel(board.D4, num_pixels, brightness=0.2, auto_write=False)


keyboard = Keyboard()


def set_led_color(index, color):
pixels[index] = color
pixels.show()

while True:
for i, button in enumerate(buttons):
if not button.value:
if i == 0:
keyboard.press(adafruit_hid.keycode.Keycode.7)
elif i == 1:
keyboard.press(adafruit_hid.keycode.Keycode.8)
elif i == 2:
keyboard.press(adafruit_hid.keycode.Keycode.9)
elif i == 3:
keyboard.press(adafruit_hid.keycode.Keycode.4)
elif i == 4:
keyboard.press(adafruit_hid.keycode.Keycode.5)
elif i == 5:
keyboard.press(adafruit_hid.keycode.Keycode.6)
elif i == 6:
keyboard.press(adafruit_hid.keycode.Keycode.1)
elif i == 7:
keyboard.press(adafruit_hid.keycode.Keycode.2)
elif i == 8:
keyboard.press(adafruit_hid.keycode.Keycode.3)

set_led_color(i, (255, 0, 0))

time.sleep(0.1)
keyboard.release_all()

else:
set_led_color(i, (0, 0, 0))

time.sleep(0.01)
Binary file added hackpads/ChadPad/production/BOT.stl
Binary file not shown.
Binary file added hackpads/ChadPad/production/TOP.stl
Binary file not shown.
65 changes: 65 additions & 0 deletions hackpads/ChadPad/production/firmware.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
import board
import digitalio
import adafruit_hid.keycode
from adafruit_hid.keyboard import Keyboard
import neopixel
import time

buttons = [
digitalio.DigitalInOut(board.P26),
digitalio.DigitalInOut(board.P7),
digitalio.DigitalInOut(board.P3),
digitalio.DigitalInOut(board.P27),
digitalio.DigitalInOut(board.P29),
digitalio.DigitalInOut(board.P4),
digitalio.DigitalInOut(board.P28),
digitalio.DigitalInOut(board.P1),
digitalio.DigitalInOut(board.P2),
]

for button in buttons:
button.switch_to_input(pull=digitalio.Pull.UP)


num_pixels = 13
pixels = neopixel.NeoPixel(board.D4, num_pixels, brightness=0.2, auto_write=False)


keyboard = Keyboard()


def set_led_color(index, color):
pixels[index] = color
pixels.show()

while True:
for i, button in enumerate(buttons):
if not button.value:
if i == 0:
keyboard.press(adafruit_hid.keycode.Keycode.7)
elif i == 1:
keyboard.press(adafruit_hid.keycode.Keycode.8)
elif i == 2:
keyboard.press(adafruit_hid.keycode.Keycode.9)
elif i == 3:
keyboard.press(adafruit_hid.keycode.Keycode.4)
elif i == 4:
keyboard.press(adafruit_hid.keycode.Keycode.5)
elif i == 5:
keyboard.press(adafruit_hid.keycode.Keycode.6)
elif i == 6:
keyboard.press(adafruit_hid.keycode.Keycode.1)
elif i == 7:
keyboard.press(adafruit_hid.keycode.Keycode.2)
elif i == 8:
keyboard.press(adafruit_hid.keycode.Keycode.3)

set_led_color(i, (255, 0, 0))

time.sleep(0.1)
keyboard.release_all()

else:
set_led_color(i, (0, 0, 0))

time.sleep(0.01)
Binary file added hackpads/ChadPad/production/gerbers.zip
Binary file not shown.