rPico KMK powered macropad with IPS screen

Related tags

HardwareMacroPact
Overview

MacroPact

rPico KMK powered macropad with IPS screen

MacroPact Idea/Desing: Sean Yin

Build/Coding: kbjunky ( In case of any problems hit me up on Discord kbjunky#6476 or Reddit /u/kbjunky)

BOM

Item Count Example
USB-C Female Breakout 1 Link
28AWG 10 Pin Flat Ribbon cable (Rainbow) 5m Link
M2/4mm heat insert 8 Link
Raspberry Pico 1 Link
WS2812 RGB Strip min 7 diodes Link
240x240 IPS/TFT 1.3" screen 1 Link
12mm Rotary Encoder with switch 2 Link
Kailh Choc V1 Switch 17 Link
Choc V1 Keycaps 17 Link
1N4148 Fast switching diode through hole 19 Link
0.1mm copper jumper wire 1 Link
M2/4mm flat head screw 4 Link
M2/8mm flat head screw 4 Link
15x16 Knob 1 Link
25x17 Knob 1 Link
6x2 antislip pads 4 Link

On top of that you'll be needing:

  • Soldering iron
  • Rosin core solder wire (anything between 0.5mm to 1mm, preferable with lead 'Pb')
  • Sharp tool to remove supports from 3D printed parts
  • Wire stripper but a normal knife will also do the job
  • Hot glue gun
  • Soldering flux or flux marker

Remarks

Be sure to order same shaft type encoder/knob. Either Knurl or Flat(D-Type).

0.1mm copper wire is used to wire the switch matrix. It's enameled so there's no risk of shorting when crossed at the same time being very easy to solder unlike tranformer core enameled wires.

Keycaps can be ordered from Kailh Official store on Aliexpress. A better alternative is MKUltra Set.

Use flux on wires before soldering the tip.

Build guide

Setup CircuitPython

Follow this guide in order to have CircuitPython up and running on your Raspberry Pico. When it's installed correctly after plugin it in you should be able to see an additional drive named CIRCUIT_PYTHON or similar. At this point you can just copy paste the content of src directory onto the newly installed drive. This will cause rPico to reboot and keyboard firmware should be running.

3D Printing

Print the pieces in any color that you like, but best if:

  • Bottom is non shine through color (only the glow insert is meant to pass the light)
  • Glow insert is transparent filament
  • Top plate is also non shine through (if you opt for a white or similar color then you'll have to cover the bottom side with tape/paint to prevent the light from shinning through)

Top plate:

  • Infill 100%
  • Layer height 0.2
  • Print facing down to get a nice smooth surface (especially if you're printing on a mirror)

Bottom:

  • Infill 30%
  • Layer height 0.1
  • Support ON

Glow insert:

  • Infill 100%
  • Layer height 0.1

Printed bottom part should look like this. Use a sharp tool to remove supports from USB port and glow insert slot. Use glue/hot glue to fix the the glow insert in place.

Use soldering iron and push in the heat inserts into designated spots.

At this point you can also try attaching top plate. It should clip in. Check if all holes align etc.

Wiring

Start with connecting USB-C extension.

Connection diagram:

rPico USB-C
VBUS V+
TP2 D-
TP3 D+
TP1 GND

Check if wiring is correct by plugging in the rPico and checking if the internal drive has showed up. If it's OK then screw in the MCU into the bottom part of the macropad with M2/5mm screws and insert the USB-C socket into the hole at the back. Secure it with hot glue.

Insert switches, encoders into the top plate. Secure the encoders with washers and screws that came with it. Here I have used my own amoebas but you will be fine with just bare switches.

Follow the diagrams below for wiring the matrix columns.

And matrix rows.

This is how it looked like in my case.

Now is a good time to attach the IPS screen to the top plate. Follow the below diagram in order to connect the IPS with rPico (Dotted wire is white).

Once this is done it's time to test it and align it properly. After booting the keyboard it should display visual help for the first layer (I've used a different image, just a white rectangle to mark the edges of the screen, but now when firmware is all done you can use default 1st layer visual guide).

Align the display part of the screen with the slot and secure it with hot glue from he bottom. (Don't mind the diffrent colors on the photo it was a temporary connector back then).

With that out of the way we can proceed and connect our matrix with the MCU. Follow the below table and diagrams posted above for proper wiring.

Columns

Matrix MCU
COL_0 Red GP15
COL_1 Green GP14
COL_2 Yellow GP13
COL_3 Black GP12
COL_4 White GP11

Rows

Matrix MCU
Row_0 Red GP16
Row_1 Green GP17
Row_2 Black GP18
Row_3 White GP19

Last thing that is left are encoders. Clip the mounting legs on the sides, we won't be needing them (thick ones). Connect 'C' pads (the one in the middle of the side with three legs) to any GND on the MCU. Then connect pads A and B from each encoder according to this table.

Row_1 Green Encoder MCU
Pad A GP1
Pad B GP0
Row_2 Black Encoder MCU
Pad A GP2
Pad B GP3

And last but not least RGB. Cut the amount of diodes that suits you best. I would recommend anything between 7 to 9 or 11. Wiring is quite simple. Use the GND near the data pin on the MCU.

RGB MCU
VCC VBUS
Data GP28
GND GND(AGND)

And that's it. If all went well your MacroPact should be functional. Connect it and check. If it's all good secure remaining parts with hot glue (ie. encoders, LED strip). Attach the top plate to the bottom part and screw it in with the 8mm screws. Put on the keycaps and enjoy!

You can customize the layout anyway you want. You might want to check KMK Manual before you do. Check 'SVG' folder for a template for visual guide that is displayed per layer. You can use Inkscape for editing it and then export to PNG. In order to save space you can convert exported PNG files to low color BMP. Also note that the final picture has to be rotated 90 deg CCW.

You can edit the text for key/modifier(bottom left of each cell). Some modifiers are not visible because the stroke/fill is set to the background color. Change the color if you want the modifier to be visible. Use Unicode characters for the icons, there's plenty to choose from.

As a last step I recommend using rubber feet to prevent the macropad from sliding on the desk. Also a magnetic USB-C cable can come handy as it won't put this much stress on the socket and is very neat.

And this is it, hope this guide is detailed enough. Enjoy your MacroPact and please share your build on r/MK!

HACS gives you a powerful UI to handle downloads of all your custom needs.

HACS (Home Assistant Community Store) Manage (Install, track, upgrade) and discover custom elements for Home Assistant directly from the UI. What? HAC

HACS 3.2k Jan 04, 2023
Playing diabolo with two robot arms in ROS + Gazebo

Playing diabolo with robots This repository holds the ROS packages for playing diabolo with two UR5e robot arms on ROS Melodic (Ubuntu 18.04). Read ou

23 Dec 18, 2022
🔆 A Python module for controlling power and brightness of the official Raspberry Pi 7

rpi-backlight A Python module for controlling power and brightness of the official Raspberry Pi 7" touch display. Note: This GIF was created using the

Linus Groh 238 Jan 08, 2023
Raspberry Pi Power Button - Wake/Power Off/Restart(Double Press)

Control Raspberry pi with physically attached button. Wake, Power Off, and Restart (Double Press) . Python3 script runs as a service with easy installation.

Stas Yakobov 16 Oct 22, 2022
Scapy: the Python-based interactive packet manipulation program & library. Supports Python 2 & Python 3.

Scapy Scapy is a powerful Python-based interactive packet manipulation program and library. It is able to forge or decode packets of a wide number of

SecDev 8.3k Jan 08, 2023
a fork of the OnionShare software better optimized for lower spec lightweight machines and ARM processors

OnionShare-Optimized A fork of the OnionShare software better optimized for lower spec lightweight machines and ARM processors such as Raspberry Pi or

ALTPORT 4 Aug 05, 2021
Run this code to blink your ThinkPad LED with a hidden mysterious Morse code! ;)

TMorse Run this code to blink your ThinkPad LED with a hidden mysterious Morse code! ;) Compatible with python3.9+. No third-party library is required

Mahyar 2 Jul 11, 2022
Custom component for interacting with Octopus Energy

Home Assistant Octopus Energy ** WARNING: This component is currently a work in progress ** Custom component built from the ground up to bring your Oc

David Kendall 116 Jan 02, 2023
Segger Embedded Studio project for building & debugging Flipper Zero firmware.

Segger Embedded Studio project for Flipper Zero firmware Установка Добавить данный репозиторий в качестве сабмодуля в корень локальной копии репозитор

25 Dec 28, 2022
Aqara Camera G3 integration for Home Assistant

Aqara Camera G3 integration for Home Assistant ATTENTION: The component only works after enabled telnet. Only supportd stream. Not support still image

14 Dec 18, 2022
Example Python code for building RPi-controlled robotic systems

RPi Example Code Example Python code for building RPi-controlled robotic systems These python files have been compiled / developed by the Neurobionics

Elliott Rouse 2 Feb 04, 2022
智能无人机路径规划仿真系统是一个具有操作控制精细、平台整合性强、全方向模型建立与应用自动化特点的软件

Drone智能无人机路径规划仿真系统是一个具有操作控制精细、平台整合性强、全方向模型建立与应用自动化特点的软件。它以A、B两国在C区开展无人机战争为背景,该系统的核心功能是通过仿真平台规划无人机航线,并进行验证输出,数据可导入真实无人机,使其按照规定路线精准抵达战场任一位置,支持多人多设备编队联合行动。

wwy 349 Jan 03, 2023
A rubiks cube timer using a distance sensor and a raspberry pi 4, and possibly the pi pico to reduce size and cost.

distance sensor cube timer A rubiks cube timer using a distance sensor and a raspberry pi 4, and possibly the pi pico to reduce size and cost. How to

3 Feb 21, 2022
Cow Feeder is a bot automatically execute trade on cowswap

Cow Feeder is a bot automatically execute trade on cowswap, includes functions: Monitoring Ethereum network gas price and execute trade whe

6 Apr 20, 2022
Home Assistant custom integration for Yi cameras: yi-hack-MStar, yi-hack-Allwinner and yi-hack-Allwinner-v2

yi-hack Home Assistant integration Overview yi-hack Home Assistant is a custom integration for Yi cameras (or Sonoff camera) with one of the following

roleo 131 Jan 03, 2023
Home-Assistant MQTT bridge for Panasonic Comfort Cloud

Panasonic Comfort Cloud MQTT Bridge Home-Assistant MQTT bridge for Panasonic Comfort Cloud. Note: Currently this brige is a one evening prototype proj

Santtu Järvi 2 Jan 04, 2023
Programmable Rainbow Redstone Computer

Programmable Rainbow Redstone Computer Table of contents What is it? Program flasher How to use it What is it? PRRC is Programmable Rainbow Redstone C

Fern H 2 Jun 07, 2022
Simples Keylogger para Windows com um autoboot implementado no sistema

MKW Keylogger Keylogger simples para Windos com um autoboot implementado no sistema, o malware irá capturar pressionamentos de tecla e armazená-lo em

3 Jul 03, 2021
Example for Calculating Robot Dynamics Using Pinocchio Library

A Example for Calculating Robot Dynamics Using Pinocchio Library Developed by: Xinyang Tian. Platform: Linux + Pinocchio. In this work, i use Pinocchi

Rot_Tianers 33 Dec 28, 2022
Tools and documentation to aid in modifying the ADI ADALM Pluto firmware

Pluto firmware modifications This repository contains tools and documentation to aid in modifying the ADI ADALM Pluto firmware. Extraction of the Plut

Daniel Estévez 28 Dec 21, 2022