From d8b7857d68be1d7d15cf5260146f5a9bcf254dae Mon Sep 17 00:00:00 2001 From: Zane Kaminski Date: Sat, 21 Sep 2024 21:53:48 -0400 Subject: [PATCH] Add reset synchronization to CNT module --- cpld/CNT.v | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cpld/CNT.v b/cpld/CNT.v index fcf8233..70f9bbb 100644 --- a/cpld/CNT.v +++ b/cpld/CNT.v @@ -16,8 +16,9 @@ module CNT( reg [1:0] Er; always @(posedge CLK) Er[1:0] <= { Er[0], E }; wire EFall = Er[1] && !Er[0]; - /* NMI button synchronization */ + /* NMI and reset synchronization */ reg nIPL2r; always @(posedge CLK) nIPL2r <= nIPL2; + reg nRESr; always @(posedge CLK) nRESr <= nRESin; /* Startup sequence state */ reg [1:0] IS = 0;