MQX 在开启telnet服务后,如何把printf打印的信息通过telnet客户端打印出来

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MQX 在开启telnet服务后,如何把printf打印的信息通过telnet客户端打印出来

1,448 Views
yongzhenyan
Contributor I

MQX 在开启telnet服务后,如何把printf打印的信息通过telnet打印出来。默认的是串口打印。telnet成功后,通过telnet命令调用的printf都能打印出来。但是在别的程序中直接调用printf,telnet客户端没有反应,打印不出来。如何重定位printf函数到telnet客户端。

Tags (1)
0 Kudos
1 Reply

1,088 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi Yongzhen:

Please refer to the file. 

Freescale_MQX_4_2\mqx\source\include\fio.h

I would suggest you comment the next line like this

//define printf _io_printf

and recompile the libraries and your application .

I hope it will help.

Regards

Daniel

0 Kudos