Debugging: printf() problem

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

Debugging: printf() problem

1,083 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Muis on Wed Jan 09 03:53:59 MST 2013
I often experience that the printf() output gets malformed. Each call results into characters in the console, but they are all unreadable chinese characters. Most of the times the first few lines appear OK, and from then on only garbage.

I expected this had something to do with the clock settings, but even using the default (48 Mhz) clock, I have this problem.

What could be causing this behaviour?
0 项奖励
回复
5 回复数

1,005 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by TheFallGuy on Wed Jan 09 09:00:08 MST 2013
As zero said, can you provide a project that shows the problem?
0 项奖励
回复

1,005 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Muis on Wed Jan 09 05:32:28 MST 2013
Currently I experience it with LpcExpresso v5 and a LPC11U35, but I noticed the same problem with LpxPresso v4 and a LPC1768 too in the past. Few days ago I had with a LPC11U14.

So the LpcExpresso version / MCU model seemed not to matter to me ;)
0 项奖励
回复

1,005 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Wed Jan 09 05:17:30 MST 2013
Could be useful if you disclose us which OS / LPCXpresso / MCU / printf-Setup you are using :confused:

Also a sample project could help to verify this effect :)
0 项奖励
回复

1,005 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Muis on Wed Jan 09 05:08:09 MST 2013
The problem is not that its slow (its fast enough for me), but that I get a chinese character when i call print("1");
0 项奖励
回复

1,005 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Wed Jan 09 04:06:28 MST 2013

Quote: muis
What could be causing this behaviour?



Semihosting printf to console is very slow ;)
0 项奖励
回复