Provide input data to FPGA using USB

Neel Mehta picture Neel Mehta · Aug 21, 2011 · Viewed 7.3k times · Source

I am working on Xilinx Spartan 3E platform, using this development board:

http://www.xilinx.com/products/boards-and-kits/HW-SPAR3E-SK-US-G.htm

My program operates on certain data and then provides output. I wish to transfer the input signals externally. The input data is a stream of 8-bit signals.

So, how do I send the input signals from my laptop to the FPGA via USB? Does Xilinx support this or is there standard software to do this?

Thanks.

Answer

davidd picture davidd · Aug 21, 2011

It sounds like you are describing a uart more than a native USB interface. You can get a USB to logic level serial adapter that will let you easily transfer data to and from a Pc at up to 921.6k baud. A uart/serial port is easy to implement in the Fpga and PCs are easy to use with serial ports.

Here is the cable: http://www.ftdichip.com/Products/Cables/USBTTLSerial.htm If you have a development card it is very possible this type of interface is present.

On the software side you can use your programming language of choice as if it was interfacing with a seal port or use a terminal program like hyper terminal or Download teraterm http://ttssh2.sourceforge.jp/

Updated response: 100Hz is not a hard interface to make. At that rate you should use the serial interface if at all possible. The board you referenced has 2 full RS-232 connections. At that point you only need a way to connect that to your computer. If you have a PC with RS-232 connectors you only need a cable if you have a newer computer without you need a RS-232 to USB translator cable (like this one: http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail&name=768-1014-ND or google rs232 usb). This will give you a virtual com port on the pc to interface with the previously mentioned terminal programs or your custom software.

Update 2: on the resource tab of the development board page you linked to there are several UART based fpga designs that you should be able to use as a starting point. i.e. the "PicoBlaze Processor SPI Flash Programmer".