Forum Discussion
Hello,
Quartus infers open-drain outputs from the behavioural tri-state description in your code. With default "Auto Open-Drain Pins" synthesis settings, it generates dedicated open drain buffers, otherswise open-drain function is generated through IO-buffer output enable function. See below techology map snippets for comparison. According to device manuals, dedicated open-drain buffer (right side) involves speed advantage, for slow intefaces like I2C the difference is effectively irrelevant.
Thus you don't need to make specfic pin assignments.
There's however a different problem involved with your code. The intended pass-through logic doesn't work, it generates dead-lock situation between both pins, because you can't determine if a pin is driven low by the peer.
Bidirectional I2C buffers with signal replication are using special analog hardware (modified Tx and Rx levels) or other methods of signal direction recognition to distinguish internal and external driven low state.
Regards
Frank