A "simple" explanation of CAN bus.

OldblueAccord

Active member
Marks is all over it so Ill keep my comments short as always. Like I said 18 years ago on several car forums CANbusC should never every be used in an Automotive setting at all.

I think the printing press I work on now has 750 nodes but it may have 900. Nothing but a headache. Germans seem to like Profibus or Interbus.
 

Nic7320

Solera 24S on a 2011 NCV3 chassis
A "differential signal" simply means the signal is sent on two wires instead of "single ended" where they use only one wire for a signal and a ground return.

The reason for this is improved noise rejection and because it greatly reduces errors due to ground voltage differences when other end's ground path might have additional voltage induced on it.

Imagine you're on a ship and another ship is using a single red flag to tell you to stop or go. Up means stop, and down means go. But you can't see much other than the red flag since it's foggy. You would be hard pressed to decide if it's up or down without a second reference to compare it to.

By sending two signals, you look at the differential (difference) between the two flags and act on that. Left flag up with right flag down means stop and left down with right up means go.

The problem with electronic circuits is there are lots of things using the circuit ground, so it becomes noisy. And just like on a ship, you can't tell if a signal is true if you can't agree where the other end is calling zero volts.

So we use differential signals to send data because it is more reliable and it can often be done with lower voltage swings which require less power (e.g. LVDS, EIA644 differential signaling).
 
Last edited:

marklg

Well-known member
A "differential signal" simply means the signal is sent on two wires instead of "single ended" where they use only one wire for a signal and a ground return.

The reason for this is improved noise rejection and because it greatly reduces errors due to ground voktage differences when other end's ground path might have additional voltage induced on it.

Imagine you're on a ship and another ship is using a single red flag to tell you to stop or go. Up means stop, and down means go. But you can't see much other than the red flag since it's foggy. You would be hard pressed to decide if it's up or down without a second reference to compare it to.

By sending two signals, you look at the differential (difference) between the two flags and act on that. Left up with right down means stop and left down with right up means go.

The problem with electronic circuits is there are lots of things using the circuit ground, so it becomes noisy. And just like on a ship, you can't tell if a signal is true if you can't agree where the other end is calling zero volts.

So we use differential signals to send data because it is more reliable and it can often be done with lower voltage swings which require less power (e.g. LVDS, EIA644 differential signaling).
From an electromagnetic interference standpoint, a differential signal is very helpful. With the twisted wires, one wire going up in voltage, and the other going down, from a few inches away the EMI cancels out.

From a practical standpoint, differential signals with twisted wires are almost as good as a shield, which is what they did.

Regards,

Mark
 

Green Maned Lion

Der Unverbesserliche.
A "differential signal" simply means the signal is sent on two wires instead of "single ended" where they use only one wire for a signal and a ground return.

The reason for this is improved noise rejection and because it greatly reduces errors due to ground voktage differences when other end's ground path might have additional voltage induced on it.

Imagine you're on a ship and another ship is using a single red flag to tell you to stop or go. Up means stop, and down means go. But you can't see much other than the red flag since it's foggy. You would be hard pressed to decide if it's up or down without a second reference to compare it to.

By sending two signals, you look at the differential (difference) between the two flags and act on that. Left up with right down means stop and left down with right up means go.

The problem with electronic circuits is there are lots of things using the circuit ground, so it becomes noisy. And just like on a ship, you can't tell if a signal is true if you can't agree where the other end is calling zero volts.

So we use differential signals to send data because it is more reliable and it can often be done with lower voltage swings which require less power (e.g. LVDS, EIA644 differential signaling).
I'd imagine the principle is similar to balanced audio cables?
 

marklg

Well-known member
I'd imagine the principle is similar to balanced audio cables?
Exactly. Same concept. I believe that's why they went with XLRs and balanced cables for DMX lighting control, besides that they were familiar to the industry.

Balanced or differential signaling also adds immunity to external RF interference. The same interference will be on both linee, so it creates what is known as a common mode signal. Differential or balanced equipment will have common mode rejection. If one wire doesn't go up while the other goes down, it gets rejected.

Regards,

Mark
 

Nic7320

Solera 24S on a 2011 NCV3 chassis
"Common mode" noise cancels out because the induced noise pushes both wires the same direction, and noise on one wire minus the same noise on the other equals zero. The minus comes from an inverting input on the bus receiver that gets the second wire.

"Balanced" refers to the way each wire of a two wire interface has the same properties, same impedance to ground, same length, same everything (if possible). That helps keep any induced noise equal on both wires so it cancels out at the receiver.

[Big edit here for clarity:] Twisting the wires also helps, because any noise that gets into one wire from an interference source is likely to also get into the other wire in the next half twist. Then the noise is more or less equal on each wire since the difference in propagation time to the next half twist is negligible. Plus the twist helps hold the wires together and at the same distance so the pair has a more uniform impedance.

In the real world, nothing is perfectly balanced, and the receiver's common mode rejection doesn't cancel out all of the noise, but it's close enough.
 
Last edited:

autostaretx

Erratic Member
A "differential signal" simply means the signal is sent on two wires instead of "single ended" where they use only one wire for a signal and a ground return.
In the long ago and far away days, differential signals were also called "push/pull" signals (usually involving currents, not voltages)
You'd flow the current from (say) red to green for a "1", and from green to red for a "0".
Ground was not involved, merely the current direction through the wires.

One (mixed) advantage of current loops is that you could splice in extra receiving units in *series*. They'd all see the same signal.
(mixed: in reality, adding lots of in-series receivers required that the source voltage could rise high enough to handle the extra resistance of each receiver. The other killer was that having a break in any wire (or receiver) would disable the entire loop)

--dick
 

mercedesstern

Active member
Marks is all over it so Ill keep my comments short as always. Like I said 18 years ago on several car forums CANbusC should never every be used in an Automotive setting at all.

I think the printing press I work on now has 750 nodes but it may have 900. Nothing but a headache. Germans seem to like Profibus or Interbus.

Why it shouldn't be used in automotive? What else should be used?

CAN-bus works well in automotive as long as engineers understand it and are not constrained by incompetent managers. Unfortunately engineers are forced to cut corners and that leads to unreliability. It's not the technology itself.
 

mercedesstern

Active member
I'd imagine the principle is similar to balanced audio cables?

Correct, except that audio signals are much more susceptible to signal distortion than 0s and 1s. Despite that a balanced audio signal doesn't require shielding, just a pair of twisted wires for a very good audio quality. In automotive non-shielded twisted wires are used for transmitting the audio signal from the head unit to the amplifiers without any noise issues, despite it is a relatively noisy environment.
 

OldblueAccord

Active member
2026? its already out of fashion. Ethernet for sure. Im not sure what Tesla/Rivian is even using but they moved away from Canbus.

Last factory I worked at that gave a damn we dumped it for Industrial Ethernet 10 years ago. The only reason we dont change out our current system where I work now is the huge amount of cost and work it would be. I could see it going well over 500k to upgrade.
 

marklg

Well-known member
2026? its already out of fashion. Ethernet for sure. Im not sure what Tesla/Rivian is even using but they moved away from Canbus.

Last factory I worked at that gave a damn we dumped it for Industrial Ethernet 10 years ago. The only reason we dont change out our current system where I work now is the huge amount of cost and work it would be. I could see it going well over 500k to upgrade.
Ethernet is point to point, not a tapped bus, so you need a different topology. Ethernet also has higher and non deterministic latency. Auto busses need low and often fixed latency. There are multiple busses for autos, including faster CAN.

Regards,

Mark
 

mercedesstern

Active member
Also, the beauty of CAN is it's simplicity and lower power consumption compared to Ethernet derivatives like Automotive Ethernet. Computational and memory requirements are very low (an ATMega328 @ 8MHz is completely sufficient), software development is not complex (MCP2515 libraries are Open Source) and my nodes consume about 2uA in sleep mode each.

For home automation (what we need it for in our vans) data rates way below CAN max possible data rates are completely sufficient.
 

OldblueAccord

Active member
When you car shuts off on the I 40 interstate left lane ..all that great explanation goes right out the window...Im not trying to be offensive at all but you got to look at the results at some point...they bought my siblings car back after telling her for a year they could fix it. There is no fixing a bad design.

I mean you get 30 services call in a 30 month period on a production machine with Canbus or zero with Industrial Ethernet what would you pick?...and remember Walmart has 4 tractor trailers waiting on you and the fines are by the hour? Really easy call...
 

marklg

Well-known member
When you car shuts off on the I 40 interstate left lane ..all that great explanation goes right out the window...Im not trying to be offensive at all but you got to look at the results at some point...they bought my siblings car back after telling her for a year they could fix it. There is no fixing a bad design.

I mean you get 30 services call in a 30 month period on a production machine with Canbus or zero with Industrial Ethernet what would you pick?...and remember Walmart has 4 tractor trailers waiting on you and the fines are by the hour? Really easy call...
Don't confuse a technology with the implementation. Any technology can be implemented well or badly. We have both CAN bus and Ethernet (based) aviation busses that meet design assurance level A, that's a probability of failure better than one in a billion per flight hour.

Regards,

Mark
 

Maslin

I've worked on a few vans
CAN, LIN, FlexRay, and Ethernet all exist for different functions. I believe there’s still some MOST on the cars as well, fiber communication they’ve had for 30 something years.

What massive systems level issues are people seeing with CAN? It’s extremely reliable in this application.
 

Green Maned Lion

Der Unverbesserliche.
CAN, LIN, FlexRay, and Ethernet all exist for different functions. I believe there’s still some MOST on the cars as well, fiber communication they’ve had for 30 something years.

What massive systems level issues are people seeing with CAN? It’s extremely reliable in this application.
I'm not sure I'd argue the point. It is extremely reliable, but its limited point failure. When things like CAN fail, its often something like the SAM that can't be realistically repaired in the field.

Whereas, I'd have problems with my 123s... but I could usually fix them on the side of the road with a few basic tools. That being said, having to deal with that sort of thing was far more common than CAN issues. And, of course, one has to be able to logically figure out why something isn't working, because its not like I can plug in a scan tool and have it tell me what fault exists. I just know that, for example, when I turned on the headlight switch, it blew a fuse. Why? :idunno:
 

Nic7320

Solera 24S on a 2011 NCV3 chassis
Ethernet is point to point, not a tapped bus, so you need a different topology.

It's intestesting that Ethernet started as a shared bus network (10BaseT), using 50 ohm coax and T adapters at each network interface card as it snaked around a building. The T adapters kept the stubs very short.

Tesla probably uses Ethernet because of the data rate required for all the cameras.

And now we "CAN" agree that networking data in any vehicle nowdays is hardly simple, especially when manufacturers stray from engineering standards.
 
Last edited:

OldblueAccord

Active member
Don't confuse a technology with the implementation. Any technology can be implemented well or badly. We have both CAN bus and Ethernet (based) aviation busses that meet design assurance level A, that's a probability of failure better than one in a billion per flight hour.

Regards,

Mark
Very well said as always...of course I dont fly at all.
 

Nic7320

Solera 24S on a 2011 NCV3 chassis
As our discussion found out, Mercedes strayed from the original Bosch CANBUS specification to the CAN block signal distribution scheme.

And does it work? Sure, but the risk is everyone thought it was a properly terminated multi-tapped bus and it wasn't like that at all.

No wonder people have trouble with it
 
Last edited:

Top Bottom