Codiode

I2C Arbitration Loss Detector

HardLogic CircuitBuild

Multi-master open-drain buses require collision detection to prevent data corruption when multiple devices begin transmitting simultaneously. The arbitration detector monitors the physical bus state against the device's intended transmission state to determine if another master has claimed the bus.

The detector operates synchronously. When the master is actively transmitting (tx_en is 1), it compares its intended output (sda_out) with the actual bus state (sda_in). If the master intends to float the line high (sda_out is 1) but reads a pulled-low bus (sda_in is 0), arbitration is lost. The arb_lost flag must assert on the next clock edge and remain high until cleared by a synchronous rst.

rst tx_en sda_out sda_in arb_lost (next)
1 X X X 0
0 0 X X arb_lost
0 1 0 X arb_lost
0 1 1 1 arb_lost
0 1 1 0 1

Constraints

  • Implement synchronous reset logic.
  • Ensure arb_lost holds its state once asserted high until rst is applied.
  • Do not evaluate arbitration conditions when tx_en is 0.

Topics

sequentialstate-machinei2carbitration

Solve this problem

Place the gates, wire them up and watch the signals settle. Every submission runs on the same simulation engine that grades it.

This problem is part of Codiode Pro. The statement above is free to read.

The circuit builder and code editor need a desktop screen. On a phone, read the problem here and open it on a laptop to solve.

Part of Interface and Communication Circuits

Problem 79 of 79 in the Interface and Communication Circuits track.

Related problems

Browse all problems · Digital logic design practice problems · Learning tracks

Solve this on a laptopSend yourself the link and continue there.