Remove await ReadOnly

This commit is contained in:
Alex Forencich
2020-12-24 00:28:16 -08:00
parent 0456e4af60
commit d97208d3c8
6 changed files with 24 additions and 49 deletions

View File

@@ -27,7 +27,7 @@ import math
from fractions import Fraction
import cocotb
from cocotb.triggers import RisingEdge, ReadOnly
from cocotb.triggers import RisingEdge
from .version import __version__
@@ -178,10 +178,9 @@ class PtpClock(object):
async def _run(self):
while True:
await ReadOnly()
await RisingEdge(self.clock)
if self.reset is not None and self.reset.value:
await RisingEdge(self.clock)
self.ts_96_s = 0
self.ts_96_ns = 0
self.ts_96_fns = 0
@@ -198,8 +197,6 @@ class PtpClock(object):
self.pps <= 0
continue
await RisingEdge(self.clock)
if self.ts_step is not None:
self.ts_step <= self.ts_updated
self.ts_updated = False