Re: [myhdl-list] simulation coding vs conversion coding
Brought to you by:
jandecaluwe
From: Christopher F. <chr...@gm...> - 2014-03-11 11:14:05
|
On 3/11/14 1:59 AM, Marcel Hellwig wrote: > Hi Lars, >> one=[Signal(intbv(0)[2:]) for k in range(2)] > do this instead: > >> one, two = [Signal(intbv(0)[2:]) for k in range(2)] > > it should avoid your problem. > I believe Lars is trying to use a list of signals, the above won't work. You can use list of signals to model memory or other logical structures. http://www.myhdl.org/doc/current/manual/conversion_examples.html?highlight=list%20signals#ram-inference What was posted is the correct approach to bit slice into the individual intbv in the list. one[n].next[b] = in | | | +- intbv bit index +--------- list index Regards, Chris |