I'm working on bit-banged I²C for the ATmega328PB. I've been seeing a lot of noise (ringing and cross-talk) on the lines but thought it was just my test probes, etc. However, when using the MCU's native I²C the noise disappears. Can anyone suggest why this is occurring and how I might fix it?
FWIW, my bit-banged I²C code is working fine but the noise is a bit worrisome. From the 'scope traces (taken ~300 µs apart) it looks like the native I²C is driving the lines harder but I don't see anything in the MCU registers to tweak that.
Edit: Per @Big6's suggestion I added a 220 Ω resistor between the MCU pin and the 4.7k Ω pull-up resistor on the clock line (doing the data line as well would involve more substantial rework). The signal's a lot cleaner now (see below; clock is cyan). I may switch the resistors to 2.2k or 3.3k Ω for the pull-ups and 470 Ω for the series ones which I suspect would further improve things.