I been having issues with my CAN bus setup. I got it successfully doing loopback test. But when i reboot and connected recommend waveshare CAN transceiver with it and connect the other end to the peak-can dongle and i run
cansend can0 123#abcdabcd
in terminal, it shows nothing on my pcan explorer. After that i tried to connect that into an Oscilloscope. It shows nothing as well. Here is the OS and hardware info that i got.
Hardware: nvidia Jetson Orin Nano Dev kit
OS: jetpack 5.1.2
CAN transceiver: waveshare SH65HVD230
Could you share the block diagram of your connections?
How do you setup your peak-can dongle? (like bitrate..etc)
Please share the full steps how you setup CAN and also the result of following command on both sides.
I have solder the header on to the orin nano dev kit carrier board. the set of header that is 3.3v GND CAN RX and CAN TX and i connect the waveshare board to the 4 header, Like 3.3v to 3.3v, GND to GND, CAN RX to CAN RX, CAN TX to CAN TX. And on the other end of the waveshare broad i connect CANH and CANL to the DB9 connect that will mate to the PCAN dongle.
I am currently not in the office right now. So i can’t really get the hardware info as needed, I will see if i can get remote access into my hardware and get the info as needed. But i know for sure i am running on jetpack 5.1.2.
I SSH into my jetson and here is the command that i use to setup the CAN communication on jetson.
tian@jetson:~$ sudo busybox devmem 0x0c303018 w 0xc458
tian@jetson:~$ sudo busybox devmem 0x0c303010 w 0x400
tian@jetson:~$ sudo busybox devmem 0x0c303010 w 0xc400
tian@jetson:~$ sudo modprobe can
tian@jetson:~$ sudo modprobe can_raw
tian@jetson:~$ sudo modprobe mttcan
tian@jetson:~$ sudo ip link set can0 up type can bitrate 1000000
and here is what happen when i use the command you provide.
Yes, I do have all of them except for the GND connection between all devices on bus. I thought since is an differential signal between CANH and CANL gnd connection is not necessary. But i will give that a try as well.
The reason why GND needs to be connected is to bring all devices to the same reference voltage.
Yes, if CAN_H=4V and CAN_L=2V, dV=2V, which means a logic 0.
Also, if CAN_H=44V and CAN_L=42V, then dV would be also 2V. This would happen if GND of one device and GND of another device have a difference of 40V. But the differential amplifier gets overloaded at such high voltages and won’t work any more. This is called common mode range.