Posts: 2
Registered: ‎06-06-2011

How to read data from an FPGA through USB

Hello Everyone,


My project has a requirement for an FPGA Board. We have a design IP which generates data which we want to store in memory and further stream it through an USB or stream it directly through an USB onto a PC. Also, we require software API’s along with the board which enables to read data through the USB and store it into a file or display it as waveforms onto the PC.


Summary of requirements for the FPGA boards:

1)  Reading Data from a memory through a USB on the FPGA Board or directly streaming data through the USB on to PC.

2)  The necessary software bundles and API references suite to read data through USB and store it in a file or stream real time data through the USB onto a PC.


If there are relevant boards as per the requirements mentioned above, I would be grateful if anyone could please provide further information and present some relevant links and also some alternate methods to read data from FPGA memory(SDRAM/DDR/ or even Synthesized logic memory on FPGA).

Thanks in advance,


Firoz Dang           

Avnet Employee (Star Contributor)
Posts: 614
Registered: ‎04-20-2009

Re: How to read data from an FPGA through USB



You have three options:


  1. Use a USB MAC core in the FPGA with an external USB PHY
  2. Use a dedicated USB controller, like the Cypress FX2
  3. Use an companion microcontroller that has a built-in USB peripheral (typically limited to full-speed)

Your choice depends on cost, bandwidth, and level of integration.  I'm not sure what is the best choice for you.  Either Avnet or Xilinx has example boards that show all 3 options.  If full-speed bandwidth is enough (max actual throughput is ~2-3 Mbps), then Option #3 is likely the least expensive and easiest to implement.  One example of this method that Avnet provides is the Spartan-6 LX16 Evaluation Kit (  This combines a Cypress PSoC 3 with built-in full-speed USB peripheral along with a Spartan-6 LX FPGA.  We use the USB connection for several operations, including USB-to-SPI bridge (used for FPGA slave serial configuration) and USB-to-UART bridge (for basic UART communication with FPGA).


If you need more bandwidth, then we'd need look at Options 1 or 2.  Let me know where your interest is, and we can share what we have available.