RTL Design · Easy · SystemVerilog

I²C Address Matcher

Decode the first I²C byte into a 7-bit address and R/W bit.

Task

Compare byte_in[7:1] with SLAVE_ADDR. Assert address_match on equality and expose read_not_write from bit 0.

Examples

Constraints

What this problem is testing

A strong answer translates the requirement into synthesizable state and combinational logic, states reset and update semantics precisely, and handles boundary conditions rather than only the nominal case.

Interview habit: before coding, state reset behavior, the state that must be stored, and the conditions that update each output.

Verification plan

Common mistakes

Interview follow-up questions

Concepts to review

I2C, address, slave

Open I²C Address Matcher in the HDLForge interactive editor.

Related problems

Explore the RTL Design Practice & Interview Preparation hub.

Continue practising