Series

prplOS & AMX

40 posts · grouped as a learning path

Start with the methodStart at Part 0

Series practice · grow through practice

prplOS / AMX fundamentals test

No need to finish reading. Practice covers the whole tier bank; exams draw random questions.

Start here · Method: run on a PC, do not memorize

The runtime is not a board; PC first, then QEMU, then hardware.

  1. AMXRT is a runtime, not a board: why I always start on a PC

Part 0 · Environment: source build to a Docker base image

Install libubox/ubus/AMX/amxrt first; PC or a Docker base image, and examples run on top.

  1. AMX / prplOS development environment: from source to a Docker base image

Part 1 · Starting point: why build an object container in C

First, clarify that “container” means an object container, not list/string.

  1. Why Does Ambiorix Build Its Own “Container”?
  2. Why I Searched for a C Container for Years — Until Ambiorix (prplOS)

Part 2 · Overview: runtime, bus, data model

Start from UCI’s boundaries, lay out the three layers, then see how amxrt starts.

  1. From UCI to a data model: what prplOS improved, and why it is necessary
  2. Ambiorix (AMX) architecture: container, bus abstraction and data model
  3. amxrt CLI options explained (with examples)

Part 3 · Data model: objects, transactions, meaning

Objects/parameters/paths → libamxd in code → why it must exist.

  1. Ambiorix Data Model: Objects, Parameters, Paths (TR-181 style)
  2. Ambiorix Explained (6): libamxd — Building a Data Model in Code
  3. Ambiorix (Conclusion): What AMXD Really Means
  4. Proving with Code: Why AMXD Must Exist (60 Lines)

Part 4 · Containers: libamxc vs STL/GLib

Intrusive lists, zero allocation, Variant, and why not STL/GLib.

  1. libamxc Examples: C Containers for Embedded (prplOS / Ambiorix)
  2. Is libamxc a C STL? Ambiorix Containers vs C++ STL
  3. Ambiorix Explained (5): Lists and Queues — Why Is It Lighter Than GLib/STL?

Part 5 · Assembly and engineering: ODL, naming, debugging

ODL instead of annotations, naming conventions, and a real libamxb debugging note.

  1. C Has No Annotations — But It Has “Annotation-Like” Things: Starting from Ambiorix ODL
  2. Ambiorix Names: What Do AMX and libamxc Actually Mean?
  3. libamxb standalone client returns object_not_found on ubus: a reproducible pitfall

Part 6 · Integration: Yocto and prplOS

Put AMX into Yocto, and understand prplOS vs OpenWrt.

  1. How AMX calls UCI: CLI, libuci and backend modules
  2. Where the AMX data model lives: memory, ODL and UCI boundaries
  3. prplOS UCI backend: from TR-181 routes to /etc/config
  4. From TR-181 routes to UCI: a minimal mapping implementation
  5. Integrating Ambiorix (AMX) into Yocto: From Layer to Running
  6. prplOS vs OpenWrt: architecture, AMX/TR-181, and Raspberry Pi / BPI-R4 reality

Part 7 · Official examples: wait_for → amx-scheduler → cpu-info

Start with wait_for (one C file), then the minimal data model.

  1. AMX official examples map: from wait_for to greeter
  2. Ambiorix wait_for example: build and run amxrt from one C file
  3. Official example 02: amx-scheduler — the smallest data model (2 C + 2 ODL)
  4. Official example 03: cpu-info — read-only/volatile, instances and actions (8 C + 3 ODL)

Part 8 · Advanced examples: greeter, localagent and ODL

Plugins, apps, threshold events, plus ODL parsing and the full reference.

  1. Official example 06: greeter_plugin — a full data model in 4 C + 4 ODL
  2. Official example 04: greeter_app — putting AMX into an existing event loop
  3. Official example 05: localagent_threshold — a real TR-181 object
  4. Ambiorix ODL parsing (2): a bigger ODL (greeter)
  5. Ambiorix ODL parsing (1): from ODL to the data model (amx-scheduler)
  6. Ambiorix ODL reference: syntax, attributes, resolvers and parse order (handbook)
  7. How ODL %config is parsed: from text to parser->config

Part 9 · prplOS porting, build and code walkthrough

From x86-64 build and QEMU config to profiles, scripts and TR-181 LED code.

  1. Build prplOS for x86_64 and boot it in QEMU (GEN_CONFIG to make)
  2. prplOS porting (2): GEN_CONFIG — targeting QEMU armsr/armv8
  3. prplOS porting (3): why add another CONFIG layer on top of OpenWrt
  4. prplOS official profiles (1): 26 profiles, layered and how to choose
  5. Why these scripts exist: reproducibility is not fussiness
  6. LED management in prplOS: TR-181 Device.LEDs and tr181-led

Further reading

Want to leave a message?

Technical questions, feedback and leads: use the guestbook.

Guestbook →