Skip to main content
Version: FILS English

Lumentra

info

Author: Sandu Tudor Nicolas
GitHub Project Link: https://github.com/UPB-PMRust-Students/fils-project-2026-TudorSN

Description

Lumentra is a modern, hybrid USB-MIDI controller designed for music producers and live performers. Built on the Raspberry Pi Pico 2 W, it acts as a native "Plug-and-Play" USB-MIDI class device. It features physical arcade buttons for tactile performance and a single Time-of-Flight (ToF) laser sensor for touchless expression. Furthermore, the project utilizes the microcontroller’s built-in hardware True Random Number Generator (TRNG) to introduce subtle, natural "humanization" to drum beats by randomizing Note Velocity and Panning directly at the bare-metal hardware level.

Motivation

As a music producer, I wanted a project that combines my passion for creating beats with the technical skills learned in the Microprocessor Architecture course. Standard MIDI controllers often lack expressive continuous control. Lumentra solves this by using an incredibly accurate laser distance sensor to create a theremin-like gesture effect channel. Furthermore, to overcome a common software issue where MIDI drum loops sound too sterile or "robotic," I engineered Lumentra to utilize the Pico 2 W's integrated hardware TRNG. By seeding beat logic with this internal noise, I can add natural human variations to performance dynamics directly in the embedded system.

Architecture

Main Components & Interconnections:

  • Core Controller (Raspberry Pi Pico 2 W): Acts as the central hub, running asynchronous Rust (Embassy) to poll all inputs and handle native USB communication.
  • Tactile Performance Array: Mechanical arcade buttons connected via standard GPIO pins, used to send MIDI Note On/Off messages.
  • Gesture Sensor: A single VL53L0X Time-of-Flight (ToF) laser sensor connected to the I2C Bus. The distance read is mapped to MIDI Control Change (CC) messages.
  • Internal Humanizer: The RP2350’s integrated TRNG peripheral is utilized to provide high-quality random data for non-deterministic MIDI velocity and panning.
  • Visual Interface: An ST7735 TFT display module connected to the high-speed SPI Bus to provide real-time visual feedback on active MIDI CC values and selected effects.
  • Host PC Connection: The microcontroller's Native USB peripheral is configured as a native USB-MIDI Class Device, sending data directly to the DAW (e.g. FL Studio).

+-------------------+ +-------------------+ +-----------------------+ | Gesture Sensor |====I2C======| |===USB=======| Host Device (PC) | | (VL53L0X ToF) | | | | (DAW/FL Studio) | +-------------------+ | | +-----------------------+ | | +-------------------+ | Logic Controller | +-----------------------+ | Tactile Input |===GPIO======| (Pico 2 W) |====SPI======| Visual Interface | | (Arcade Buttons) | | | | (ST7735 Display) | +-------------------+ | | +-----------------------+ | | | | +-----------------------+ | |===GPIO======| Audio Feedback | +-------------------+ | (Buzzer - Extra) | +-----------------------+

Log

Week 1 - 9

  • Decided on the final idea for the project and chose the Raspberry Pi Pico 2 W as the main board because of its native USB support and built-in random number generator.
  • Researched exactly what parts were needed and ordered the ToF laser sensor, the SPI display, and the arcade buttons.
  • Tested the individual parts separately on a breadboard to make sure they turn on and work correctly before putting everything together.
  • Set up the Rust programming tools on my computer and successfully connected to the Pico 2 W to make sure I can upload code to it.

Week 12 - 18 May

Week 19 - 25 May

Hardware

The project is built around the Raspberry Pi Pico 2 W (featuring the dual-core ARM Cortex-M33 RP2350), selected for its excellent asynchronous Embassy Rust support and native USB capabilities. Gesture inputs are captured using a single, millimeter-accurate VL53L0X ToF laser sensor on the I2C bus. Performance input is handled by mechanical arcade buttons. Visual feedback is delivered via a 1.44" LCD display driven by an ST7735 controller communicating over the SPI bus. To ensure a professional and durable musical instrument, the entire circuit will be permanently soldered onto a prototyped perfboard.

Lumentra Hardware Photo

Schematics

Lumentra KiCad Schematic

Bill of Materials

DeviceUsagePrice
Raspberry Pi Pico 2 WMain microcontroller running the native USB stack, I2C, and SPI logic.40 RON
VL53L0X ToF SensorLaser sensor to track hand distance for effect control.20 RON
LCD Module with ST7735 ControllerProvides real-time visual feedback of MIDI values41 RON
Arcade Buttons (4 pack)Tactile mechanical input for sending Note On/Off messages.40 RON
Resistors 10kΩPull-down for buttons5 RON
[Perfboard]Final assembly8 RON
[Wires]Connections20 RON

Software

LibraryDescriptionUsage
embassy-executorAsync RuntimeCore non-blocking peripheral management.
embassy-rpHardware AbstractionRP2350 specific GPIO, I2C, TRNG, and SPI configuration.
embassy-usbUSB Device StackConfiguring the Pico's native hardware USB peripheral to communicate with the PC.
vl53l0xI2C driver for ToF sensorReading millimeter distance values from the laser sensor.
usbd-midiUSB MIDI ClassFormats raw button and sensor data into standard USB-MIDI packets.
mipidsiST7735 / SPI DriverHandles the low-level initialization and SPI communication for the TFT screen.
embedded-graphics2D graphics libraryUsed for drawing shapes, text, and visual interface elements on the display.
  1. link

...