i have to calculates lots of constants, dependant only of 1 generic value. I can do that in C or in Octave (Matlab-like language). I don know how to load those constants, i've been doing it "by hand" in the VHDL header, first calculating them, and them putting them into matrixes in an array type. Can i implement the c-code (or matlab code) into the vhdl code like some kind of function? Have in mind that i'm not asking for sinthetizing this secuential code for calculation, i'm just looking for the ability to know the number of components and length of signals by every "layer" in my design. Thanks a lot
Hi Fito, you might need to store your constants in a textfile and overwrite your constants(generics) with this values. Look for the textIO package. Regards
Hi Fito check out my solution: http://www.nkavvadias.com/hercules/ and for free testing: http://www.nkavvadias.com/cgi-bin/herc.cgi These links provide access to the HercuLeS high-level synthesis tool. So you can try automatically synthesizing your C code to VHDL with Herc. Best regards Nikolaos Kavvadias Research Scientist
Fito wrote: > i have to calculates lots of constants, dependant only of 1 generic > value. I can do that in C or in Octave (Matlab-like language). Write a function in C/Octave, which generates a valid VHDL file, containing your constants. Add this file to your project. Tom
Maybe myHDL (http://www.myhdl.org/doku.php) could solve your problem, but it might be quite a change. For simulation, some people have done interesting stuff with the GHDL simulator by interfacing it with C routines (http://www.fpgarelated.com/showarticle/20.php). But not sure if that helps, as you're speaking of constants. I'm just using those extensions to pull configuration values out of .INI files.
once, there used to be a prog named "c to vhdl" I got from the internet i never tried