0000 a7f9 [2] <-- cylces AIS #-7 17: volatile byte marker=0; 0002 95 [2] TSX 0003 7f [4] CLR ,X 18: 19: volatile word data=0xaaaa; 0004 45aaaa [3] LDHX #-21846 0007 9eff02 [5] STHX 2,SP 20: volatile word data2=0x5555; 000a 455555 [3] LDHX #21845 000d 9eff04 [5] STHX 4,SP 21: volatile word data3=0xcccc; 0010 45cccc [3] LDHX #-13108 0013 9eff06 [5] STHX 6,SP 22: 23: ReturnAddress = (word) ▮ 0016 95 [2] TSX 0017 960000 [5] STHX ReturnAddress 24: ReturnAddress = *((word*) (&marker +OFFSET)); 001a 9efe04 [5] LDHX 4,SP 001d 960000 [5] STHX ReturnAddress 25: ReturnAddress =(word) GetMyCaller; 0020 450000 [3] LDHX @GetMyCaller 0023 960000 [5] STHX ReturnAddress 26: 27: } 0026 a707 [2] AIS #7 0028 81 [6] RTS 28: 29:
It doesn't have any such feature that I am aware of. Of the options given in your first post, I would almost always perfer using a pin on the microcontroller. I usually have at least 1 status LED on a board and I often use this in the developement process to find the length of time routines take, the loading due to ISRs and anything else timing related. It will add a minimum of time to a routine, and the amount of time added is known. For a quick estimate I just disassmble the code to get a look at the assembly lines generated from each line of C. In the end, I don't know of much anything much easier than toggling a pin and using a scope.
jmd wrote:Regarding the cicrocontroller, I am currently working with an AW60 micro, but my question is general. I am wondering if the Codewarrior includes an option in order to generate a log file or something similar that I can use to estimate the CPU consumption.