danmc
Community Member
Offline
Posts: 35
Boston
|
Hello,
I"m trying to use generate() to produce a bunch of filters. I have an initial block where I use generate to initilialze the gain and banwdith of my filters and then try to do:
generate i (1 , 10) begin // Transfer function for a first order low pass filter
V(OUT[i]) <+ laplace_nd(in[i], {gain[i]}, {1,tau[i]}); end /
but I get back: Error found by spectre during SpectreHDL compile. "/path/to/mycell/veriloga/veriloga.va", line 126: "{1,tau[i]})<<--? ;" "/path/to/mycell/veriloga/veriloga.va", line 126: Error: arg #2 must be an array variable or a constant array expression. It cannot be an array expression containing non-constant expressions. If you need the argument to be variable, use an array variable instead. "/path/to/mycell/veriloga/veriloga.va", line 126: Error: arg #3 must be an array variable or a constant array expression. It cannot be an array expression containing non-constant expressions. If you need the argument to be variable, use an array variable instead.
I want to be able to pass parameters into this model that determine the gain and bandwidth of each filter. However, the gain and bandwidth are functions computed from a different set of user parameters.
Any suggestions?
Thanks -Dan
|