Skip to content

Sample resolved I2C inputs while the VIP drives the bus - #310

Open
lionelZhaowy wants to merge 5 commits into
pulp-platform:mainfrom
lionelZhaowy:fix/vip-i2c-resolved-inputs
Open

lionelZhaowy wants to merge 5 commits into
pulp-platform:mainfrom
lionelZhaowy:fix/vip-i2c-resolved-inputs

Conversation

@lionelZhaowy

@lionelZhaowy lionelZhaowy commented Nov 7, 2026 •

Copy link
Copy Markdown

The I2C input buffers in vip_cheshire_soc_tristate are enabled only when the DUT releases the line. When the DUT drives SDA or SCL low, its input becomes high impedance instead of reflecting the resolved bus value.

This patch connects both I2C inputs directly to the resolved wires. Output buffers, pullups and SPI buffers stay unchanged.

The same 78-check test reports 16 input mismatches before the fix and zero after. It tests the simulation wrapper, with no synthesizable RTL changes.

Validation, reproduction and scope

Validation used official main 6c6dd5e834347f72c7be31cd6c41021ec293c5b9. The same finite 78-check test ran against both versions with VCS W-2024.09-SP1. It instantiated the complete real tristate module, extracted without edits. A package shim supplied only the SPI chip-select port width.

  • Sweep all 16 combinations of DUT/peer low or release controls for SDA and SCL.
  • Check both resolved wires and returned inputs, release transitions, and unchanged SPI input gating.
  • Original: exactly 16 input mismatches, all z instead of 0, followed by the expected failure.
  • Patch: 78 checks, zero errors, and a normal finish at 250 ns.
  • Limits: 1 us HDL deadline and 60 seconds wall-clock per run.

Run make sim-test-i2c-inputs with VCS on PATH. The target checks the summary, errors, and normal finish.

The full checkout passes the license and C/C++ format checks, and hw-all, sw-all, and sim-all build with the CI GCC 12.2.0 toolchain. The license job uses Ubuntu 24.04 so that its existing Python 3.9 action can start.

Full SoC EEPROM boot still reports an SCL timing violation: a 385 ns low pulse against the model minimum of 500 ns. The unmodified official base reports the same violation with the same image. Full EEPROM boot is not a passing result.

The public test and commands are in target/sim/test/. No EEPROM model is needed. This verifies the simulation wrapper only. It does not claim full controller, EEPROM, or SoC verification. No synthesizable RTL changes.

OpenAI Codex assisted with the patch, test, and validation. A separate AI review checked the source and logs.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant