Sheet 5/10 — Firmware · Device Trees
mzDTB
Device Tree Blob generation and parsing, from host tools to bare metal.
| Layer | Firmware · Device Trees |
|---|---|
| Language | C |
| Targets | arm · arm64 |
| Depends on | — (foundation) |
| Used by | mzOS2 |
| Organization | microZeus |
| Source | Private alpha — opens with a change order on this site’s log |
General notes
mzDTB is a complete Device Tree Blob toolkit for the ARM side of mzOS2. It pairs a freestanding parser library — no libc required, usable inside a BIOS or kernel — with host-side tools for generating, validating, and converting DTBs, and CMake integration that produces the right DTB automatically at build time.
gen_dtb emits a minimal device tree with configurable memory layout and a simple framebuffer node; dtb2c embeds binary blobs as C arrays; the parser walks trees with callbacks, reads properties, and extracts memory regions with proper big-endian handling throughout.
Bill of materials — what’s in the box
- Freestanding parser — runs in bare-metal environments
- gen_dtb: configurable memory size, base address, and framebuffer nodes
- dtb2c: binary DTB → embeddable C source
- QEMU DTB extraction for ARM/ARM64 platforms
- Automatic DTB generation wired into the CMake build