UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Visitor hugobpontes
Visitor
773 Views
Registered: ‎11-09-2019

Vivado FPGA part selection

Jump to solution

Hello,

I'm an aerospace engineering student and for my master thesis I will be implementing an attitude control algorithm onto a satellite's on board computer, more specifically onto its FPGA.

As of now my knowledge in FPGA is rather limited so I've been trying to figure out how to set up an FPGA using vivado. When starting the application it asks for my FPGA part and the one I will be using is Spartan 3E and it says XC3S50GE on the chip(I'm not a 100% sure the 'G' is actually a G, the image I have is blurry). This part is not available in Vivado or at least I can't find it. How can I work around this issue? Is it possible to add a new component to the database? Or maybe use an identical part?

Additionally I have another question although I'm not sure this is the right place to ask, however if anyone could help it would be greatly appreciated:

I am much more familiarised with implementing control algorithms on Matlab and I've been doing some research on how to implement a Matlab algorithm into an FPGA and so far I found that I can 'translate' the matlab code to vhdl or verilog that can be used in fpga or alternatively I could design a simulink model from the matlab code,  that could be implemented in FPGA as well ,though I didn't quite understand why one would go through Simulink if the first option can work. What would you recommend for my specific case and why ? 

 

Thank you very much in advance!

-Hugo

 

 

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Scholar u4223374
Scholar
755 Views
Registered: ‎04-26-2015

Re: Vivado FPGA part selection

Jump to solution

I expect that it's actually an XC3S500E. Unfortunately that's quite an old chip (approaching 15 years old now), so it is not supported in Vivado (Vivado is only for fairly recent chips and there is no way to add support for the older ones). You will need to download Xilinx ISE, which is not officially supported on Windows 10 (it's designed for Windows 7).

Last time I used HDL Coder (which was, admittedly, a few years back) it was not a very good experience. FPGAs really don't like 64-bit floating-point, so any algorithm needs to be designed pretty carefully for fixed-point. Additionally, its ability to actually turn Matlab code into HDL was very limited - it was only really useful if you could do a design using the provided Simulink blocks (since it already knows how to convert each of those into HDL).

Normally I'd suggest Vivado HLS (which does C-to-HDL) - but that's not an option for the Spartan 3. Instead, I guess my recommended option is "learn Verilog".

View solution in original post

9 Replies
Visitor hugobpontes
Visitor
767 Views
Registered: ‎11-09-2019

Re: Vivado FPGA part selection

Jump to solution

Here is the picture I have of the board I will be using:

abacus2017_3D_Top-768x630.jpg
0 Kudos
Highlighted
Scholar u4223374
Scholar
756 Views
Registered: ‎04-26-2015

Re: Vivado FPGA part selection

Jump to solution

I expect that it's actually an XC3S500E. Unfortunately that's quite an old chip (approaching 15 years old now), so it is not supported in Vivado (Vivado is only for fairly recent chips and there is no way to add support for the older ones). You will need to download Xilinx ISE, which is not officially supported on Windows 10 (it's designed for Windows 7).

Last time I used HDL Coder (which was, admittedly, a few years back) it was not a very good experience. FPGAs really don't like 64-bit floating-point, so any algorithm needs to be designed pretty carefully for fixed-point. Additionally, its ability to actually turn Matlab code into HDL was very limited - it was only really useful if you could do a design using the provided Simulink blocks (since it already knows how to convert each of those into HDL).

Normally I'd suggest Vivado HLS (which does C-to-HDL) - but that's not an option for the Spartan 3. Instead, I guess my recommended option is "learn Verilog".

View solution in original post

736 Views
Registered: ‎09-17-2018

Re: Vivado FPGA part selection

Jump to solution

If you are serious,

Order the PYNQ Z2 board from TUL.  A recent device will besupported by Vivado, and in Pynq, you can do your while system in Python (in floating point), without touching Verilog (or VHDL).

In a real system, one could recode the Python into Verilog or VHDL if the Python executes too slowly on the ARM A9's in the Zynq 7020 device on the Pynq board.

Great development board.  I use it in my classes at UCSC Extension.

l.e.o.

 

0 Kudos
Visitor hugobpontes
Visitor
703 Views
Registered: ‎11-09-2019

Re: Vivado FPGA part selection

Jump to solution

Thank you so much for your response and for your insights, I'll install ISE and work in it.

When you say "it was only really useful if you could do a design using the provided Simulink blocks" I trust that, sadly, matlab function blocks are not included? Also from what you said and considering my lack of knowledge of verilog wouldn't it be preferable to design the algorithm in simulink? Or would it have the floating point issue as well?

 

0 Kudos
Visitor hugobpontes
Visitor
702 Views
Registered: ‎11-09-2019

Re: Vivado FPGA part selection

Jump to solution
Sadly the company in which I will be interning for my thesis has already acquired the fpga I mentioned, thanks for the advice anyway!
0 Kudos
Scholar drjohnsmith
Scholar
668 Views
Registered: ‎07-09-2009

Re: Vivado FPGA part selection

Jump to solution

That old spartan 3 is small and slow by modern standards.

Matlab to RTL / Simulink is great, but for all real examples I have seen, it producs terrible RTL code.

   Very in efficient and runs very slow,  They seem to work on assumption FPGAs a re big and fast, which the spartan 3 is not,

Ive just spent a few months turing the terrible code prduced by some in Matlab into a prectical product.

One other thing I have noticed is Matlab users come up with great algorithums . wich map great int a CPU , but terrible into a FPGA . To code FGas efficiently, you need to understnad the underlining logic capabilities, and idealy be able to draw how you would imlimnet any part of your desgn in logic. If you can't the tools are going to make a mess of things, 

in 5 / 10 years time, it might be different, but not now.

 

As for language, I see the comment to Verilog above, and I have to put the argument for VHDL.

As I see it, VHDL tends ot be used for Mil and space projects due to its inherant bult in checking, ( even if Xilinx turn it off by default !! ) Id say thats you to the comany your working at, 

If you use Verilog, use the SystemVerilog version , if VHDL, the 2008 version, 

 

<== If this was helpful, please feel free to give Kudos, and close if it answers your question ==>
662 Views
Registered: ‎06-21-2017

Re: Vivado FPGA part selection

Jump to solution

I have to agree.  Both companies that I worked for that did government work used VHDL.  The commercial company did too. 

It's been a long time, but the last time I looked at Matlab produced VHDL, it was unreadable.  Spent a lot of time doing global replaces to get meaningful signal names, adding white space and comments. 

If the algorithm maps easily to Xilinx Simulink blocks, it's worth a try, otherwise either RTL will force you to think about the hardware Implementation.  That's something that a lot of beginners overlook.

Visitor hugobpontes
Visitor
604 Views
Registered: ‎11-09-2019

Re: Vivado FPGA part selection

Jump to solution

Thanks very much to all who helped! I will probably try to learn either verilog or VHDL and implement it directly. Even though its harder for me it appears that it will help me avoid a lot of trouble later on.

Thanks again!

-Hugo

0 Kudos
Scholar u4223374
Scholar
597 Views
Registered: ‎04-26-2015

Re: Vivado FPGA part selection

Jump to solution

I think that is the right approach.

 

MATLAB HDL Coder works OK if you are just chaining together Simulink blocks, although even then it tends to make a pretty huge amount of hardware - it doesn't know what optimizations are sensible, whereas a human does. An example of where I'd use it is if I wanted to get a big phased array radar system working now (well, within a week or two). There's probably a Simulink toolbox and HDL block just for that (which will cost about the same as a new car) and with that sort of costing the company will most likely be happy to also buy a massive Virtex UltraScale+ FPGA to go with it (so speed and resource usage is not a big problem). I'd imagine that this would be almost plug-and-play - and if it's not, when you've just spent a fortune on MATLAB products you could expect to get some decent tech support from them.

 

When I used HDL coder, it could convert MATLAB code to HDL - but you had to write the MATLAB code in a way that looks very much like HDL before the tool has a chance of implementing it sensibly (as opposed to just trying to do the whole thing in one cycle, which leaves you with a very low clock speed and requires more resources than any FPGA can provide). This leaves you effectively writing HDL code in a language that is really not designed for that (eg. everything defaults to double-precision floating-point) - it'd be much easier to just move to Verilog (which has similar-ish syntax).

 

For something that needs to fit on a resource-constrained device (the Spartan 3 is small by modern standards - although still a substantial amount of processing power), and needs a custom algorithm, you're much better-off using HDL directly. Especially if this is going on a satellite where heat/power are concerns and you may need to deal with radiation-induced errors, HDL gives you far more resources to achieve the goal than MATLAB does.

 

Edit: you might be able to get away with using Vivado HLS (C to HDL), actually. Try downloading Vivado 2015.4, which is (a) the last version that supported the old ISE-only chips, and (b) the first version that didn't require a paid license to use HLS. HLS will still demand more resources (and power) than a well-done HDL design, and I don't trust it as much (I wouldn't use it for anything mission-critical) but it'll most likely be faster to get started on than VHDL.