How inferi70/gp-2040-glyph works
GP2040-CE is configurable RP2040 gamepad firmware: board inputs become gamepad state, optional input-processing features modify behavior, and a selected input-mode driver exposes controller reports to a host. Its embedded web configurator manages mappings, profiles, peripherals, and feature settings; firmware storage persists configuration. The README also documents display, LED, audio, and customization features. The tree and README support these major branches, but only storage, one driver, and parts of layout/configurator code were sampled, so detailed wiring for other subsystems is omitted.
Main entry points: gp2040.cpp Firmware loop · src Web configurator · storagemanager.cpp Config and profiles · addons Feature addons
Components 20
Firmware Runtime
- Firmware loop
src/gp2040.cpp - Gamepad state
src/gamepad.cpp - Input addons
src/addonmanager.cpp
Controller I/O
- Driver manager
src/drivermanager.cpp - USB transport
src/usbdriver.cpp - Platform drivers
src/drivers
Configuration
- Web configurator
www/src - Firmware web API
src/webconfig.cpp - Config and profiles
src/storagemanager.cpp - Config serialization
src/config_utils.cpp - On-device flash
lib/FlashPROM/src/FlashPROM.cpp
Features and UI
- Button layouts
src/layoutmanager.cpp - Display UI
src/display/GPGFX_UI.cpp - LED animations
src/animationstation/animationstation.cpp - Feature addons
src/addons
Board Support
- Board definitions
configs - Peripheral manager
src/peripheralmanager.cpp
Other components
- Physical controls
- Console or PC
- Configurator user
Connections 19
- Physical controls → Firmware loop: provides input
- Firmware loop → Gamepad state: updates state
- Firmware loop → Input addons: dispatches processing
- Firmware loop → Driver manager: selects mode
- Driver manager → Platform drivers: dispatches reports
- Platform drivers → USB transport: sends reports
- USB transport → Console or PC: reports controls
- Configurator user → Web configurator: configures
- Web configurator → Firmware web API: requests settings
- Firmware web API → Config and profiles: reads and updates
- Config and profiles → Config serialization: serializes config
- Config serialization → On-device flash: persists settings
- Config and profiles → On-device flash: resets storage
- Web configurator → Button layouts: configures layouts
- Display UI → Button layouts: uses layout definitions
- Input addons → Feature addons: dispatches features
- Board definitions → Peripheral manager: defines hardware options
- Peripheral manager → Feature addons: supports peripherals
- LED animations → Feature addons: supports LED effects