From 55d2673359c6a9f007012a8da96f70200895e2d4 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Mon, 9 Mar 2020 20:31:27 +0000 Subject: [PATCH] allow name on latchregister --- src/nmutil/latch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/nmutil/latch.py b/src/nmutil/latch.py index 84235ff..2086fe5 100644 --- a/src/nmutil/latch.py +++ b/src/nmutil/latch.py @@ -21,8 +21,8 @@ always @ (posedge c) endmodule """ -def latchregister(m, incoming, outgoing, settrue): - reg = Signal.like(incoming) # make register same as input. reset is OK. +def latchregister(m, incoming, outgoing, settrue, name=None): + reg = Signal.like(incoming, name=name) # make reg same as input. reset OK. with m.If(settrue): m.d.sync += reg.eq(incoming) # latch input into register m.d.comb += outgoing.eq(incoming) # return input (combinatorial) -- 2.30.2