Hey everyone I am currently using CAN bus to control four ODrives via a Feather Can M4 Express from adafruit. I have a serial to CAN bus converter firmware written that allows me to connect to the CAN Bus via serial. I am using an oscilloscope to look at the waveform of the CAN bus data and found something interesting.
All the ODrives are powered via 52V. The first issue or concern is the general spikiness of the signal even with no data being sent via the CAN bus. The first block of signals being sent are requests for voltage data to be sent from all 8 ODrive devices. Then the following response is the voltage data being sent back from the ODrives to the Feather CAN. However, as you can see it is extremely spiky indicating a good deal coming from the Odrive.
I thought this may have been bus collisions so I then changed it to ask only one ODrive for voltage and I got the same result, a very noisy response. Granted it works great I am just curious if there is a way were could remedy this to try and produce a cleaner signal or if anyone else has had this issue.
Motor drivers are a noisy environment. CAN uses differential signaling exactly for the reason to be resiliant to this type of noise. Make sure you use twisted wires between the CAN_H and CAN_L signals.
After that, get your scope to show you the difference between the signals, and make sure you have a high bandwidth/sample rate on the scope. I hope it will show that the differential signal is clean, except for some noise picked up on the scope probes.
1 Like
Don’t forget to use 120 ohm resistors at each end, too! ODrive has a switch to enable it on the board
I am using twisted wires specifically for can bus and also adjusted my sample rate to 10us per division and still see a high degree of noise. The bigger issue is that this noise was present with no robots even running. Also, I had 120-ohm resistors on each side when testing, I also tried without the switch enabled and it looked the same which is interesting. I am using an Arduino Feather M4 CAN to convert serial to CAN bus data.
Today I was working on the can bus trying to reduce noise levels by slowing adding ODrives and seeing how it affects the noise on the scope. I have had 3 ODrives break on me in the past presumably too ground loops from connecting to it with serial while driving motors. Now today another 2 ODrives died on me, this time no serial was plugged in. I did have CAN bus plugged in as well as a ground cable from the Feather to the ODrive to ensure both are on the same ground. The feather was then plugged into my computer. I have been very careful with the wiring to ensure proper gauge wire is being used for the power and we are running at 48V. Once again I want to reiterate that no motors were even moving all I was doing was sending CAN messages asking for the vbus voltage. I have attached pictures of the wiring below. I love these boards but just cant seem to get through issues that are causing the boards to seemingly die. When I measure voltage on the broken boards I have full 5V but the 3.3V line is only at 0.5V and all the chips get extremely hot. Any Ideas?
Can you share your wiring schematic? You’re doing something that’s frying the STM chips. Considering you have some other source of noise in your system (CAN noise with no bots running?) I suspect power supplies or similar.
Dead (hot) STM32’s is usually caused by injected currents due to ground loops hitting the logic pins. Do you have a diagram of your logic wiring, and how various grounds are connected together?
@Wetmelon Regarding that, I am using the Odrive Pro and I want to use the CAN, however, I can’t find how to activate that internal resistance. Is there an internal resistance on that new model?
Thanks
Yes, there is a small double DIP switch on the board, one of those is DFU/RUN and one is 120ohm / 0ohm CAN termination.
1 Like