EmbDev.net

Forum: FPGA, VHDL & Verilog Passing a generic value from a tcl script to a generic package file in VHDL


von Abdallah (Guest)


Rate this post
useful
not useful
Hello Guys



Simple question, yet I cannot find an answer anywhere for it. I even 
read book chapters on the subject, and still cannot figure it out.

So here it is, I can pass a generic value from a tcl script to the top 
layer in an a certain hierarchy using the "-g" flag when simulating, and 
then I pass down this generic to the sub-modules within it.

However, my problem is this. I am trying to make a generic package file, 
and I want pass the generics from a tcl script into the package file,

Then after this is done, I will instantiate the generic package file in 
each module and they can all read what was passed to the package 
instead.

So I want this: Genrics in tcl => pass to Generic_PKG => instantiate 
package in submodules => parametrize all modules.

This is my current case: Genrics in tcl => pass to Generic_Top_module => 
pass down to sub-modules => parametrize all modules.



Thanks in advance!

von vancouver (Guest)


Rate this post
useful
not useful
You could let your tcl script generate the pkg itself, i.e. a code 
generator. If your pkg just contains parameters, this should be quite 
easy to implement.

Please log in before posting. Registration is free and takes only a minute.
Existing account
Do you have a Google/GoogleMail account? No registration required!
Log in with Google account
No account? Register here.