rj11 coupler/extend cable

Support, advice and resources for the Raspberry Pi Oracle Weather Station for schools

3 posts
by CudaEngineer » Thu Feb 23, 2017 5:47 pm
Would I be able to add a coupler to the cables for the sensors? I would like to keep the pi inside so I don't have to worry about the weather. If I put it near a window I can mount the air sensor outside and the wind/rain sensors on the roof. We would need to extend it maybe 20ft. Was concerned about signal loss over that distance. Thanks.
Posts: 2
Joined: Thu May 26, 2016 6:40 pm
by willip5 » Mon Mar 06, 2017 7:13 pm
The wind and rain sensors will work at 10 meters or more without any problems but the i2c bus is a bit more fussy. I can get 3 meters by using CAT5 twisted pair cable, I haven't tried any longer but I have seen discussions where 100m is achievable. Try Googling i2c maximum cable lenghth for more details or just give it a go. You may need to change the i2c pull up resistors to get greater length.
Posts: 58
Joined: Wed May 29, 2013 11:55 am
Location: France
by jmbelisle » Sun Jun 18, 2017 9:25 pm
Regarding long cable lengths for I2C, there is an excellent post on this board
https://www.raspberrypi.org/forums/view ... hp?t=82049

in a nutshell:
- use cat5e (or 6) cable
- use a twisted pair for SDA and SCL with the signal on one cable of the pair and GND on the other (eg: Blue/White-blue pair with Blue on SDA and White-blue on GND).
- connect the White-blue (in this example) to GND at both ends of the cable (on the Pi side AND on the sensor side)
- do the same for SCL (say using the Orange/White-orange pair)
- Vcc and GND use the solid colors of the other 2 pairs (no need to use both wires of twisted pair for Vcc and GND)
- if you have issues (sensor not detected or ioerrors), try using a lower (100K) I2C bus speed
- if you still have issues try adding a pulldown resistor (values given in post) on the sensor side
- if you still have issues use a I2C cable extender board using chip type P82B715

My own successful test involved:
- Raspberry Pi 2 with jessie up to date
- 8 meters (25 feet) of cat5e cable
- TSL2561 I2C sensor board from Adafruit
I did NOT need to use a lower speed nor additional pulldown resistors and of course did not use extender boards
It worked very nicely.

jmb
Posts: 1
Joined: Sun Jun 18, 2017 8:51 pm