PocketMage SDK Documentation

PocketMage SDK Documentation

A PocketMage app is a standalone ELF the host firmware loads at runtime and runs in-process. There is no firmware reflash: you build an ELF, pack it with an overlay sidecar and an icon, copy the tar onto the SD card, and install it through the on-device app loader. These docs cover the whole path, from installing the toolchain to the binary contract the loader enforces.

Get Started
Guides
API reference
Binary contract
Tooling
Publishing

Get started

New here? Go from an empty directory to a running app in two steps.

Get Started

What a PocketMage app is, what you need installed, and the shortest path to a running ELF.

Open
Install the toolchain

The pinned espressif Xtensa compiler, the elf_overlay host tools, and the pm CLI.

Open
Your first app

Scaffold, build, gate, pack, and install a minimal app end to end.

Open

Guides

Walkthroughs of the whole app model.

Making an app

From pm new to a running ELF: scaffold, build recipe, delivery tar, and the host loader.

Open
App lifecycle

Entry points, the host/app export model, APP_INIT, and exiting cleanly.

Open
Rendering

The two-display model, the buffered E-Ink refresh rhythm, and the scroll loop.

Open
Internationalization

Give an app translatable strings: the catalog it ships and the runtime that resolves them.

Open
Publishing

The delivery tar, the 40x40 icon, assets, and what APPLOADER does with them.

Open
Guides overview

Guide index and cross-links into the deep references.

Open

API reference

Every component the SDK publishes, with semantics and its pm_* C ABI. Start at the overview.

API overview

The umbrella header, the PM_TARGET_HOST/PM_TARGET_APP split, the singleton pattern, and the pm_* projection model.

Open
Function index

Every pm_* wrapper and its exact signature, grouped by module.

Open
Displays

OLED, E-Ink, Font, Layout, UI helpers.

Open
Input

Keyboard, Touch.

Open
System

Sys and globals, SD card, Clock, Buzzer, WiFi, i18n runtime.

Open

The binary contract

What the loader accepts and how an app’s dependencies resolve.

App ABI

The binary shape the loader accepts: format, entry, two-stage load, failure modes.

Open
Overlay format (.elfo)

The overlay sidecar that pages app code into executable RAM, and what it contains.

Open
Symbols

The host-export surface an app’s undefined list resolves against, and how to change it.

Open

Tooling

The build and release tools.

Building apps

A Makefile including tools/app.mk is the whole build system. Toolchain, targets, icon, overlay.

Open
pm CLI

Scaffolding, building, the enforcing dependency gate, packing, exports, and release bumps.

Open
i18n catalogs

The generator and the merge rules that keep string IDs stable across the SDK and app catalogs.

Open

Help

Troubleshooting

The failures a build or load hits most, what causes each, and how to fix it.

Open
Glossary

Every term these docs use, defined once, with links to the page that owns the concept.

Open
Migration

Moving a pre-ELF app to the runtime-load flow.

Open

Start here

  1. Install the toolchain: Get Started.
  2. Build your first app end to end: Your first app.
  3. Learn the model: Making an app, then the API overview.
  4. Read the contract: App ABI and Overlay format.
  5. Check what your app resolves against: Symbols.
  6. Ship a tar: Publishing.
  7. Port existing code: Migration.