markf 0 Posted August 21, 2011 Share Posted August 21, 2011 At first I'd like to say hello to all forum members :-) My question is: where I can check the memory usage of program after compilation in IAR Embedded Workbench? Cheers. Quote Link to post Share on other sites
nobody 47 Posted August 21, 2011 Share Posted August 21, 2011 First: go to Project -> Options -> Linker -> List and check "Generate linker listing" After you rebuild project, open file "YourProjectName".map in your Project tree. And at the low end of the file you find something like 908 bytes of CODE memory 80 bytes of DATA memory (+ 17 absolute ) 512 bytes of CONST memory bluehash 1 Quote Link to post Share on other sites
markf 0 Posted August 21, 2011 Author Share Posted August 21, 2011 So if I sum all the values together, and then subtract it from 2048 I'll get how many bytes left. I.e. 2048 - (908+80+17+512) = 2048 - 1517 = 531 bytes free. (1517/2048) * 100 = 74% of memory used. Quote Link to post Share on other sites
nobody 47 Posted August 22, 2011 Share Posted August 22, 2011 You are wrong. Not all segments is in the flash memory. Eg. segment "DATA" is in RAM. "DATA" segment contains variables and stack. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.