JTAG_master class: fix bug that wrongly changed state to Scan when TMS is 0
authorStaf Verhaegen <staf@stafverhaegen.be>
Sat, 14 Apr 2018 09:18:56 +0000 (11:18 +0200)
committerStaf Verhaegen <staf@stafverhaegen.be>
Sat, 14 Apr 2018 09:18:56 +0000 (11:18 +0200)
sim/cocotb/c4m_jtag.py

index 48d2677cc5920daa1423d4c6cf82d7efaa8f537f..529e66bc589a99e8c70b6343cdafc22463a2dcbf 100644 (file)
@@ -62,7 +62,7 @@ class JTAG_Master(object):
 
     @cocotb.coroutine
     def cycle_clock(self, cycles=1):
-        if self.state == "Run" and self.tms:
+        if self.state == "Run" and self.tms == 1:
             self.state = "Scan"
         yield self.clkgen.Cycle(cycles)