Real-Time Measurement and Control

annuler
Affichage des résultats de 
Rechercher plutôt 
Vouliez-vous dire : 

CAN communication issue

Résolu !
Accéder à la solution

Hello,

 

I am using NI XNET USB 8502 and Bus monitor to communicate with microcontroller. I was able to send and receive messages but getting error frames now

 

Getting bus off stage when I try to send message from bus monitor. 

Getting error frames along with messages when I try to receive message

 

Receive messages on Bus monitor:

MM29_0-1727823543110.png

 

Bus statistics page for Transmitting message:

MM29_1-1727823577005.png

 

Bus statistics page for CAN transmit message:

MM29_2-1727823614073.png

 

0 Compliments
Message 1 sur 5
6 535 Visites

According to Special Frames, you are encountering with Stuff Error. This is usually caused by improper termination. My CAN Device is Failing to Communicate or is Inconsistent at High Baud Rates

Make sure your CAN network is terminated at both ends. Or you can enable the termination in USB-8502.

ZYOng_0-1727827775189.png

 

-------------------------------------------------------
Applications Engineer | TME Systems
https://tmesystems.net/
-------------------------------------------------------
https://github.com/ZhiYang-Ong
Message 2 sur 5
6 521 Visites

I have 120ohm termination and also I have enabled termination in XNET bus monitor

MM29_0-1727883798206.png

 

From Bus monitor end, I am able to receive Data frame along with Error frame but getting bus off stage when I try to transmit. 

 

0 Compliments
Message 3 sur 5
6 487 Visites
Solution
Accepté par l'auteur du sujet MM29

It is odd to see stuff bit error with the slow baud rate of 125kBaud.

Do you have another CAN adapter like PCAN-USB or Kvaser USB CAN to test if the CAN communication of your microcontroller is working correctly?

-------------------------------------------------------
Applications Engineer | TME Systems
https://tmesystems.net/
-------------------------------------------------------
https://github.com/ZhiYang-Ong
0 Compliments
Message 4 sur 5
6 474 Visites

The problem was with my XNET 8502 device, and it was resolved after replacing the device. With the same settings, I'm now able to send and receive messages successfully.

 

It's surprising that the device failed so suddenly

Message 5 sur 5
6 464 Visites