Matlab HDL Coder Query

Just about everything about Red Pitaya
Post Reply
igttgit
Posts: 15
Joined: Fri Jul 31, 2015 9:22 pm

Matlab HDL Coder Query

Post by igttgit » Wed Oct 14, 2015 11:53 pm

Dear Forum,
Has anyone tried using the Red Pitaya device with the Matlab HDL coder ?

I understand that it would be unreasonable to ask for a tutorial such as the one for the
Zynq 702 Evaluation kit however this is a request to anyone who has attempted this and
knows how to get started

I am a complete amateur at FPGA and would appreciate any help getting started with programming fast
complex FPGA systems

Thank you in advance

Link to zynq 702 evaluation kit
http://uk.mathworks.com/help/hdlcoder/e ... tform.html

pavel
Posts: 799
Joined: Sat May 23, 2015 5:22 pm

Re: Matlab HDL Coder Query

Post by pavel » Thu Oct 15, 2015 12:23 am

I understand that it would be unreasonable to ask for a tutorial such as the one for the
Zynq 702 Evaluation kit however this is a request to anyone who has attempted this and
knows how to get started
I have IP cores for the Red Pitaya ADC and DAC with the AXI4-Stream interface. They can be used together with the IP cores generated by Matlab HDL coder.

The source code of my IP cores can be found at the following location:
https://github.com/pavel-demin/red-pita ... ster/cores

The commands to generate the IP cores repository with the ADC and DAC IP cores are:

Code: Select all

source /opt/Xilinx/Vivado/2015.3/settings64.sh
source /opt/Xilinx/SDK/2015.3/settings64.sh

git clone https://github.com/pavel-demin/red-pitaya-notes
cd red-pitaya-notes

make tmp/cores/axis_red_pitaya_adc_v1_0
make tmp/cores/axis_red_pitaya_dac_v1_0
Then you can add tmp/cores repository to IP Integrator.

Alternatively, you can generate an empty project, open it in Vivado and add the IP cores generated by Matlab HDL coder to this project. Here are the commands to generate an empty project with Red Pitaya configuration and with all my IP cores:

Code: Select all

source /opt/Xilinx/Vivado/2015.3/settings64.sh
source /opt/Xilinx/SDK/2015.3/settings64.sh

git clone https://github.com/pavel-demin/red-pitaya-notes
cd red-pitaya-notes

make tmp/led_blinker.xpr

vivado tmp/led_blinker.xpr
Also have a look at my notes at this link

pavel
Posts: 799
Joined: Sat May 23, 2015 5:22 pm

Re: Matlab HDL Coder Query

Post by pavel » Thu Oct 15, 2015 8:15 am

You can also use the following tutorial:
http://uk.mathworks.com/help/hdlcoder/e ... kflow.html

It should work for the Red Pitaya board. Just replace the ZYBO Zynq definition file (ZYBO_zynq_def.xml) with the Red Pitaya definition file (red_pitaya.xml):
https://raw.githubusercontent.com/pavel ... pitaya.xml

igttgit
Posts: 15
Joined: Fri Jul 31, 2015 9:22 pm

Re: Matlab HDL Coder Query

Post by igttgit » Tue Oct 27, 2015 2:46 pm

An update, I am able to add HDL coder generated files into Vivado, and I have run through the tutorial files.

When I try to import the red-pitaya.xml file to add a custom board, I get the following error

Java exception occured, the system cannot find project.dtd

After looking on the internet it seems that this is a java library required to parse dtd files, is this possible on windows ?

pavel
Posts: 799
Joined: Sat May 23, 2015 5:22 pm

Re: Matlab HDL Coder Query

Post by pavel » Tue Oct 27, 2015 3:16 pm

Does it work with the ZYBO definition file (ZYBO_zynq_def.xml) from the tutorial?

I'm using Vivado 2015.3 with Debian 8 and Vivado reads red_pitaya.xml without any problem. It should also work under Windows. If it does not, then it's probably a bug in Vivado.

igttgit
Posts: 15
Joined: Fri Jul 31, 2015 9:22 pm

Re: Matlab HDL Coder Query

Post by igttgit » Tue Oct 27, 2015 5:07 pm

Yes, I still get the error when I use the Zybo Definition file.

I am attempting to use the MATLAB board manager wizard (launch with fpgaBoardManager command)
to add the board.I have installed MATLAB onto Linux, same problem, current configuration

Vivado 2015.2 MATLAB 2015b on Ubuntu 14.04 (through virtualbox)

pavel
Posts: 799
Joined: Sat May 23, 2015 5:22 pm

Re: Matlab HDL Coder Query

Post by pavel » Tue Oct 27, 2015 5:20 pm

I'm not sure if I understand at what step of the tutorial you get this error.

Anyway, there is always a possibility to generated IP cores using the "Generic Xilinx Platform" as target platform in HDL Workflow Advisor.

Then you can create an empty project in Vivado and add the IP cores from HDL Coder to the IP core repository in your Vivado project.

Or you can use the commands from my first comment to generate led_blinker.xpr, open it in Vivado and add the IP cores from HDL coder.

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 39 guests