cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Observer
Observer
7,552 Views
Registered: ‎11-27-2007

From Matlab coding to VHDL

Can we convert matlab code to VHDL? Or we have to do it in Simulink Block?
0 Kudos
2 Replies
Highlighted
Explorer
Explorer
7,526 Views
Registered: ‎08-14-2007

You can use AccelDSP to do this (for some Matlab code)

Cheers,
Martin
Martin Thompson
martin.j.thompson@trw.com
http://www.conekt.co.uk/capabilities/electronic-hardware
0 Kudos
Highlighted
Adventurer
Adventurer
7,493 Views
Registered: ‎08-20-2007

You can do this with Matlab Block in system Generator as well. But there are some restrictions for math operations - multiplying only by power of 2 and no division and for loops.
In my opinion SG generates good code for matlab only  if you need to have a lot of switch-case statements. If you have a lot of calculations then you have to control precision in matlab with special functions. Otherwise matlab maintains full precision and generates huge adders and substractors (like Fix50_20). In this case it is easier to control with standard SG blocks.

0 Kudos