7
\$\begingroup\$

I'm looking at using RS-485 to connect a bunch of sensors across a lengthy distance (approx 500 metres) however the location of the sensors means it would be suitable for connection as a loop.

By loop I mean that instead of having a single cable for the bus, with terminators (termination resistors) at either end, the terminators are removed and the two ends of the cable are connected together.

The reason for considering this is that in theory it would mean that if the cable was cut at any single point, the RS-485 communications would continue to function. A second cut would be needed before devices may start disappearing off the bus.

I realise that RS-485 needs terminators at either end of the cables for high speed operation, however these are optional at low speeds, which are fine for my sensors.

So if I would be able to run this bus normally without terminators, would it still work if I took the extra step of connecting the cable ends together as well?

\$\endgroup\$
4
  • \$\begingroup\$ Why do you think that a single wire cut would let the bus continue to function? Any open wire would partially disable the bus. rs485 is a differential signal. Both wires are needed. \$\endgroup\$
    – vini_i
    Commented Jun 4 at 10:58
  • \$\begingroup\$ How slow can you go? 9600? 1200? 300? One answer is this: if you go slow enough it will work \$\endgroup\$
    – jonathanjo
    Commented Jun 4 at 11:19
  • 1
    \$\begingroup\$ @vini_i If I understand correctly, the asker's proposal is to connect one end of the cable to the other end of the same cable, thus creating two independent connections between any device and any other device. If the cable is cut anywhere (even through both wires), it will still act as a single cable connecting all of the devices. \$\endgroup\$ Commented Jun 5 at 0:28
  • \$\begingroup\$ @TannerSwett I see what you mean. \$\endgroup\$
    – vini_i
    Commented Jun 5 at 12:06

3 Answers 3

9
\$\begingroup\$

Because RS485 injects a current signal, the twisted pair cable can be connected in a loop and will self terminate but, the problem is that you have two paths in which the signal travels down and, those two signals will hardly ever reach the intended destination at the same point in time.

This will certainly lead to corruptions.

In addition, you will find that the signals carry on passing around the loop many, many times until they die out. In my opinion it doesn't sound like a practical solution.

Here's a simulation of 450 metres of twisted pair terminated in 100 Ω (our baseline): -

enter image description here

Results are as expected for a current driver of +/- 10 mA.

If I loop back the 150 metre section and remove the terminator, we get this highly corrupted waveform at the input: -

enter image description here

I've focussed on the input waveform because if that gets corrupted then the output waveforms will also be corrupted. I've also increased the voltage range in the plot because, as you can see, the waveform is heading south and will start hitting the RS-485 voltage extremes pretty quickly.

I also ran the simulation for 100 μs and things did not settle down at all.

\$\endgroup\$
4
  • \$\begingroup\$ Wouldn't that only be a problem for higher speed communications? At lower speeds wouldn't the signal levels settle before it becomes an issue? My understanding is that the purpose of stopping the reflections is to prevent e.g. a high reflecting back down the line at the exact moment you're trying to transmit a low, but if those reflections/loops settle by the time the next bit is being sent, it shouldn't be a problem? \$\endgroup\$
    – Malvineous
    Commented Jun 4 at 10:41
  • 2
    \$\begingroup\$ @Malvineous it will be a problem even at low-speeds but, I've attached simulations to show what happens using data rates at 1 MHz so that you can pick-up the baton and try this for yourself in a simulator of your choice. \$\endgroup\$
    – Andy aka
    Commented Jun 4 at 11:19
  • \$\begingroup\$ Hmm, so how come at 9600 bps, with a pulse width of 104 µs, the signal still gets corrupted? From a physical perspective I would've thought there would be ample time for everything to settle, since the signal would propagate through the 500 m cable in around 2 µs. Even if the signal bounced through the cable a dozen times surely it would still settle within 100 µs before the next bit transition took place? \$\endgroup\$
    – Malvineous
    Commented Jun 9 at 3:40
  • 1
    \$\begingroup\$ For a start, the bouncing would initially drive the signal crashing into the RS485 voltage limits and this might cause an issue. Secondly, the signal shape is highly corrupted (look at the 2nd signal image in my answer). Thirdly, the looping signal is likely to become additive and grow with time. Fourthly the signal is unlikely to have settled down by the mid-bit (sampling) point. In fact, it might not settle down to a reasonable level in a milli-second or 10 milliseconds. \$\endgroup\$
    – Andy aka
    Commented Jun 9 at 9:54
4
\$\begingroup\$

It is not intended to run RS-485 without termination and in a ring topology.

Having said that, RS-485 can be used without termination, if the bus length is short, or speed is low enough so that the reflections don't matter, but it does not mean low speed at the level of bit rate, it means that the transitions on the bus are slow enough that there are no sharp transitions. But this scenario is well known if the bus is not a ring.

When bus is in a ring, you basically have an infinite transmission line so it does not need termination at the end to make it look like an infinite transmission line. The problem is more like the signal traveling both routes and the signal edges keep traveling basicaly infinitely around the loop but fading away due to losses. Having a very slow speed to allow for very slow signal trasitions can help here too.

If there is a problem and the bus breaks and stops being a ring, then you are left in a scenario of unterminated long bus that is without termination, and you still want it to work, so you anyway need low bit rate with slow transitions on bit edges.

So do try first as a linear bus without terminations, and then connect the ends together. It helps if you have an oscilloscope to view bus waveforms.

Even without proper strong terminations, I recommend some kind of biasing for the bus, to keep the wires weakly floating at some idle voltage. It means that there should be a pull-up on one data wire and pull-down on the other, to define the idle logic level.

\$\endgroup\$
1
  • \$\begingroup\$ The capacitance of the cable can be significant and dampens the system a fair amount. \$\endgroup\$
    – Kartman
    Commented Jun 4 at 11:37
0
\$\begingroup\$

Even if you could get away with using it as a ring, a single cut would then leave you with an unterminated, or wrongly terminated, bus, which will not work.

\$\endgroup\$
1
  • 2
    \$\begingroup\$ Except if the baud rate was slow enough to allow slow enough slew rate for the whole case anyway. \$\endgroup\$
    – Justme
    Commented Jun 4 at 14:01

Not the answer you're looking for? Browse other questions tagged or ask your own question.