I2C cable

W

Winfield Hill

Guest
We need a 1-meter length of 100kHz (or slower)
I2C onnection. It'd be nice to use a pre-made
cable: micro-USB, 4-wire RJ11, or RJ45 ethernet.
Some considerations: SCL and SDA crosstalk(?),
high ground capacitance. Also need 3.3V, Gnd.

Micro-USB: SCL and SDA twisted together, bad?
RJ11: flat, SCL and SDA on outside lines?
RJ45: SCL and SDA shielded from each other.


--
Thanks,
- Win
 
Martin Rid <martin_riddle@verison.net> Wrote in message:
> Winfield Hill <hill@rowland.harvard.edu> Wrote in message:> We need a 1-meter length of 100kHz (or slower) I2C onnection. It'd be nice to use a pre-madecable: micro-USB, 4-wire RJ11, or RJ45 ethernet.Some considerations: SCL and SDA crosstalk(?),high ground capacitance. Also need 3.3V, Gnd.Micro-USB: SCL and SDA twisted together, bad? RJ11: flat, SCL and SDA on outside lines?RJ45: SCL and SDA shielded from each other.-- Thanks, - Win- 400pf. Max @100khz . Cat5 should work. There are bus extenders too.Cheers----Android NewsGroup Reader----http://usenet.sinaapp.com/

https://www.i2c-bus.org/specification/
--


----Android NewsGroup Reader----
http://usenet.sinaapp.com/
 
Winfield Hill <hill@rowland.harvard.edu> Wrote in message:
We need a 1-meter length of 100kHz (or slower) I2C onnection. It'd be nice to use a pre-madecable: micro-USB, 4-wire RJ11, or RJ45 ethernet.Some considerations: SCL and SDA crosstalk(?),high ground capacitance. Also need 3.3V, Gnd.Micro-USB: SCL and SDA twisted together, bad? RJ11: flat, SCL and SDA on outside lines?RJ45: SCL and SDA shielded from each other.-- Thanks, - Win

-
400pf. Max @100khz . Cat5 should work. There are bus extenders too.

Cheers


----Android NewsGroup Reader----
http://usenet.sinaapp.com/
 
Just for lab use? Or is this part of the flex or beehive question from
earlier?

I'd be loathe to suggest anything not shielded at least in some rudimentary
way. There are lots of styles of flat or round multiconductor cable that
would do, and then a regular header will do on the end, or modular
connectors if you like those.

Incidentally, any idea if PVC (outgassing, plasticizers, chewing?)
compatible with bees? How about electric fields?

Tim

--
Seven Transistor Labs, LLC
Electrical Engineering Consultation and Design
Website: https://www.seventransistorlabs.com/

"Winfield Hill" <hill@rowland.harvard.edu> wrote in message
news:qb40m902842@drn.newsguy.com...
We need a 1-meter length of 100kHz (or slower)
I2C onnection. It'd be nice to use a pre-made
cable: micro-USB, 4-wire RJ11, or RJ45 ethernet.
Some considerations: SCL and SDA crosstalk(?),
high ground capacitance. Also need 3.3V, Gnd.

Micro-USB: SCL and SDA twisted together, bad?
RJ11: flat, SCL and SDA on outside lines?
RJ45: SCL and SDA shielded from each other.


--
Thanks,
- Win
 
Tim Williams wrote...
Just for lab use? Or is this part of the flex
or beehive question from earlier?

This goes from the little PCB located on the
outside of the beehive, mating to the flex.

I'd be loathe to suggest anything not shielded
at least in some rudimentary way. There are
lots of styles of flat or round multiconductor
cable that would do, and then a regular header
will do on the end, or modular connectors if
you like those.

Well, a nice thing about a CAT5 connector is,
readily available in many lengths. I'm adding
a Harting RJ45 jack to the PCB now.

Incidentally, any idea if PVC (outgassing,
plasticizers, chewing?) compatible with bees?
How about electric fields?

Bees are robust, maybe, but hive operators stick
to natural materials = wood. Near the end of the
season, the environment in the hive can get pretty
nasty. That's why I'm adding gas sensors.
But dunno what we'll find. Maybe nothing.

https://www.dropbox.com/sh/w1xbcwovma602he/AADzRhQgieifJ9z1FoSscDrHa?dl=0


--
Thanks,
- Win
 
On Friday, 10 May 2019 17:03:04 UTC+1, Winfield Hill wrote:

Well, a nice thing about a CAT5 connector is,
readily available in many lengths. I'm adding
a Harting RJ45 jack to the PCB now.

RJ11 connectors work nicely for i2c in conjunction with the following
four-core flat cable: Farnell 130-2745
which has a pvc outer sheath and polypropylene insulated conductors.
I have used this combination in production with cable lengths of 7m.

For such lengths it is important to follow the more recent NXP
recommendations:
Power and ground in the middle, sda and sclk on the outside. In most
systems the largest source of interference is from the adjacent signal
transitions.
Power and ground decoupled to each other at each end of the cable.

Many devices can be daisy chained, but keep them in a continuous
line without branches to form a constant impedance transmission line.
Consider some gentle RC damping at the controller end to minimise
reflections. Treating the bus as a transmission line really does
have benefits.
More info later...
John
 
Winfield Hill <hill@rowland.harvard.edu> wrote:

OK, John, yes, crosstalk is the big concern. And, hey,
CAT5 is UTP, unshielded twisted-pair, not shielded.

SHIELDED CABLE (STP) vs UNSHIELDED CABLE (UTP)

Cat 5E cables are most commonly utilized with unshielded twisted pairs (UTP).
However, environments with large motors, generators, and certain types of
high-voltage lighting are major sources of Electromagnetic and Radio
Frequency Interference (EMI/RFI). In these applications, shielded twisted
pair (STP) cable will help protect data signals when connected properly

https://www.warehousecables.com/landing/cat5-shielded-cable.php

Many other examples on google
 
jrwalliker@gmail.com wrote...
On Friday, 10 May 2019, Winfield Hill wrote:

Well, a nice thing about a CAT5 connector is,
readily available in many lengths. I'm adding
a Harting RJ45 jack to the PCB now.

RJ11 connectors work nicely for i2c in conjunction with the following
four-core flat cable: Farnell 130-2745
which has a pvc outer sheath and polypropylene insulated conductors.
I have used this combination in production with cable lengths of 7m.

For such lengths it is important to follow the more recent NXP
recommendations:
Power and ground in the middle, sda and sclk on the outside. In most
systems the largest source of interference is from the adjacent signal
transitions.
Power and ground decoupled to each other at each end of the cable.

Many devices can be daisy chained, but keep them in a continuous
line without branches to form a constant impedance transmission line.
Consider some gentle RC damping at the controller end to minimise
reflections. Treating the bus as a transmission line really does
have benefits.
More info later...
John

OK, John, yes, crosstalk is the big concern. And, hey,
CAT5 is UTP, unshielded twisted-pair, not shielded.


--
Thanks,
- Win
 
On 10 May 2019 10:50:57 -0700, Winfield Hill
<hill@rowland.harvard.edu> wrote:

jrwalliker@gmail.com wrote...

On Friday, 10 May 2019, Winfield Hill wrote:

Well, a nice thing about a CAT5 connector is,
readily available in many lengths. I'm adding
a Harting RJ45 jack to the PCB now.

RJ11 connectors work nicely for i2c in conjunction with the following
four-core flat cable: Farnell 130-2745
which has a pvc outer sheath and polypropylene insulated conductors.
I have used this combination in production with cable lengths of 7m.

For such lengths it is important to follow the more recent NXP
recommendations:
Power and ground in the middle, sda and sclk on the outside. In most
systems the largest source of interference is from the adjacent signal
transitions.
Power and ground decoupled to each other at each end of the cable.

Many devices can be daisy chained, but keep them in a continuous
line without branches to form a constant impedance transmission line.
Consider some gentle RC damping at the controller end to minimise
reflections. Treating the bus as a transmission line really does
have benefits.
More info later...
John

OK, John, yes, crosstalk is the big concern. And, hey,
CAT5 is UTP, unshielded twisted-pair, not shielded.

Why do you need shielding ?

Put clock in one twisted pair, data in an other pair and Vdd/Gnd in
the third pair.

If only two pairs available, use the non-active members of each pair
for Vdd resp. Gnd. Use heavy AC decoupling between these non-active
pair members.

After all, 100 kHz is a quite low frequency.
 
On Friday, 10 May 2019 21:21:07 UTC+1, upsid...@downunder.com wrote:

> After all, 100 kHz is a quite low frequency.

But the falling edges can be fast enough for transmission line
effects to be important when the cable is a few metres long.
Double clocking due to reflections makes a mess of i2c.

Using the lowest possible pullup resistors or using active pullup
that approximates to a constant current clamped at Vcc can help with
noise immunity in the high state.

John
 
On Friday, May 10, 2019 at 6:22:09 PM UTC-4, Tim Williams wrote:
upsidedown@downunder.com> wrote in message
news:bsmbded0mhgetsajtjm98k93vn8n6suj3a@4ax.com...
OK, John, yes, crosstalk is the big concern. And, hey,
CAT5 is UTP, unshielded twisted-pair, not shielded.

Why do you need shielding ?

Put clock in one twisted pair, data in an other pair and Vdd/Gnd in
the third pair.

The signals themselves might not need shielding, but that ignores ambient
noise. We're considering a clock signal here, so we need to be wary of fast
changes from external sources.

I2C is supposed to discard rapid changes -- interfaces are supposed to
sample (at fairly high rate) and filter (to avoid noise), but, who knows.
Not everyone follows the standard properly, y'know?

I thought I had read the standard once some time ago and don't recall that it is intended to be sampled like a UART. Is that literally in the spec or does it say some amount of noise is to be rejected and not seen as a start condition or clock edge?

--

Rick C.

- Get a 1,000 miles of free Supercharging
- Tesla referral code - https://ts.la/richard11209
 
<upsidedown@downunder.com> wrote in message
news:bsmbded0mhgetsajtjm98k93vn8n6suj3a@4ax.com...
OK, John, yes, crosstalk is the big concern. And, hey,
CAT5 is UTP, unshielded twisted-pair, not shielded.

Why do you need shielding ?

Put clock in one twisted pair, data in an other pair and Vdd/Gnd in
the third pair.

The signals themselves might not need shielding, but that ignores ambient
noise. We're considering a clock signal here, so we need to be wary of fast
changes from external sources.

I2C is supposed to discard rapid changes -- interfaces are supposed to
sample (at fairly high rate) and filter (to avoid noise), but, who knows.
Not everyone follows the standard properly, y'know?

Twisted pair, used in unbalanced mode, still helps relative to doing nothing
at all, but it isn't much on immunity.

Tim

--
Seven Transistor Labs, LLC
Electrical Engineering Consultation and Design
Website: https://www.seventransistorlabs.com/
 
On 5/10/2019 10:16 AM, Tim Williams wrote:
Just for lab use?  Or is this part of the flex or beehive question from
earlier?

I'd be loathe to suggest anything not shielded at least in some
rudimentary way.  There are lots of styles of flat or round
multiconductor cable that would do, and then a regular header will do on
the end, or modular connectors if you like those.

Do you mean loath by any chance? Just being a bit pedantic.
 
jrwalliker@gmail.com wrote...
On Friday, 10 May 2019, upsid...@downunder.com wrote:

After all, 100 kHz is a quite low frequency.

But the falling edges can be fast enough for transmission line
effects to be important when the cable is a few metres long.
Double clocking due to reflections makes a mess of i2c.

Using the lowest possible pullup resistors or using active
pullup that approximates to a constant current clamped at
Vcc can help with noise immunity in the high state.

Right, John. Fast falling edges are worrisome. Even
more-so, as I'm driving I2C with a fast STM processor. I
regret my PCB doesn't have a place for source resistors,
or anything (in this rev anyway). I'm using 10k pullups
on each end (5k net), and added a spot on the PCB for an
additional pullup resistor for SCL.** My flat P6C4 cable
has SCL and SDA separated 80 mils, by power and ground.

** A newby on an EE forum claimed he got good results
for 15m, with 10k for SDA, and 2k or somesuch, for SCL.



--
Thanks,
- Win
 
Tim Williams wrote...
The signals themselves might not need shielding,
but that ignores ambient noise. We're considering
a clock signal here, so we need to be wary of fast
changes from external sources.

Agreed, but I only have 24 to 36-inches of cable,
and beehives are in electrically-quiet places.

Also, it's OK if we occasionally get a bad data
transmission. We'll see how it works out.


--
Thanks,
- Win
 
On Friday, May 10, 2019 at 6:33:46 PM UTC-4, Winfield Hill wrote:
Tim Williams wrote...

The signals themselves might not need shielding,
but that ignores ambient noise. We're considering
a clock signal here, so we need to be wary of fast
changes from external sources.

Agreed, but I only have 24 to 36-inches of cable,
and beehives are in electrically-quiet places.

Also, it's OK if we occasionally get a bad data
transmission. We'll see how it works out.

Uh, be careful what you wish for. If you are using proper I2C it has a hang condition which the Intel SMBus doesn't since it includes a time out. I don't use I2C or SMBus so I can't say how significant this is, but Intel added the timeout for a reason. I assume your hives are relatively remote. How much impact will it have if you have to go to them once a month to reboot everything to unhang the I2C bus?

--

Rick C.

+ Get a 1,000 miles of free Supercharging
+ Tesla referral code - https://ts.la/richard11209
 
On 2019-05-10, Winfield Hill <hill@rowland.harvard.edu> wrote:
We need a 1-meter length of 100kHz (or slower)
I2C onnection. It'd be nice to use a pre-made
cable: micro-USB, 4-wire RJ11, or RJ45 ethernet.
Some considerations: SCL and SDA crosstalk(?),
high ground capacitance. Also need 3.3V, Gnd.

do you need UV resistant? weatherproof?

> Micro-USB: SCL and SDA twisted together, bad?

yes bad, maybe put SDA on white as SCL on red
and +3 on green

> RJ11: flat, SCL and SDA on outside lines?

or SDA-0-scl-3.3

or RJ12 0-SDA-0-3.3-SCL-0

> RJ45: SCL and SDA shielded from each other.

meh.


--
When I tried casting out nines I made a hash of it.
 
On Fri, 10 May 2019 14:22:38 -0700 (PDT), jrwalliker@gmail.com wrote:

On Friday, 10 May 2019 21:21:07 UTC+1, upsid...@downunder.com wrote:

After all, 100 kHz is a quite low frequency.

But the falling edges can be fast enough for transmission line
effects to be important when the cable is a few metres long.
Double clocking due to reflections makes a mess of i2c.

The OP had only a 1 m long line, the two way CAT5 cable propagation
delay is about 0.01 us. While the fall time can be short, the rise
time with 400 pF stray capacitances is up to 1 us and according to the
I2C standard, the signal must remain stable for 4 us. No doubt, each
receiver must have some hysteresis (Schmitt trigger). In a missmatched
line, the reflected signal causes over/ndershot.

Using the lowest possible pullup resistors or using active pullup
that approximates to a constant current clamped at Vcc can help with
noise immunity in the high state.

Use series termination on each node to tame the reflections.

 
"Rick C" <gnuarm.deletethisbit@gmail.com> wrote in message
news:0be3e775-67ce-4a39-891a-a2b9330fd7a5@googlegroups.com...
I thought I had read the standard once some time ago and don't recall that
it is intended to be sampled like a UART. Is that literally in the spec
or does it say some amount of noise is to be rejected and not seen as a
start condition or clock edge?

It's been so long since I looked at the standard in that much detail. But
some kind of minor filtering is required. A digital filter would be a
typical implementation.

If you have, say, MCU peripherals that require fairly high clocks relative
to the data rate (i.e., "400kHz"), say a 16x or higher prescaler, that's
probably what's being done.

In a correct implementation, the "400kHz" isn't, it's just the average when
everything is behaving as it should, activating and releasing SCK in a
timely manner, and with pull-up, capacitance and rise time in spec.

Tim

--
Seven Transistor Labs, LLC
Electrical Engineering Consultation and Design
Website: https://www.seventransistorlabs.com/
 
Jasen Betts wrote...
On 2019-05-10, Winfield Hill wrote:
We need a 1-meter length of 100kHz (or slower)
I2C onnection. It'd be nice to use a pre-made
cable: micro-USB, 4-wire RJ11, or RJ45 ethernet.
Some considerations: SCL and SDA crosstalk(?),
high ground capacitance. Also need 3.3V, Gnd.

do you need UV resistant? weatherproof?

It'd be nice, but otherwise I'll wrap everything
with rubber mastic electrical tape, or some such.

Micro-USB: SCL and SDA twisted together, bad?

yes bad, maybe put SDA on white as SCL on red
and +3 on green

RJ11: flat, SCL and SDA on outside lines?

or SDA-0-scl-3.3

or RJ12: 0-SDA-0-3.3-SCL-0

This is my choice: RJ12 6P6C connector, except
3.3-SDA-3.3-0-SCL-0 (3.3 and 0 are equivalent)
Flat 6P6C cables from Amazon, $4 each. An RJ12
connector at each end, series damping resistors.
A bit of a kludge, but beehive clock is ticking.

RJ45: SCL and SDA shielded from each other.

meh.

Mounted RJ45 connector, but too big, cable too
stiff, unsure of how the shielded variant works.
Went to smaller, simpler RJ12 instead.


--
Thanks,
- Win
 

Welcome to EDABoard.com

Sponsor

Back
Top