Build a Simple Macro Pad
by Basheer bk in Circuits > Microcontrollers
729 Views, 5 Favorites, 0 Comments
Build a Simple Macro Pad




Welcome to this Instructables ! In this guide, we’ll build a simple 3-key macro pad using a Raspberry Pi Pico. This project is designed to be minimalistic—unlike most macro pads, it doesn’t require a custom PCB. Instead, we’ll assemble everything on a dot board (perf board), making it an easy and accessible DIY build.
A macro pad is a great way to streamline workflow by assigning frequently used shortcuts to dedicated keys. For example, you can map one key to CTRL+C for quick copying. When pressed, the Pico will send the corresponding key combination to your computer, just like a standard keyboard.
In my setup, I’ve programmed shortcuts for essential functions, but you can easily customize the keys to suit your needs—whether for productivity, gaming, or creative software.
Supplies



To make this project, I used:
Raspberry Pi Pico
Push button x 3
dot board
breadboard and jumper wire
Acrylic sheet
Soldering iron
flux
soldering led
other essential tools
Vscode IDE (optional)
Flashing Circuit Python on the Raspberry Pi Pico

.png)
.png)
For flashing First, download the Circuit Python UF2 file from the official website.
Then, enter bootloader mode by holding the BOOTSEL button while plugging the Pico into your computer via USB.
Once it appears as a drive named RPI-RP2, simply drag and drop the UF2 file onto it. The Pico will reboot and appear as CIRCUITPY, indicating that Circuit Python is successfully installed.
For more detailed steps click here.
Adding Adafruit Circuit Python Library

.png)
Next, we need to add the Adafruit Circuit Python HID library to enable keyboard functionality.
First, download the Circuit Python Library Bundle from github.
https://github.com/adafruit/Adafruit_CircuitPython_Bundle
Extract the file, find the adafruit_hid folder inside the lib directory, and copy it to the lib folder on the CIRCUITPY drive. This library allows the Pico to act as a keyboard, sending keypresses to the computer
Programming the Pico

.png)
For the programming part, I used VS Code as the IDE. First, open VS Code and connect your Raspberry Pi Pico. Then, navigate to the CIRCUITPY drive and create a new file named code.py. Copy and paste the provided code into this file and save it.
Downloads
Initial Testing


![VID-20250206-WA0014(1)2[1].gif](/proxy/?url=https://content.instructables.com/FKR/O4K4/M70HSKV1/FKRO4K4M70HSKV1.gif&filename=VID-20250206-WA0014(1)2[1].gif)
Here, i have used a breadboard, push button and jumper for initial testing. i have copied hello text and when i press the button, it's pasting the text. So everything is working.
Soldering




First i have soldered the female header pins to the dot board. then three push buttons are place according to the GPIO pin position. i have used GPIO 15,7,0. So i connected the pins to push button pins and GND pins are also connected.
Program Edits
Maps each button to a keyboard shortcut. and Uses Ctrl+C for copy, Ctrl+Z for undo, and Ctrl+V for paste. change these keys and add your own short keys
For changing GPIO pins:-
Desinging Case



.png)
.png)
After all the soldering, i thought of setting up some type of wooden base. i used small piece of wooden log and cut a piece out of it. but it did not look pretty. The fact is there is no makerspaces in my home town to get access of any 3d printers. anyway i thought to design a case as an experiment. i used a CAD software and designed a simple case. suddenly i got an idea to make case out of acrylic. i took the design to nearby cnc shop and cut down the case, but it was a flop due to some dimensional errors of the top part.
Final Outcome


I used the other parts and thought to kept it as a DIY design rather than a enclosure case. The key take away from this project is, i have learned a lot about HID interference and designing.