Learn how a maker used his electronics and coding knowledge to make an alternative to a commercial Stream Deck to control his computer software.
If you were not already aware, makers are welcome to submit their projects via our website for a chance to be featured in our mag (https://diyodemag.com/submissions). This month, we had an interesting submission from Pedro Callisaya with his Stream Deck alternative.
Pedro explained that even though there are a lot of projects out there from external numpads up to expensive decks like the Loupedeck CT, his has a budget-friendly price and it is easy to make for beginner programmers and non-programmers.
Pedro’s build uses an ESP32S2 dev board, but his code can also be adapted to ESP32 Bluetooth boards or RP2040 boards.
Read on to learn more about the clever build.
Thanks for submitting your project, Pedro. Tell us about yourself and what first got you interested in electronics
I am an electronic engineer from Bolivia. I got into the DIY world about 6 years ago, making some small projects and lately, I got into the photography and videography hobby. I started making budget DIY projects for this hobby as it is an expensive one.
What motivated you to design and build your project instead of buying a commercial equivalent?
As I am now into the photo/video world, I also wanted to show my projects and to create features that maybe other projects and commercial products do not have. I always liked keyboards, especially macropads, but the alternatives I found online were expensive (streamdeck or loupedeck) or limited (QMK). Also, QMK I think has a longer learning curve because of the configuration interface and the keys do not have labelling.
All this started when I tested a simple QMK 6 button macropad. Initially, I found it hard to configure. I do not have a great memory so to remember every button without a label was hard. And, as a maker, I use many IDEs (Browser navigation, Fusion360, Kicad, Premiere, Photoshop) and the QMK macropad functionality was limited for what I needed. Also, when I started to use this QMK, I had to reprogram the macropad every time I changed my mind about the order fo the profile.
So, I started to think about designing my own project and improving things I didn't like about QMK.
First, I needed an easy to use programming language because there is a lot of tutorials of macropads using Arduino. However, it was important to me that the functions were not hardcoded in the code. This is where I discovered DuckyScript which was pretty simple to use but DuckyScript was oriented to read only one file so I decided to make a file for every button and store those files in an SD card.
The second problem was the key labels. My first prototype used a small LCD screen to show the labels for every button.
When I showed my project to some colleagues, they liked its functionality and wanted to make something for themselves but they didn’t know about electronics or soldering. This motivated me to look for a ready to use solution.
Thus, the dev board I used is an ESP32S2 board that has USB support so can emulate a keyboard like ATmega32u4 and the RP2040. It has a capacitive touchscreen that replace the keypad and add a display that can show icons like a Stream Deck, and has a microSD card slot to store all the Ducky Script files and icons.
The board is made by Makerfabs, but I think anyone with the same components can recreate the same devboard.
Can you go into more detail about how it works, and what parts you use?
Only the Makerfabs ESP32S2 touchscreen board and a 3D printed case.
In case you build one from scratch, you will need:
- ESP32S2 board
- 3.5" display with ILI9488 driver and touchscreen
- SD card module
The Makerfabs ESP32S2 touchscreen devboard has a touchscreen that I coded to work as a matrix keypad to display buttons.
When you press the button, it runs a Ducky Script file (txt file on the microSD card) that executes the instructions as you were pressing your keyboard automatically.
The buttons displayed have icons stored in the same SD card, making it easier to remember what every button does.
I chose the ESP32S2 because it supports native USB, and you can emulate a keyboard with this chip. If someone is building one you can also use a Raspberry Pico RP2040, or a STM32F103 both have the same capabilities.
The display is a 3.5" screen based on the ILI9488 with a capacitive touchscreen based on the FT6236 driver. I prefer a capacitive touchscreen because it is similar to the haptics of a Smartphone, but there are resistive touchscreen alternatives (the downside of a resistive touchscreen is that it needs calibration).
The microSD card where all the files are stored, such as the DuckyScript files and icons, can be from an old spare microSD card of 2GB up to 32GB, which is supported by the Arduino libraries. 32GB enables you to create a huge number of profiles.
The icons must be in BMP or bitmap 24-bit files as it is easier for Arduino to read these files to display the icons. You can create these bitmap icons easily using Photoshop or GIMP or even an online photoshop emulator like Photopea.
To start using it, in the files there are example profiles and you can learn DuckyScript with any online tutorial. DuckyScript is pretty simple to use and understand even for non-coding users.
What design challenges did you need to overcome?
The first challenge was to code the DuckyScript interpreter code, read the instructions and execute them as a keyboard. And, the second challenge was to find a board that was ready to use and does not require complex wiring and soldering.
The ESP32S2 takes its power from the USB port also?
Yes. Only a USB-C cable is required to power and communicate with the board, like any keyboard or macropad.
How did you go about coding it?
The hardest part was to read the text files and parse the instructions to make an action. Currently, the InfiniteDeck only works as a keyboard but I want to add more features in the near future.
You are obviously also savvy with 3D printing. Please tell us about the 3D design and print process.
The 3D design is pretty simple - just a case for the board and the printing process does not need supports.
Too easy. If our readers want to make one for themselves, do you have more details, code, print files, etc?
Perfect. Is there anything else our readers should know that we haven't already discussed?
This is my first version of the InfiniteDeck. I plan more versions with new features, like wifi configuration, buttons and sliders. And, because it is opensource, readers can also create their own features.
Also, I used ArduinoIDE to develop this project because it is easier to understand and others can quickly create new features in the code, because other coding languages have hard to use libraries and not so friendly IDEs.
Nice work, Pedro. Thanks for sharing your project with us.