Application Module
Application Module
app/ is the firmware composition root. It is small on purpose — the bulk of the code lives in src/, and app/ is what wires the right pieces together for the right firmware build.
The module owns:
- the compile-time firmware profile in
app/firmware_,profile.hpp - runtime composition and startup wiring in
app/app_runtime.*, - the static task table consumed by the launcher in
app/task_,descriptor.hpp - the launcher entrypoint in
app/.main.cpp
Startup sequence
app/ performs a fixed startup, in this order:
- initialize stdio,
- obtain the singleton
AppRuntime, - run
AppRuntime::prepare(), - enable the watchdog,
- spawn tasks from
AppRuntime::tasks(), - apply optional core affinity,
- start the FreeRTOS scheduler.
Startup is fail-fast. Any failure in prepare or in task creation ends in the terminal halt path — there is no "limp along with half
the runtime" mode, because that is exactly the kind of state that is hard to debug remotely.
Profile model
The firmware topology is compile-time data, in app/firmware_. The current profile keeps:
radio1enabled with the NPR runtime,radio2available as a compile-time flag, with no runtime implementation yet,- feature gates for USB, W5500, and PPPoS integration.
Compile-time selection is deliberate. It makes the firmware image auditable — what is in the binary is exactly what the profile says should be in the binary — and it keeps cold paths from quietly shipping into a build that does not need them.