# halbeshuhn/cardputer-radiopod architecture

> Architecture diagram of the GitHub repository halbeshuhn/cardputer-radiopod, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/halbeshuhn/cardputer-radiopod
- Repository: https://github.com/halbeshuhn/cardputer-radiopod

## Overview

Cardputer-RadioPod is standalone firmware combining internet radio and an on-device podcast player. The principal podcast workflow is discover/search in Apple Podcasts, subscribe, browse episodes, then stream or download and resume per episode; a separate radio mode browses stations and plays internet streams. The tree exposes podcast, audio-compatibility, Wi-Fi, language, and demux headers, but no main sketch or radio implementation. Accordingly, several documented capabilities use the existing firmware directory as their supported path; wiring not established by excerpts is omitted.

Main entry points: [`v1.0.1/M5Cardputer_PodRadio/PodUi.h`](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h) (Podcast interface), [`v1.0.1/M5Cardputer_PodRadio`](https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio) (Radio mode), [`v1.0.1/M5Cardputer_PodRadio/AudioCompat.h`](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/AudioCompat.h) (Radio audio compatibility), [`v1.0.1/M5Cardputer_PodRadio/CardWifiSetup.h`](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/CardWifiSetup.h) (Wi-Fi setup)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_podcast["Podcast player"]
  node_podui["Podcast interface<br/>[PodUi.h]"]
  node_podfetch["Podcast discovery<br/>[PodFetch.h]"]
  node_podfeed["Episode feeds<br/>[PodFeed.h]"]
  node_podstate[("Subscriptions &amp; resume<br/>[PodUi.h]")]
  node_episodes["Episode audio<br/>[M4aDemux.h]"]
  node_downloads[("SD downloads<br/>[PodUi.h]")]
end

subgraph group_radio["Internet radio"]
  node_radio_ui["Radio mode"]
  node_station_search["Station browsing"]
  node_audio["Radio audio compatibility<br/>[AudioCompat.h]"]
end

subgraph group_shared["Device services"]
  node_wifi["Wi-Fi setup<br/>[CardWifiSetup.h]"]
  node_device["Cardputer firmware"]
  node_language["German / English<br/>[Lang.h]"]
end

node_listener(("Listener"))
node_apple{{"Apple Podcasts"}}
node_station_service{{"Station listings"}}
node_station_stream{{"Station streams"}}
node_output(("Device audio output"))

node_listener -->|"chooses podcasts"| node_podui
node_podui -->|"requests discovery"| node_podfetch
node_podfetch -->|"searches catalog"| node_apple
node_podui -->|"loads episodes"| node_podfeed
node_podui -->|"stores progress"| node_podstate
node_podui -->|"downloads / deletes"| node_downloads
node_podui -->|"plays episode"| node_episodes
node_podui -->|"configures network"| node_wifi
node_listener -->|"opens radio"| node_radio_ui
node_radio_ui -->|"browses stations"| node_station_search
node_station_search -->|"searches listings"| node_station_service
node_radio_ui -->|"starts stream"| node_audio
node_audio -->|"reads stream"| node_station_stream
node_audio -->|"outputs audio"| node_output
node_wifi -->|"provides connectivity"| node_station_service
node_wifi -->|"provides connectivity"| node_station_stream

click node_podui "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h"
click node_podfetch "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodFetch.h"
click node_podfeed "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodFeed.h"
click node_podstate "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h"
click node_episodes "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/M4aDemux.h"
click node_downloads "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h"
click node_wifi "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/CardWifiSetup.h"
click node_device "https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio"
click node_language "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/Lang.h"
click node_radio_ui "https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio"
click node_station_search "https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio"
click node_audio "https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/AudioCompat.h"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_podui,node_podfetch,node_podfeed,node_podstate,node_episodes,node_downloads toneBlue
class node_radio_ui,node_station_search,node_audio toneAmber
class node_wifi,node_device,node_language toneMint
class node_listener,node_apple,node_station_service,node_station_stream,node_output toneIndigo
```

## Components

### Podcast player

- [Podcast interface](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h): `v1.0.1/M5Cardputer_PodRadio/PodUi.h`
- [Podcast discovery](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodFetch.h): `v1.0.1/M5Cardputer_PodRadio/PodFetch.h`
- [Episode feeds](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodFeed.h): `v1.0.1/M5Cardputer_PodRadio/PodFeed.h`
- [Subscriptions & resume](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h): `v1.0.1/M5Cardputer_PodRadio/PodUi.h`
- [Episode audio](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/M4aDemux.h): `v1.0.1/M5Cardputer_PodRadio/M4aDemux.h`
- [SD downloads](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/PodUi.h): `v1.0.1/M5Cardputer_PodRadio/PodUi.h`

### Internet radio

- [Radio mode](https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio): `v1.0.1/M5Cardputer_PodRadio`
- [Station browsing](https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio): `v1.0.1/M5Cardputer_PodRadio`
- [Radio audio compatibility](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/AudioCompat.h): `v1.0.1/M5Cardputer_PodRadio/AudioCompat.h`

### Device services

- [Wi-Fi setup](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/CardWifiSetup.h): `v1.0.1/M5Cardputer_PodRadio/CardWifiSetup.h`
- [Cardputer firmware](https://github.com/halbeshuhn/cardputer-radiopod/tree/main/v1.0.1/M5Cardputer_PodRadio): `v1.0.1/M5Cardputer_PodRadio`
- [German / English](https://github.com/halbeshuhn/cardputer-radiopod/blob/main/v1.0.1/M5Cardputer_PodRadio/Lang.h): `v1.0.1/M5Cardputer_PodRadio/Lang.h`

### Other components

- **Listener**
- **Apple Podcasts**
- **Station listings**
- **Station streams**
- **Device audio output**

## Connections

- Listener → Podcast interface: chooses podcasts
- Podcast interface → Podcast discovery: requests discovery
- Podcast discovery → Apple Podcasts: searches catalog
- Podcast interface → Episode feeds: loads episodes
- Podcast interface → Subscriptions & resume: stores progress
- Podcast interface → SD downloads: downloads / deletes
- Podcast interface → Episode audio: plays episode
- Podcast interface → Wi-Fi setup: configures network
- Listener → Radio mode: opens radio
- Radio mode → Station browsing: browses stations
- Station browsing → Station listings: searches listings
- Radio mode → Radio audio compatibility: starts stream
- Radio audio compatibility → Station streams: reads stream
- Radio audio compatibility → Device audio output: outputs audio
- Wi-Fi setup → Station listings: provides connectivity
- Wi-Fi setup → Station streams: provides connectivity
