How jpbruijstens/embedded_production works
This is a Raspberry Pi Pico LED controller. Its principal workflow turns potentiometer, rotary-encoder, and IR-remote input into LED channel/volume state and updates a WS2812 strip and two PMOD OLED displays. The sampled code supports ADC/DMA volume processing, encoder-driven LED/display updates, and both predefined and learnable IR control. IR capture dispatch details and some unsampled module behavior are uncertain, so those connections are omitted; paths for documented but unsampled hardware subsystems use their exact source files.
Main entry points: main.c Startup and loop · adc_volume.c ADC volume · ir_remote.c Remote decoding · ws2812_led.c LED control
Components 17
Application
- Startup and loop
main.c - Shared state
global.c
Input and control
- GPIO interrupts
gpio_interrupt.c - ADC volume
adc_volume.c - ADC DMA
dma.c - Encoder processing
rotary_encoder.c - IR capture
ir_reader.c - Remote decoding
ir_remote.c
LED output
- LED control
ws2812_led.c - WS2812 PIO
ws2812.pio
Display
- Display rendering
pmod.c
Other components
- Operator
- Potentiometer
- Rotary encoder
- IR remote
- WS2812 strip
- Dual OLEDs
Connections 27
- Operator → Potentiometer: adjusts
- Operator → Rotary encoder: rotates
- Operator → IR remote: presses
- Startup and loop → ADC volume: initializes
- Startup and loop → ADC DMA: starts
- Startup and loop → Encoder processing: initializes
- Startup and loop → Remote decoding: initializes
- Startup and loop → GPIO interrupts: initializes
- Startup and loop → LED control: initializes
- Startup and loop → Display rendering: initializes
- Potentiometer → ADC volume: sets level
- ADC volume → ADC DMA: configures sampling
- ADC DMA → ADC volume: updates volume
- ADC volume → LED control: selects color
- ADC volume → Display rendering: refreshes bars
- Rotary encoder → Encoder processing: signals rotation
- Encoder processing → LED control: updates channel
- Encoder processing → Display rendering: refreshes displays
- IR remote → Remote decoding: sends commands
- Remote decoding → LED control: changes channel
- Remote decoding → ADC volume: adjusts volume
- IR capture → Shared state: records edges
- Remote decoding → Shared state: reads capture state
- IR capture → Display rendering: shows learning prompts
- LED control → WS2812 PIO: writes pixel data
- WS2812 PIO → WS2812 strip: drives
- Display rendering → Dual OLEDs: sends display data