Qt for MCUs · Traveo T2G class target
From .qml to silicon , build, flash, execute, allocate
Eight stages tracing a Qt Quick Ultralite application from source through ahead-of-time compilation, into internal and external flash, up into RAM at boot, and out to the display controller. Worked figures come from a 1280×768 CYT4DN cluster build.
kinematics.cpphand-written C++
float solveIK(const Pose &p) { … 40 lines … }
→.textinternal flash · XIP
static const float kArmLength[6] = { 1.2f, 0.9f, … };
→.rodataread in place
static int calibOffset = 42;
→.data imgcopied to SRAM
static float jointAngle[6];
→.bssno flash cost
MainScreen.qml → MainScreen.cpp → MainScreen.ogenerated
Rectangle { … } , the object instance itself
→.bsspermanent RAM
construction + property-set code for that tree
→.textinternal flash
Text { text: "SPEED" } , the literal
→.rodatainternal flash
text: speed * 1.6 , JS binding, now a C++ functor
→.text+ node in .bss
Image { source: "gauge_bg.png" } , pixel data
→resource blobexternal flash
Assetsfrom stages 02 and 03
gauge_bg.png , large, uncompressed
→resource blobread in place
icon_warn.png , small, boot-critical
→.rodatainternal flash
Roboto , static engine: baked glyph bitmaps
→.rodatainternal flash
Roboto , vector engine: subsetted outlines
→font blobexternal flash
Internal code flash · memory mapped · executable4 MB
programmed as app.hex
External flash over SMIF · memory mapped · read-onlyQSPI / HyperFlash
programmed separately as resources.bin
moves flash → SRAM at startup
stays in flash, read in place
stays in external flash
claimed, never copied
VRAM region, dedicated, does not touch the heap2 MB · 96% occupied
claimed statically at platform init, never malloc'd
System SRAM, the heap comes from hereheap = the remainder
fixed at link time
available for allocation
| Consumer | Region | Fixed at | Reduces heap? |
|---|---|---|---|
| Layer / frame buffers | VRAM | platform init | no, separate region |
| Image / glyph / text caches | VRAM | build config | no, separate region |
| .data + .bss | SRAM | link time | yes |
| Task and core stacks | SRAM | link / RTOS config | yes |
| RAM-resident functions | SRAM / TCM | linker script | yes |
| Free heap | SRAM | whatever survives | the remainder |