Power capture with a Joulescope
Capture current, charge and energy for the clean inference window of a profile run. You will learn what the config adds, what the run does after the profile pass, and which health signals decide whether the energy number can be quoted.
Hardware and wiring
Section titled “Hardware and wiring”An Apollo510 EVB, a J-Link, and a Joulescope JS110, JS220 or JS320 in series with the board’s supply, with its GPIO input on the board’s sync pin and, on the JS220 and JS320, its Vref pin wired. The wiring, the pin table and the instrument differences are on Joulescope; read it before plugging anything in.
Software prerequisites
Section titled “Software prerequisites”hpx with the aot extra (pyjoulescope_driver ships with hpx), the
toolchain and J-Link software, and on Linux the Joulescope udev rule.
hpx power-on is the smoke test that the instrument is seen.
Config file
Section titled “Config file”examples/quickstart/hpx_aot_power.yml:
model: path: kws_model.tflite arena_size: 131072engine: type: helia-aot config: prefix: hpx module_name: hpx_modeltarget: board: apollo510_evb toolchain: arm-none-eabi-gccprofiling: pmu_counters: cpu: default per_layer: true iterations: 3 warmup: 1power: enabled: true driver: joulescope mode: external duration_s: 20 io_voltage: 1.8 sync_gpio_pin: 29output: format: csv dir: ./results/results_aot_powerpower.enabled turns the five power stages on; driver, mode,
duration_s, io_voltage and sync_gpio_pin are explained on
Power measurement and the generated
configuration reference.
cd examples/quickstarthpx power-on --driver joulescopehpx profile --config hpx_aot_power.ymlThe run profiles as usual, then builds and flashes a dedicated power binary, arms the Joulescope, resets the board and captures the gated clean window.
Expected output
Section titled “Expected output”Not yet captured on this bench. A completed run adds a power block to
summary.json with measurement_scope, energy_per_inference_j,
capture_duration_s, the gated-window statistics and the health signals;
the fields are listed on Output files and the
terminal panel is described on Verifying a capture.
How to read it
Section titled “How to read it”measurement_scopemust readgpio_gated_clean_windowfor the energy per inference to mean one inference; the other scopes are explained on Windows and lock-step.- The
power.window_*andgated_window_duration_suspectcodes inissuesare the health checks; adegradedverdict with one of them means the number is a caveat, not a measurement. - Compare two power runs only through
hpx compare, which withholds the power deltas when the scope, mode, firmware, probe or clean workload differ (Analysis and comparison).
Variations
Section titled “Variations”- Reading the block the run wrote: Read a power summary; holding two captures against each other: Compare two power runs.
- heliaRT instead of heliaAOT: copy the
powerblock intohpx_rt.yml. - INA228 on the board instead of a Joulescope:
power.driver: ina228, a different measurement scope, on INA228. - Longer captures for tighter statistics: raise
duration_s; the fixed inference count is derived from the profile pass’s clean timing.
Validated on
Section titled “Validated on”Not yet validated. The nightly hardware validation runs with power: off,
and no captured power bundle is shipped with the documentation. The
configuration above is the checked-in quickstart file; the bench facts on
the linked measurement pages are cited there.