I've done some experiments with i2c over 2 metres of cat5 cable.
Again, the circuit worked fine when connected with short cables, but
when connected with the longer cable things didn't work so well.
In the accompanying image [1] (note the traces are in different time
scales - apparently the DSO can "store" signals, but I can't work out
how to access them), the light blue horizontal bars are roughly where
the i2c spec says the signal has to reach. With the shorter cable, the
signal moves into the limits of the spec, but with the longer one, the
signal transitions too slowly to change state.
It's not all bad news though. It looks like the signal only missed the
thresholds because of the low slew rate. One problem is that i2c never
drives the line high - it just leaves the line float back to the high
state, the results of which are easily seen on the attached image. If
we chose a serial protocol instead - one which actually drives the
line high AND low - we may not have this problem.
I'm not sure whether to choose SPI or asynchronous serial, the latter
has the advantage that we don't need a clock line and might get away
with one data line. If we use the internal 8MHz oscillator on the AVR,
we can run asynchronous serial at about 500kbit/s (you can actually go
faster, but you risk synchronization problems on the receiver). SPI
should be able to go faster, of course slew rates may limit our speed.
And if we have voltage problems, we might be able to use a RS232 or
RS485 transceiver on the sender, and hopefully get away with a few
resistors on the receiver.
I guess my next experiment is to repeat with asynchronous serial and
see if that works better over the longer cable, and if that doesn't
work, then try a serial tranciever.
1:
http://www.hackerspace-adelaide.org.au/wiki/File:Peel_St_Lantern_i2c_test_results.jpg