forked from M-Labs/artiq
dsp/Delay: reset_less
This commit is contained in:
parent
424a1f8f4e
commit
98193d6fa1
|
@ -7,13 +7,13 @@ from migen import *
|
|||
class Delay(Module):
|
||||
def __init__(self, i, delay, o=None):
|
||||
if isinstance(i, (int, tuple)):
|
||||
z = [Signal(i) for j in range(delay + 1)]
|
||||
z = [Signal(i, reset_less=True) for j in range(delay + 1)]
|
||||
elif isinstance(i, list):
|
||||
z = [Record(i) for j in range(delay + 1)]
|
||||
elif isinstance(i, Record):
|
||||
z = [Record(i.layout) for j in range(delay + 1)]
|
||||
else:
|
||||
z = [Signal.like(i) for j in range(delay + 1)]
|
||||
z = [Signal.like(i, reset_less=True) for j in range(delay + 1)]
|
||||
self.i = z[0]
|
||||
self.o = z[-1]
|
||||
if not isinstance(i, (int, list, tuple)):
|
||||
|
|
Loading…
Reference in New Issue