can i test a code in codewarrior4.6 without a target board?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

can i test a code in codewarrior4.6 without a target board?

跳至解决方案
2,418 次查看
Xbot
Contributor II
hi,
 
i want to test a code and perform instructions to verify how many clock cycles are spent. Is this possible?
 
thanks,
标签 (1)
标记 (1)
0 项奖励
回复
1 解答
1,411 次查看
CrasyCat
Specialist III
Hello
 
You can use the simulator for that.
 
I would proceed as follows:
  - Start the simulator and load your code
  - Set a Breakpoint on the beginning of the code snippet on which you want to evaluate the cycle count
  - Set a breakpoint at the end of the code snippet on which you want to measure cycle count
  - Run till first breakpoint is reached.
  - On the debugger Status bar you have different area. Next to the frequency area you have a small
   area denoting the current cycle counts. Double click within that area to reset the cycle count to 0
  - Run till second breakpoint is reached
 
You see the number of cycles between the two breakpoint in the status bar (in the area where you did double click before).
 
I hope this helps
 
CrasyCat

在原帖中查看解决方案

0 项奖励
回复
2 回复数
1,412 次查看
CrasyCat
Specialist III
Hello
 
You can use the simulator for that.
 
I would proceed as follows:
  - Start the simulator and load your code
  - Set a Breakpoint on the beginning of the code snippet on which you want to evaluate the cycle count
  - Set a breakpoint at the end of the code snippet on which you want to measure cycle count
  - Run till first breakpoint is reached.
  - On the debugger Status bar you have different area. Next to the frequency area you have a small
   area denoting the current cycle counts. Double click within that area to reset the cycle count to 0
  - Run till second breakpoint is reached
 
You see the number of cycles between the two breakpoint in the status bar (in the area where you did double click before).
 
I hope this helps
 
CrasyCat
0 项奖励
回复
1,411 次查看
Xbot
Contributor II
it sure did help a lot with regards to the procedure where you can reset the clock cycle... thanks.
0 项奖励
回复