Mimas Artix 7 FPGA Development Board

Programming Mimas A7 using OpenOCD and XC3SProg

40 views November 22, 2018 jyothi-as 0

Programming Mimas A7 using OpenOCD

What is OpenOCD?

OpenOCD stands for Open On-Chip Debugger. It is an open-source software that supports debugging a wide variety of chips, devices and boards using a range of supported debug interfaces. If you find a device which is not supported by OpenOCD, being an open-source software, you can add support for that device in OpenOCD yourself and submit patches so that your improvements can be merged into OpenOCD for others to use. OpenOCD is used for debugging as well as in-system programming for embedded target devices. The Mimas A7 FPGA Development Board features a high-speed USB 2.0 interface which is connected to FPGA IC’s JTAG signals. So, Mimas A7 can be programmed using its on-board USB interface using OpenOCD, without the need for a separate external JTAG programmer.

Configuration using OpenOCD

The following steps will walk you through the process of configuring Mimas A7 board using OpenOCD.

Step 1:

Download and extract the latest Windows version of OpenOCD from its website http://openocd.org to a suitable location in your system.

Step 2:

To program Mimas A7 through its USB interface, “WinUSB” drivers need to be installed instead of the default drivers installed by Windows. To install “WinUSB” drivers, download and run latest version of “Zadig“. Go to Options click “List all devices” and select it.

Select “Mimas A7 FPGA Module(Interface 1)” as shown in the image below.

Step 3:

Select “WinUSB” drivers in target driver to replace the “FTDIBUS” drivers. Click “Replace Driver” to install WinUSB drivers as follows.

You will see the following message if drivers were installed correctly.

Step 4:

Download numato_mimasa7.cgf from here. Save the downloaded “numato_mimasa7.cfg” file to the “openocd/scripts/board” directory.  Open Command Prompt or PowerShell in “bin-x64” directory which is located in “openocd” folder.

Step 5:

Use the following command in Command Prompt or PowerShell to program FPGA. You need to replace <bitstream file> with the actual location of your .bit file. OpenOCD should show output similar to the image shown below if the programming process finished successfully.

openocd.exe -f board/numato_mimasa7.cfg -c "init" -c "pld load 0 <bitstream file>" -c "shutdown"

Congratulations on successfully programming your bitstream to Mimas A7 using OpenOCD, without the need of any external JTAG hardware.

To change the drivers back to FTDI USB drivers follow these steps:

Open Device Manager-> Universal Serial Bus Devices, select Mimas Artix 7 FPGA Module, right-click and select “Uninstall device”. In the “Uninstall Device” dialog window, select “Delete the driver software for this device.” and click “Uninstall”.


Scan for hardware changes to verify that USB Serial Converter A now comes under “Universal Serial Bus Controllers”.

 

 

Programming Mimas A7 using XC3SProg

What is XC3SProg?

XC3SProg is a software for programming a wide variety of chips, devices and boards. XC3SProg reads a .bit file generated by an FPGA design tool, and programs .bit into configuration RAM of a FPGA. The Mimas A7 FPGA Development Board features a high-speed USB 2.0 interface which is connected to FPGA IC’s JTAG signals. So, Mimas A7 can be programmed using its on-board USB interface using XC3SProg, without the need for a separate external JTAG programmer.

Configuration using XC3SProg

Note: Before moving on to the section of how to configure Mimas A7 using XC3SProg, make sure that  Mimas A7 FTDI drivers are properly installed. Refer Driver Installation section of Mimas A7 User Manual to install drivers.

The following steps will walk you through the process of configuring Mimas A7 board using OpenOCD.

Step 1:

Download XC3SProg for Mimas A7 from here to a suitable location in your system.

Step 2:

Open Command Prompt or PowerShell in the folder where you have downloaded the XC3SProg.

Step 3:

Use the following command in Command Prompt or PowerShell to program FPGA. You need to replace <bitstream file> with the actual location of your .bit file. XC3SProg should show output similar to the image shown below if the programming process finished successfully.

xc3sprog.exe -c mimas_a7 <bitstream_file>

Congratulations on successfully programming your bitstream to Mimas A7 using XC3SProg, without the need of any external JTAG hardware.

 

 

 

Was this helpful?

Leave A Comment
*
*