
Sonos magic hub
perja12/sonos_magic_hub
Circuit for using the LG OLED C9 TV remote (LG Magic Remote) with the Sonos Playbar.

A digital gate/trigger processor for Eurorack modular synthesizers. Gatekeeper has a two-state (0 or 5V) output driven by push button and CV input. The input response is configurable via menu settings.
Gatekeeper is an open-source printed circuit board by mjrskiles, from the mjrskiles/gatekeeper repository on GitHub, published under the MIT licence. It is a 2-layer board of 16 × 110 mm with 33 parts on 21 nets, routed with 143 tracks and 48 vias.
It is built around the ATTINY85V-10SU, PMEG4010CEH and MMBT3904. Its parts include 10 capacitors, 8 resistors, 4 diodes, 4 connectors and 2 ICs. It belongs with the AVR (ATmega, ATtiny) boards of this library.
A digital gate/trigger processor for Eurorack modular synthesizers. Gatekeeper has a two-state (0 or 5V) output driven by push button and CV input. The input response is configurable via menu settings.
This project is designed as a reference for hackers of all types. We assume hardware and coding knowledge, but those with a strong desire to learn and build will find this an approachable beginner hardware project.
Five Operating Modes:
Persistent Settings: Mode selection is saved to EEPROM and restored on power-up. Factory reset is available by holding both buttons for 3 seconds during startup.
Debounced Input: Robust button state detection with rising and falling edge detection.
Configuration Gestures:
Hardware Abstraction Layer (HAL): Clean interface for hardware access, enabling comprehensive unit testing on the host machine.
Unit Testing: 152 tests using the Unity framework verify functionality without hardware.
Native Simulator: Interactive terminal UI or headless JSON output for development without hardware.
Target: ATtiny85 @ 8 MHz (internal RC oscillator)
| Resource | Size | Usage |
|---|---|---|
| Flash | 8 KB | ~87% used |
| SRAM | 512 B | ~38% used |
| EEPROM | 512 B | 17 bytes used (~3%) |
Pin Assignment:
| Pin | Function |
|---|---|
| PB0 | Neopixel data |
| PB1 | CV output |
| PB2 | Button A (menu/secondary) |
| PB3 | CV input (analog via ADC) |
| PB4 | Button B (primary/gate control) |
| PB5 | RESET |
LED X and Y are Neopixels connected to PB0.
The firmware is organized into reusable library code (lib/) and application-specific code (src/), with headers alongside sources:
lib/ src/
├── events/ ├── config/
├── fsm/ ├── core/
├── hardware/ ├── hardware/
├── input/ ├── modes/
├── output/ ├── output/
└── utility/ ├── app_init.c/.h
└── main.cKey modules:
| Module | Purpose |
|---|---|
core/ | Application coordinator - manages FSM hierarchy, routes events |
fsm/ | Generic table-driven FSM engine (reusable library) |
events/ | Event processor - button gestures, CV edge detection |
modes/ | Signal processing modes (Gate, Trigger, Toggle, Divide, Cycle) |
hardware/ | HAL implementation (pin control, timers, EEPROM) |
input/ | Button debouncing and edge detection |
output/ | CV output behaviors |
app_init.c | Startup sequence, settings validation, factory reset |
See docs/ARCHITECTURE.md for detailed documentation including data flow diagrams, EEPROM layout, and extension guides.
Firmware build:
avr-gcc, avr-objcopy, avr-size, avr-strip)avrdude (flashing), bc + avr-nm (size analysis)Test/Simulator build (no AVR toolchain needed):
Install on Debian/Ubuntu:
# Tests only
sudo apt install build-essential cmake
# Firmware (minimal)
sudo apt install gcc-avr avr-libc cmake
# Firmware (full: build + flash + analysis)
sudo apt install gcc-avr avr-libc binutils-avr avrdude cmake bc# Build firmware
cmake --preset firmware && cmake --build --preset firmware
# Build and run tests
cmake --preset tests && cmake --build --preset tests
ctest --preset tests
# Build and run simulator
cmake --preset sim && cmake --build --preset sim
./build/sim/sim/gatekeeper-simThe simulator is under construction.
make flash # Program firmware
make fuses # Set fuse configuration
make read_fuses # Verify fusesDefault programmer: stk500v2 on /dev/ttyACM0. Override with:
cmake -DPROGRAMMER=usbasp -DPROGRAMMER_PORT=/dev/ttyUSB0 ..MIT
| Qty | Value | Footprint | References |
|---|---|---|---|
| 8 | 100nF | Capacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolder | C2, C4, C5, C6, C7, C8, C11, C12 |
| 4 | 10K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R1, R3, R4, R5 |
| 2 | 10uF | Capacitor_SMD:C_0805_2012Metric_Pad1.18x1.45mm_HandSolder | C1, C9 |
| 2 | NEOPIXEL | LED_THT:LED_D5.0mm-4_RGB | LED1, LED2 |
| 2 | PMEG4010CEH | Diode_SMD:D_SOD-123F | D1, D3 |
| 2 | SW_Push | Button_Switch_THT:SW_PUSH_6mm | SW1, SW2 |
| 2 | ~ | mjrskiles:THONKICONN | J1, J2 |
| 1 | 100 | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R2 |
| 1 | 330 | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R8 |
| 1 | 4.7K | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R6 |
| 1 | 470 | Resistor_SMD:R_0805_2012Metric_Pad1.20x1.40mm_HandSolder | R7 |
| 1 | ATtiny85V-10S | Package_SO:SOIC-8W_5.3x5.3mm_P1.27mm | U2 |
| 1 | Conn_02x03_Odd_Even | Connector_PinHeader_2.54mm:PinHeader_2x03_P2.54mm_Vertical | J4 |
| 1 | Conn_02x05_Odd_Even | Connector_PinHeader_2.54mm:PinHeader_2x05_P2.54mm_Vertical | J3 |
| 1 | FerriteBead | Inductor_SMD:L_0805_2012Metric | FB1 |
| 1 | MCP1703Ax-500xxDB | Package_TO_SOT_SMD:SOT-223-3_TabPin2 | U1 |
| 1 | MMBT3904 | Package_TO_SOT_SMD:SOT-23 | Q1 |
The 32 most common of 33 parts.
It measures 16 × 110 mm and has 2 copper layers, 1.6 mm thick.
33 parts, built around the ATTINY85V-10SU, PMEG4010CEH and MMBT3904. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.
From the mjrskiles/gatekeeper repository on GitHub, at the commit this page was made from: the board is hardware/gatekeeper/gatekeeper.kicad_pcb and its schematic hardware/gatekeeper/gatekeeper.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).

perja12/sonos_magic_hub
Circuit for using the LG OLED C9 TV remote (LG Magic Remote) with the Sonos Playbar.
perja12/roomba_beacon
IR beacon that can be used to limit where the Roomba vacuum cleaner goes.






georges-mars/Docimeter
A wearable redesign of the OpenDosimeter platform focused on compact electronics, custom PCB integration, embedded firmware, and practical radiation-monitoring applications.