|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Can I branch the CAN to go to two separate places?
So far, we've always been wiring CAN devices in series so that one pair of CAN wires on a device feeds directly into a pair on the next device, and all devices are in series. What would happen if I were to branch the CAN so that the output wires on a device split and I sent the two resultant pairs to different devices? I've read technical documentation on the CAN so I have some ideas, but I'd like to get an opinion from someone who knows about this in detail before I draw a (potentially incorrect) conclusion.
|
|
#2
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
If you get it Phased correctly it should work. Do you have the access to just try it? I am curios to find out.
|
|
#3
|
|||||
|
|||||
|
Re: Can I branch the CAN to go to two separate places?
It's not recommended but I've seen teams do it and not have any issues. It's probably one of those things where it may work, but it may also cause problems. If you start seeing anything strange like devices not responding it would be a good place to start troubleshooting.
The CAN network seems pretty resilient, I've seen teams run with out any termination in the line. We've used a variety of interconnects between nodes without any issues, etc. |
|
#4
|
|||
|
|||
|
Re: Can I branch the CAN to go to two separate places?
Yes, we're planning to try it and see how it goes. My main concerns are that it is either not legal (and by extension we would fail inspection) or not functional (the protocol depends on it being sequential and would not function correctly without it). Am I correct that I would theoretically need to add a 120-ohm termination resistor to whichever end doesn't ultimately end up in the PDP? And what do you mean by "phased correctly"?
|
|
#5
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
My advice would just be to not do that. I get that you might have one talon on one end of your bot, and another talon on the other end. But can wire is so thin anyway, just run a really long strip. No point in introducing points of failure into an already relatively "fragile" system.
|
|
#6
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
When you split a terminated bus like this you create the probability of reflections. If you look up a tool called TDR:
https://en.wikipedia.org/wiki/Time-domain_reflectometer It is not recommended to do this. Certain patterns of communication traffic might become garbled. Resulting in intermittent errors you can't see a cause for. Leaving an end unterminated is actually worse, as well would be using the wrong value terminators. Last edited by techhelpbb : 24-09-2016 at 15:40. |
|
#7
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
Quote:
Generally RF rules apply if you're at high frequency (such as CAN, ethernet, or Wifi/Bluetooth) or you're over a massively long distance (such as a 10 mile power transmission line). TLDR: Don't branch CAN wires, while it seems like it will work in reality it's asking for trouble. |
|
#8
|
|||||
|
|||||
|
Re: Can I branch the CAN to go to two separate places?
If the entire collection of CAN devices and wiring is physically small enough, you can get away with just about any topology without it breaking.
My advice: don't tempt fate. Use the system as specified and as designed, with a single "chain" of devices each having their own internal very short tap on the bus. Troubleshooting will be much more straightforward. |
|
#9
|
|||
|
|||
|
Re: Can I branch the CAN to go to two separate places?
The CAN standards allow "star" configurations for low data rates over long distances. For your peace of mind, it is probably best to avoid using the star configuration if it can be avoided. With the (low) quality of the wiring I have seen in many FRC robots, a bad connection is at least as likely to be the real cause of their CAN Bus problems.
It is the high edge-rate (short rise-time and fall-time) of the signal that directly leads to reflections, not the data rate. Of course, as the data rate rises, faster edge-rates are required to maintain signal integrity. Many of the CAN transceiver chips have the ability to reduce the edge-rate to minimize reflections when running at lower data rates. Without looking at CTRE and NI's schematics, it is difficult to know if they are using such a feature. The length of the various line lengths determines whether a reflection causes interference or not. With the rule-of-thumb signal propagation delay of 2 nsec/foot, your CAN wiring would have to be pretty long (in the order of 100 ft.) for it to have an effect on a 1 Mbps signal, longer than one could reasonably put on an FRC robot. If one wires the CAN Bus with the PDP "at the end of the chain" then one should always have the terminations. With a star configuration (or multi-star), the PDP should still be the furthest from the RoboRio. Quote:
|
|
#10
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
Do NOT do this! Your goal is to make the robot as robust as possible. One way to make the robot more robust is to wire the power, sensors and control lines per the recommendations of the relevant standards committees or OEMs. Use the correct tools and the correct techniques then test everything over and over again.
Could you get lucky? Sure Is it worth it? No, a hundred times no Is it a "professional" thing to do? No buyer would sign off and pay you for something wired incorrectly. You might be thinking "if it works then who cares"? This is where engineering ethics comes in - you are not compliant and you know it. So fix it! That is my two cents. I've delivered many dozens of high performance systems. And I've been on the receiving end of non-compliant subsystems and made them fix everything (using their own money). |
|
#11
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
QFT - I should have mentioned this. But on the roboRio the CANbus is running near full-speed. You would have to slow the bus down and all kinds of things might stop working (PCM control loops not closing, not enough bandwidth to query/set Talons etc).
|
|
#12
|
|||
|
|||
|
Re: Can I branch the CAN to go to two separate places?
Quote:
What do you mean by "slow the bus down"? Do you mean a slower data-rate or do you mean a slower edge-rate? |
|
#13
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
That's how I was taught in Electromagnetics class. Of course resistance is still present, but it's not 100% of the picture and looking at it alone will lead to results more puzzling that the statements I made.
Quote:
Quote:
Otherwise, obviously I agree. |
|
#14
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
Quote:
Since CAN signals are NRZ digital (with the 1&0 voltages dependent on the PHY layer design) they represent a typical digital square wave of odd-integer harmonics with differential signal. The issue, and the TDR neatly demonstrates this concept, is that an analysis over time (not at any given instant) can produce reflections when the termination or legs (even the legs of the circuit inside the devices) get too long. So it's not merely the real component of the terminator resistance at work. It's the capacitance, inductance and impedance of the circuit as a whole. (Active AC components tend to introduce mathematical imaginary or polar numbers into circuit analysis so when I say real resistance I mean DC resistance.) Long story short - I don't think anyone in the last few posts disagrees that students shouldn't follow the guidelines. No one wants to have intermittent phantom problems that only happen when a certain pattern of traffic is sent over that CAN bus. I don't think I've ever seen a FRC team test their CAN bus with a BERD/BERT even though the speed is pretty high on that circuit (a T1 digital telephone circuit is basically 1.544Mbps and these are usually tested with something like a T-BERD). There's limited rational reason in the last few years of robots that the CAN bus configuration as recommended can't be achieved. Even if you somehow put a Talon 14 feet up an end-effector you could avoid doubling back with the CAN buss wire (which given you'd be running the power up there seems sort of strange) by simply ending the buss up there. There are some good examples of why a star configuration has advantages if you suspect your devices might fail to be connected. However, like in computer networking, how far does one want to go to get a star network without the circuit implications? Active CAN hubs? How about a CAN switch? (NOTE: I am making no suggesting the 2 links I provided are FRC legal or even recommended, just pointing out that such devices exist with evidence.) Last edited by techhelpbb : 27-09-2016 at 09:51. |
|
#15
|
||||
|
||||
|
Re: Can I branch the CAN to go to two separate places?
Quote:
one implies the other (but not really sure what you mean by edge rate) |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|