Capture serial communication output from the full chip simulation

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

Capture serial communication output from the full chip simulation

1,737 次查看
Brynas
Contributor I

Hello,

I'm completely new to using the full chip simulation and haven't really found information about what I'm looking for anyway. Basically what I want to do is to run some code in the simulator that prints some text to the serial output using printf and then capture the output from outside the simulator somehow. I've started to write a Hello World program just to get the functionality but I don't seem to get it right.

 

What I would like to do is:

1. Call the simulator from a command prompt and execute my hello world program

2. Capture the output in a terminal window of some sort.

 

Is this possible?

标签 (1)
标记 (1)
0 项奖励
回复
3 回复数

986 次查看
kef
Specialist I

What's your target architecture? You can use printf, terminal, etc with S12(X) simulator. Unfortunately S08 simulator is unable to do that.

0 项奖励
回复

986 次查看
Brynas
Contributor I

I use MC9S12P128.

 

Actually I managed to print my Hello World now the terminal window in the simulator and also to a text file. What I'm curious about now is if there is any possibility to automatically execute the simulation and just store the output to file? What I would like to do is to automatically build the program using a Continuous Integration engine or similar, then execute a number of unit tests on the simulator and store the result for automatic parsing.

 

Is it possible to execute the simulator from the command prompt?

0 项奖励
回复

986 次查看
J2MEJediMaster
Specialist I

In {CodeWarrior Installation}\(CodeWarrior Examples)\Scripting\PERL you will find an example Perl script that does a few simple things in the debugger. For more information on the commands you can use in a Perl script, consult the Debugger_HC12.pdf manual, the section Book IV - Commands and Environment Variables.

 

---Tom

0 项奖励
回复