Sonntag, 29. September 2024

 


Building a Custom MIDI Controller for VCV Rack with Raspberry Pi Pico

Welcome to my custom DIY MIDI controller project! In this tutorial, I will guide you through building your own controller using a Raspberry Pi Pico, potentiometers, buttons, and a multiplexer for expanded control. Below, you will find images of my late-night work sessions, detailed instructions, and the necessary resources to build your own.

Overview

While I have some Python knowledge, I let AI handle most of the code generation. This project is for those who enjoy soldering and customizing their hardware. The enclosures were designed in Fusion360 and 3D printed, and I'll soon upload the files to Thingiverse for others to download and improve.



Materials Used:

  • Raspberry Pi Pico (~€2)
  • CD74HC4067 Multiplexer (~€5 for 10)
  • 10k Ohm Potentiometers (~€3 for 10)
  • Push Buttons (~€3 for 10)
  • Jumper Wires
  • Breadboard (optional)

Steps to Build:

1. Install CircuitPython on the Raspberry Pi Pico

  • Download CircuitPython from circuitpython.org.
  • Flash it onto the Pico by holding the BOOTSEL button while connecting the Pico via USB.
  • Copy the downloaded .UF2 file onto the Pico’s drive.

2. Add USB-MIDI Libraries

  • Download the CircuitPython Library Bundle.
  • Copy the adafruit_midi library to the lib folder on the CIRCUITPY drive.

3. Multiplexer Setup

  • Connect the multiplexer to the Pico:
    • S0 → GP2, S1 → GP3, S2 → GP4, S3 → GP5 (for control lines).
    • SIG → GP26 (for reading potentiometer values).
    • VCC → 3.3V, GND → GND (for power and ground).

4. Potentiometer Wiring

  • Pin 1 (GND) connects to GND on the Pico.
  • Pin 2 (Wiper) connects to a multiplexer channel (e.g., C0, C1, etc.).
  • Pin 3 (3.3V) connects to 3.3V on the Pico.
  • Up to 16 potentiometers can be connected.

5. Button Setup

  • Solder buttons directly to free GPIO pins (e.g., GP0, GP1, GP6 - GP22), with one pin of the button going to GND and the other to a GPIO pin.

Sample Code and Controller Configuration

Here is a Wokwi Project for a controller with 4 buttons and 4 potentiometers + code









MIDI Mapping with MidCat in VCV Rack

Once the hardware is set up, map the MIDI controls in VCV Rack using the MidCat plugin by Stoermelder. This allows you to assign MIDI signals from your Pico to any desired parameter in VCV Rack.


Get Involved

If you have experience with this type of setup, feel free to suggest improvements. I will upload my Fusion360 files to Thingiverse soon for those interested in customizing further.

Keine Kommentare:

Kommentar veröffentlichen