Skip to content

Commit

Permalink
Remove two consecutive ReadOnly() waits
Browse files Browse the repository at this point in the history
Internal-tag: [#71812]
Signed-off-by: Maciej Kurc <mkurc@antmicro.com>
  • Loading branch information
mkurc-ant authored and kgugala committed Jan 21, 2025
1 parent eb60379 commit d1b8204
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion verification/cocotb/block/bus_tx/test_bus_tx.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,12 @@ async def assert_drive_start(dut, sda_value):

# Ensure data is correct until tx is finished
while True:
await ReadOnly()
if dut.tx_done_o.value:
break
assert dut.sda_o.value == sda_value
assert dut.tx_idle_o.value == 0
await RisingEdge(dut.clk_i)
await ReadOnly()

await RisingEdge(dut.clk_i)
dut.drive_i.value = 0
Expand Down
2 changes: 1 addition & 1 deletion verification/cocotb/block/bus_tx_flow/test_bus_tx_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,12 @@ async def assert_bit_request(dut, sda_value):

# Ensure data is correct until tx is finished
while True:
await ReadOnly()
if dut.bus_tx_done_o.value:
break
assert dut.sda_o.value == sda_value
assert dut.bus_tx_idle_o.value == 0
await RisingEdge(dut.clk_i)
await ReadOnly()

await RisingEdge(dut.clk_i)
dut.req_bit_i.value = 0
Expand Down

0 comments on commit d1b8204

Please sign in to comment.