ML Riechers Systems Engineering


[Photo of the Front Side of our rse-2c micro-controller card]

Taking the Time to do the Firmware Right.


Problems with Differential Signaling, "Grounding Issues."

CEO Summary:

We've recently become aware of a grounding problem between the Master Station (Touch Screen) and certain Register Boxes which destroys any hope of updating the Touch Screen's station info.

Four years ago we switched to really, really, really good signaling chips, because we lost way too many just really good signaling chips destroyed by high voltage on the transmit line. But we found that our really, really, really good chips are not good at all communicating with "ungrounded" stations. If you want reliable communications and robust hardware, make sure that every station is well grounded. Get your Grounding Right.

Executive Summary:

(Sung to the tune "Ya Gotta Have Heart"  &mdash Damn Yankees)

"Ya Gotta Have Ground,"
"Miles and Miles and Miles of Ground..."

Or, my Dad would say, "Boy, you've got to be well grounded in something, 
or you'll never amount to anything.  Try Time Domain Reflectometry."

We've recently become aware of a grounding problem between the Master Station (Touch Screen) and certain Register Boxes which destroys any hope of updating the Touch Screen's station info.

To communicate from the Master Station (Touch Screen) to the Register Boxes, we use a method called Differential Signaling, conforming to standard RS-485. This is normally a very reliable and fast method, much better than the old RS-232 standards. For instance, the old RS-232 standard will not tolerate much electrical noise, nor will it put up with end points which are based at different voltage levels. This is the "Grounding issue."

Our RS-485 Differential Signaling ignores all but the nastiest sort of electrical noise, and tolerates base voltage differences between end points (which we'll call "stations," including the "Touch Screen," because that's what you'll call them), up to a point. For reliable communications, this voltage difference limit generally works out to be between about -7 to +7 volts, perhaps a bit more. Much more than that, and you risk frying your equipment.

A more subtile problem lies with "ungrounded" stations. These are stations electrically isolated from the rest of the stations. They don't really have a "different" base voltage level. The base voltage level of these stations "floats" under the influence of the nearest electromagnetic field(s), and with whatever signals attach to them. In fact, this "ungrounded" station may be sorta grounded through its own and other driver and receiver chips. Obviously this is not a good situation: grounding currents should not be "surging" through the signaling chips.

But, for infamously bad luck, how's this: The older, cheaper, weaker, RS-485 chips actually work _better_ to communicate with the "ungrounded" station. The badder the chip, the better it will "work" &mdash more or less most of the time. This is because the badder the chip, the more stabilizing current it will allow through itself, but at the price of its own eventual suicide. The better the chip can protect itself, the less it will allow the "ungrounded" station to ground itself through the chip.

We use really, really, really good RS-485 chips, because we were losing way too many just really good signalling chips destroyed by high voltage on the transmit line. They are so good at protecting themselves against overvoltages and drawing significant currents, we've not had a documented failure since shipping these starting in February 2004.

In fact, they are so good that they can't produce a makeshift parasitic power/ground reference path for "ungrounded" stations, and so are not good at all communicating with the "ungrounded" station. So, if you want reliable communications and robust hardware, make sure that every station is well grounded. Get your Grounding Right.

Problems with Differential Signaling, "Grounding Issues."

Or, dispite what your mother told you, everything has everything to do with ground -- including Differential Signaling. Get your Grounding Right.

When we explained Differential Signalling in "Drive Issues," we told you to not read anything into "A Positive Voltage" or "A Negative Voltage" with respect to "ground." Conceptually, Differential Signaling has nothing to do with ground. Then we said, OK, for you wise guys who know better, everything has everything to do with ground... OK, now's the time to 'splain this, and why a Register Box's can't communicate with the Master Station (Touch Screen).

But first, a little review.

Review.

Five Volt Differential Signaling is very common on the factory floor and in the office. "RS-485" or "RS-422," are very common Differential Signaling standards that specify, along with a whole lot of other stuff, that voltage. Similar to a current loop, Differential Signaling uses two wires and a voltage difference between the wires; a Differential Signaling transmitter might look like this:

                               (Current Out)
A Positive Voltage on Wire A  >-----------------> V 
                                                  V (imagine a resistor here) 
A Negative Voltage on Wire A' <-----------------< V
                               (Current Return)

Let's call that the "off" or "normal" state. Then the opposite is the "on" or "abnormal" state:

                               (Current Return)
A Negative Voltage on Wire A  <-----------------< ^
                                                  ^ (imagine a resistor here) 
A Positive Voltage on Wire A' >-----------------> ^ 
                               (Current Out)

But, Differential Signaling is _not_ a current loop. For one thing, Differential Signaling compares _voltages_, not the presence or absence of current. But the biggest thing is that Differential Signaling _Receivers_ are not _isolated_. (Well, they could be):

TYPICAL CURRENT LOOP:

                               (Current Out)
A Positive Voltage on Wire A  >-----------------> V 
                                                  V (imagine an opto-isolator here)
A Negative Voltage on Wire A' <-----------------< V
                               (Current Return)

TYPICAL DIFFERENTIAL RECEIVER:

                      (Current Out/In)
A Voltage on Wire A  >-----------------> V (Sense Transistor here)
                                         V  |
                                         V  |--- (compare Transistor)
                                         V  |
A Voltage on Wire A' <-----------------< V (Sense Transistor here)
                      (Current In/Out)

Transistors need to be fed power, and referenced to something or other, which ends up (ultimately) being ground. This ordinarily limits signaling voltages to between the plus and minus supply voltages, as in our case, between 0 and 5 volts. However, hardware designers have lots of tricks up their sleeves, and can widen this limit.

Level Shifting &mdash doing the heavy lifting, RS-485 style.

Hardware engineers like to call this voltage translation, or, more commonly, _Level Shifting_. Typical level shifting involves say, translating [0 to 3.3V] to/from [0 to 5V], or [0 to -3V] to/from [0 to 5V], but I've also seen voltage level shifts sensing hundreds of volts. Like anything else, there are trade-offs. To get voltage, you will pay in:

  • Loss of Sensitivity.
  • Reduced Signaling Rate.
  • Increased Complexity.
  • Increased Power Consumption.
  • Cash, gelt, moola: To regain better Sensitivity, Signaling Rate, and/or Power Consumption.

    The Differential Output Transistors have troubles of their own. Even when they're turned off, these transistors have inherent or parasitic diode thingies that, frankly, leak current when the voltage on their outputs get too high (or too low). This is a good way to fry a perfectly good transistor. Engineers can build protections into the transistors, but once again, you pay:

  • Reduced Signaling Rate.
  • Increased Complexity.
  • Increased Power Consumption.
  • Cash, gelt, moola: To regain better Signaling Rate, and/or Power Consumption.

    So what are typical RS-485 voltage limits, and how do we measure the voltage?

    First, I'll state typical Never Exceed Voltages, straight from most manufacturer's data sheets, then the typical operating range, as the RS-485 spec would have it:

    Never exceeds:
    
    The Positive Voltage on any wire should never exceed 14 to 15 Volts.
    The Negative Voltage on any wire should never be less than -14 to -15 Volts.
    
    Operating ranges:
    
    The Voltage on Wire A should not exceed 12 Volts.
    The Voltage on Wire A should not be less than -7 Volts.
    
    The Voltage on Wire A' should not exceed 12 Volts.
    The Voltage on Wire A' should not be less than -7 Volts.
    
    So we bring in the concept of Common Mode Differential Signaling pair: Taken as a pair, the Voltage on Wire A and Wire A' should not exceed +12 to -7 volts.

    And how do we measure that voltage? With respect to THE GROUND at the output of the Driver Transistor or input of the Receiver Transistor.

    And what happens if you exceed the Never Exceed voltages? Possibly:

  • The receiving chip(s) will ignore the signal. The better the chip, the more likely this is to happen.

  • The receiving chips as a set will swallow the voltage, dragging the voltage down to an acceptable level. This will tend to stabilize and reference the transmitting station, if its output impedance is high enough. Whether or not any chips decode a useful signal is uncertain.

  • The receiving chips as a set will swallow the voltage, dragging the voltage down to an acceptable level. However, some chip(s) sacrifice themselves to the God of the Fuse, and degrade or destroy themselves.

  • The drivers on the receiving chip(s) will self-protect, and leak only a small amount of current. The better the chip, the more likely this is to happen.

  • The drivers on the receiving chips as a set will swallow the voltage through their inherent or parasitic diodes, dragging the voltage down to an acceptable level. This will tend to stabilize and reference the transmitting station, if its output impedance is high enough.

  • The drivers on the receiving chips as a set will swallow the voltage through their inherent or parasitic diodes, dragging the voltage down to an acceptable level. Some drivers swallow so hard that they bust. But that is really, really good for stabilizing and referencing the transmitting station, especially if they blow "shorted." But that really, really messes up the network.

    So what's all this Grounding stuff, anyhow?

    With homage and deference to my Lord Ralph of Morrison, there are two issues here: 1)The Earth acting as a Ground Plane, and 2)The Earth as a convenient zero voltage reference to compare the Register Box and "Touch Screen" base voltages.

    Let me address The Earth acting as a Ground Plane first, so I can say that the topic is important and should not be ignored, then mostly ignore it. So even though our signals are differential and carried over (I hope) paired and twisted wires, so the signal loop is very small, the Earth, or any metal sheet _still_ acts as a Ground Plane for the signal. Best is to run your own Ground Plane. I'm thinking, ideally, a metal sheet say 3 inches wide running the length of the Press, on which the signal cable lies, and grounded and grounding the various stations. You must put some thought into avoiding ground loops.

    There is another reason for using a metal sheet, instead of a round conductor: A metal sheet provides a much lower impedance return path for noise than does a round conductor of equivalent cross section.

    Now let's get on to my notion of The Earth as a convenient zero voltage reference to compare the Register Box and "Touch Screen" base voltages. I put it that way, because, as long as 1)All of the so-called "signal grounds" internal to the "Touch Screen" and Register Boxes are electrically connected with a big fat conductor, and 2)the big fat conductor is a low impedance path, and 3)the whole thing has an effective "ground plane" to interact with and reflect against, it doesn't really matter, electrically, if the the "signal grounds" are at actual ground potential or not, as long as these "signal grounds" are all the same.

    But, I wouldn't want to bet my National Electric code on that.

    So, we end up with the proposition that we'd like to start out by ensuring that the "Touch Screen" and Register Box Internal Grounds match the Earth Ground as closely as possible. For the Register Boxes, that should already be done: the nominal 24 volt power supply's return should be earthed at the power supply. However, you'd do well to check how effective this grounding is.

    That may not be true for the "Touch Screen," however. We've had certain indications that it might not be earthed at all. You see, the "Touch Screen" has its own power supply typically running off of 120 Volts, to DC through a transformer, which provides galvanic isolation. The "Touch Screen" case and internal signal ground may or may not be hooked up to "ground" through the Safety Ground (green wire). If it isn't, you'll have to ground the case and (hopefully you can find a stud saying "signal ground") maybe the "signal ground" yourself. If it is, then that may or may not open up a whole new can of worms, if it turns out that the green wire goes all the way back to the Main Service Entrance. That could well mean that the "Touch Screen's" "local ground" might be grossly out of whack with the Register Boxes' "local ground."

    Notice how effectively I've danced around a whole host of issues. That's because the whole topic of "grounding" is filled with if's, but's, and maybe's, enough to fill a book. And that's not even to mention common misconceptions about grounding, and the new thinking emphasizing conceiving grounding and interference problems as interacting and changing electromagnetic fields, instead of circuit theory.

    But enough of all that. Your Press is unique, but chances are that checking the things I said ought to clear the matter up "well enough." If it doesn't, then there's Plan B based on your unique electrical situation.

    10 Cent Summary

    1. Our really, really, really good signaling chips don't play well in Presses with Grounding Problems.

    2. The reason our really, really, really good signaling chips don't play well in Presses with Grounding Problems, is because they are really, really really good signaling chips. They protect themselves, and their systems, really, really well.

    3. The cheaper chips that we used to use a long time ago seem to play ok, as much as we can tell, in Presses with Grounding Problems. At least they communicate well enough to give that impression.

    4. The cheaper chips that we used to use a long time ago that seem to play ok, as much as we can tell, in Presses with Grounding Problems, do so, as best we can theorize, by providing an un-authorized virtual ground path through themselves, and by other self-destructive behavior.

    5. Using the cheaper chips that we used to use a long time ago as a solution to Grounding Problems in Presses with Grounding Problems is not a sterling idea: 1)It's not a 100% solution; 2)It is most likely destructive to the cheaper chip; and 3)The cheaper chip will be exposed to potential dangers that could destroy it &mdash dangers that the really, really, really good signaling chips are immune to.

    6. The solution is to address the Grounding Problems.

    Contact Information

    Please send inquiries about MLRSE to
    M. L. Riechers Systems Engineering     Voice:  +1-513-844-2220
    530 Main Street                        Fax:    +1-513-844-2279
    Hamilton, Ohio 45013-3222, USA         mlr(at)rse(dot)com
    


    This page was created by Mike Riechers, e-mail at: mlr(at)rse(dot)com

    The Webmaster of this site is free to use the images below on an Apache/NetBSD-powered Web server. Thanks for using Apache on NetBSD!

    Site driven by NetBSD - NetBSD rocks!