| Board Support Package | Low-level board drivers: SPI, I2C, I2S buses and the volume ADC |
| ADC / Volume potentiometer | Potentiometer sampling on ADC1 and mapping to PCM5242 digital volume |
| I2C bus | Shared I2C master bus (expander, DAC control, fuel gauge) |
| I2S bus | I2S0 master TX stream to the PCM5242 DAC |
| SPI buses | Display on SPI2 (HSPI), SD card on SPI3 (VSPI); both on native IOMUX pins |
| Drivers | Chip-level drivers built on top of the bsp buses |
| Audio DAC (PCM5242) | I2C control of the PCM5242 digital volume and soft mute |
| OLED display (SSD1333) | Panel init and full-frame RGB565 blit over SPI |
| Fuel gauge (MAX17260) | I2C access to the ModelGauge m5 EZ state-of-charge and analog measurements |
| GPIO expander (PI4IOE5V9554A) | I2C access to the 8 expander channels: per-pin output, input read |
| microSD card (FATFS over SPI) | Mount/unmount a FAT volume at "/sdcard" and read card presence |
| Services | High-level services built on top of the drivers and bsp layers |
| Audio sink interface | Output-agnostic PCM sink: the pipeline writes frames here without knowing whether they go to the wired DAC or to Bluetooth A2DP |
| Audio decoder | Decode an MP3 or WAV file into PCM for an Audio sink interface |
| Audio pipeline | Real-time task feeding PCM from a source to an Audio sink interface |
| Playback transport | Play/pause/resume/stop/next/prev over the playlist, with auto-advance on EOF |
| Playlist service | Current track + next/prev navigation over the storage index (no hardware) |
| Track metadata | Read tags + format from a file without playing it (for now_playing and the browser) |
| Volume service | Sole writer of the PCM5242 digital volume (pot -> DAC, with L/R balance) |
| Autonomy test service | Self-measured battery autonomy: workload run + discharge-curve logging |
| Bluetooth service | Classic Bluetooth A2DP source stack and connection management |
| Diagnostics service | Opt-in FreeRTOS stack / run-time / heap measurement for the characterisation campaign |
| Input service | Buttons -> ui_event_t queue, interrupt-driven and discrete (one press, one event) |
| Input logic (pure) | Debounce + press-edge detection + button->ui_event mapping, no hardware |
| Maintenance service | Shared low-priority task that periodically drives background chores |
| Power service | Battery state, charge detection, low-battery policy, and power on/off |
| Settings service | Persistent key/value store for user preferences (NVS-backed) |
| Storage service | Enumerate the SD card's playable tracks and serve them by index |
| User Interface | Framebuffer rendering, the screen interface, navigation and input events |
| Input events | The input events a screen can receive |
| Graphics | Software rendering into an in-RAM RGB565 framebuffer, blitted by gfx_flush() |
| Navigator | A fixed-depth stack of screens; the top screen owns input and rendering |
| Screen interface | The polymorphic screen contract, as a manual C "vtable" |
| Status bar | Permanent top bar shared by every screen: Bluetooth state, active output, battery percent |