Re: how to make list of unequal-sized signals

Christopher Felton <[email protected]> Thu, 25 Feb 2016 07:24:13 -0600
Newsgroups gmane.comp.python.myhdl
Message-ID <[email protected]>
> this does not seem to be convertible, as the signals in the array
> have different lengths
>
> multout = [Signal(intbv(0, min=de.min*coeff, max=de.max*coeff)) for
> coeff in coeffs]

You can't do this, in hardware if they are all different
types they would need to be mapped to some non-homogeneous
structure (i.e. not memory).

What I would do if first find the min and max in your
coefficients and create the coefficient array
(list-of-signals) from the overall collection's min and
max.  Then you have a structure that can be mapped to
to a memory if needed.

If that is not desired, you don't have much choice but
to individually select the different size `coeff`.  Note,
if you use the ROM [1] structure (tuple-of-ints) it will
use the minimal hardware you desire.

Regards,
Chris


[1] 
http://docs.myhdl.org/en/stable/manual/conversion_examples.html#rom-inference


------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140