Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Flash and RAM (Compile Time)

  • analyse compiled binary

,
  • with GNU size

, nm, analysing linker
  • and objdump

  • inspect memory map files

To measure memory at compile time, one can analyse the resulting binary and associated metadata, such as memory map files. Analysis at compile time allows assessing full Flash usage and partial RAM usage. It can be performed with more or less granularity, depending on the tool used. Available tools include GNU objdump, size, and nm ; the memory map file generated by the linker can also be used for manual inspection or automated parsing.

...

Code Block
$ painted_words=$(( (0x20001000 - 0x20000440) / 4 ))
$ remaining_bytes=$(probe-rs read b32 0x20000440 $painted_words --chip nRF52840_xxAA | tr ' ' '\n' | grep deadbeef | wc -l | awk '{print $1*4}')
$ echo $(( (painted_words * 4) - remaining_bytes))
908

Measuring Execution Time

timers, gpio's connected to logic

...

analyzers

Measuring Energy Consumption

multimeters, oscilloscopes, power profilers

Correlating Execution Time and Energy Consumption

Syncing execution time and energy consumption: power profiler with gpio

Step-by-step Granular Time and Energy Consumption

Obtaining step-by-step time and energy consumption: merging results from power profiler and logic analyser

Measuring Message Sizes

logging, hardware packet sniffing, packet analysis tools (wireshark)

...