How do I know how much Flash is used by my application?
In EmberZNet EM250 stack releases 2.3 and higher, a utility called em2xx_ebl.exe runs in a post-processing step after the linker, turning your XPV and XDV files into a compressed binary format (EBL files) that the Ember Bootloader can read. In doing this, em2xx_ebl analyzes your code & data and reports the segment usage for the build's Flash usage.
In earlier releases, code size can be found by looking at the last line in your XPV file (the final Program memory datafile that gets uploaded). The first hex number shown in the last line is the highest address used for your application, shown in words [16 bits].
Since the Flash mapping of the EM250 the chip has about 112 KB available for your code, the total Flash usage reported by em2xx_ebl (or the last word address shown in your XPV file) should never be higher than 0xE000. (If it is, the code won't fit and the build and/or upload will fail.)
- Login to post comments









