Brightness control v3.5.4
๐ก RESTORED: Display Brightness Control for Electra One MK1 HW 2.40 v3.5.4
Overview
The display brightness control feature that was available in firmware v2.0 but dropped in later versions has been successfully restored for Electra One MK1 running firmware v3.5.4!
This implementation adds SysEx-based brightness control while preserving all existing controller functionality.
โ What This Adds
- 5 brightness levels from maximum to minimum via SysEx commands
- Persistent settings - brightness survives controller reboot (stored in EEPROM)
- Minimal code change - only 25 lines added to firmware
- Full compatibility - works with existing presets, Lua scripts, and controller features
- SysEx API integration - follows Electra One's existing command structure
๐ง Technical Implementation
Firmware Changes
The restoration required adding UPDATE command support for ElectraInfo objects in TaskProcessSysex.cpp:
} else if (cmd.isUpdate()) {
if (object == ElectraCommand::Object::ElectraInfo) {
// Handle brightness update for ElectraInfo
uint16_t brightness = (cmd.getByte1() << 8) | cmd.getByte2();
System::logger.write(LOG_ERROR, "processElectraSysex: setting brightness to %d", brightness);
// Set the brightness value in runtime info
System::runtimeInfo.setElectraInfoBrightness(brightness);
// Apply brightness immediately to the display
Hardware::screen.setBacklightbrightness(brightness);
System::logger.write(LOG_ERROR, "processElectraSysex: brightness set successfully");
MidiOutput::sendAck(MidiInterface::Type::MidiUsbDev, port);
} else {
// Pass other UPDATE commands to application
App::get()->handleElectraSysex(port, sysexBlock);
}
SysEx Command Format
F0 00 21 45 04 7F [MSB] [LSB] F7
-
F0- SysEx start -
00 21 45- Electra One manufacturer ID -
04- UPDATE command -
7F- ElectraInfo object -
[MSB] [LSB]- 16-bit brightness value (big-endian) -
F7- SysEx end
Brightness Value Range
Important: The RA8876 display uses inverted PWM - higher values = darker screen!
- 0 = Maximum brightness (brightest)
- 1024 = High brightness
- 2048 = Medium brightness
- 4096 = Low brightness
- 5888 = Minimum brightness (dimmest)
- 6144 = Hardware maximum (very dim)
๐ Ready-to-Use SysEx Files
| File | Brightness Level | Value | Description |
|---|---|---|---|
set-brightness-maximum.syx |
Maximum | 0 | Brightest setting |
set-brightness-high.syx |
High | 1024 | High brightness |
set-brightness-medium.syx |
Medium | 2048 | Medium brightness |
set-brightness-low.syx |
Low | 4096 | Low brightness |
set-brightness-minimum.syx |
Minimum | 5888 | Dimmest usable setting |
๐ ๏ธ Installation Instructions
Option A: Use Pre-compiled Firmware (Easiest)
- Download the compiled firmware from the GitHub release
- Upload using ElectraOneConsole app or
make upload
Option B: Build from Source
- Prerequisites: ARM GNU Toolchain installed
-
Clone repositories:
git clone https://github.com/electraone/firmware.git git clone https://github.com/electraone/controller.git -
Checkout brightness control branch:
cd firmware git checkout brightness-control-v3.5.4 -
Link controller app:
ln -sf ../controller ./controller -
Build and upload:
make APPPATH=controller all make APPPATH=controller upload
๐งช Testing
- Install firmware (see instructions above)
-
Test brightness control:
- Send
set-brightness-maximum.syxโ Screen should be brightest - Send
set-brightness-minimum.syxโ Screen should be dimmest
- Send
- Verify persistence: Restart controller, brightness should remain
Expected Response
Successful brightness changes return ACK:
F0 00 21 45 7E 01 00 00 F7
๐ How This Was Discovered
The brightness infrastructure was never removed from v3.5.4 - it just lacked the SysEx command interface:
- โ
Hardware::screen.setBacklightbrightness()- Present - โ
System::runtimeInfo.setElectraInfoBrightness()- Present - โ EEPROM storage functions - Present
- โ UPDATE command handler - Missing (now restored!)
๐ป Integration Examples
MIDI Controller
Map hardware knobs/faders to send brightness SysEx commands
Automation
# Python example using python-rtmidi
brightness_cmd = [0xF0, 0x00, 0x21, 0x45, 0x04, 0x7F, 0x08, 0x00, 0xF7] # Medium
midiout.send_message(brightness_cmd)
Max/MSP, Pure Data, etc.
Send raw SysEx messages to Electra Controller CTRL port
๐ค Contributing
This feature is now available as:
-
Source code: GitHub branch
brightness-control-v3.5.4 - Pre-compiled firmware: GitHub release downloads
- SysEx test files: Ready-to-use brightness control files
โ ๏ธ Compatibility
- Hardware: Electra One MK1 only (MK2 uses different display driver)
- Firmware: Based on v3.5.4 - fully compatible with existing presets
- Controller App: Tested with full controller application (not just demo)
๐ Result
The Electra One MK1 now has the brightness control that was missing since v2.0, implemented with minimal firmware changes and maximum compatibility!
Thanks to the excellent Electra One architecture that preserved all the underlying brightness infrastructure - this restoration required only adding the missing SysEx command interface!