TI中文支持网
TI专业的中文技术问题搜集分享网站

TM4C123GH6PM CDC串口不能通讯问题

TI工程师您好!我用的是官方的例程,tivaware下ek-tm4c123gxl的USB_DEV_serial例程,程序可以运行,Windows下也安装了CDC的驱动并虚拟出来个串口,但是我用串口助手发送数据却没有任何数据返回,程序可以进入USBUARTIntHandler中断,但状态是发送,在PC端却接收不到任何数据,为什么?我用UARTprintf发送数据也收不到任何数据,我应该怎么调试?

user524568:

我通过仿真,确定串口发送的数据,USB端都正确的收到并读取,然后数据直接通过ROM_UARTChartPutNonBlovking放入USB的发送FIFO中,但PC端却没收到数据,不知道为什么?我的USB只接了4根线,电源,地,DP,DM。

xyz549040622:

回复 user524568:

我跑这个例程试试,应该是你的测试办法不对吧。

user524568:

回复 xyz549040622:

测试的怎么样?我想知道是硬件问题还是软件问题,还是测试方法问题。

yongchang xu:

楼主,你的USB_dev_bulk例程调试可以吗?

Zhenghu wang:

回复 yongchang xu:

USB_dev_bulk例程怎么测试?我写于了这个例程,但不知道怎么测试,它不像CDC那么好测试。CDC用串口调试助手就可以了,这也是我选择CDC的原因。

xyz549040622:

回复 Zhenghu wang:

USB Generic Bulk Device

This example provides a generic USB device offering simple bulk datatransfer to and from the host. The device uses a vendor-specific class IDand supports a single bulk IN endpoint and a single bulk OUT endpoint.Data received from the host is assumed to be ASCII text and it isechoed back with the case of all alphabetic characters swapped.

A Windows INF file for the device is provided on the installation CD andin the C:/ti/TivaWare-for-C-Series/windows_drivers directory of TivaWare Cseries releases. This INF contains information required to install theWinUSB subsystem on Windowi16XP and Vista PCs. WinUSB is a Windowssubsystem allowing user mode applications to access the USB device withoutthe need for a vendor-specific kernel mode driver.

A sample Windows command-line application, usb_bulk_example, illustratinghow to connect to and communicate with the bulk device is also provided.The application binary is installed as part of the ''Windows-side examplesfor USB kits'' package (SW-USB-win) on the installation CD or via downloadfrom http://www.ti.com/tivaware . Project files are included to allowthe examples to be built using Microsoft VisualStudio 2008. Source codefor this application can be found in directoryTivaWare-for-C-Series/tools/usb_bulk_example.

根据官方的说法,用VS2008编译生成一个软件,然后就可以交互运行了。

赞(0)
未经允许不得转载:TI中文支持网 » TM4C123GH6PM CDC串口不能通讯问题
分享到: 更多 (0)