Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

CANopen references get lost

Hi,

I have some problems using the CANopen library on a PXI-8461 card. First some details about the setup: One CAN bus, 500kBaud with three
servo controllers and the NI CAN card connected. Upon program start three processes are started from one reentrant VI
each controlling a single servo controller. Each process will create the following references:
1x Interface object
1x SDO object
2x PDO object
Of course the configuration of these objects differ depending upon the node ID of their dedicated servo controllers.
All references are closed when program stops, last one closed is the interface object reference.
During the program is running these references are hold in a shift register and are reused when needed. In intervals of
about 250ms each process will query some status informations from its servo controller using the SDO reference.
Bus load is <2%. This setup works well most of the time, but sporadically it seems as if the CANopen references get lost.
All connections will time out, error "5378" appears accessing the CANopen VIs and the application has to be restarted.
Attached is a NI Spy log of what happens, at the end there is the abnormal API call. Also attached is "nicanErr.txt" as the
NI Spy Log refers to it.

Any help is appreciated!

Sincerely,

Swen
Download All
0 Kudos
Message 1 of 2
(6,119 Views)

It seems like you somehow messed up the references for your SDO's. At least the error indicates that.

The error indicates that a SDO process is still pending and you started another one for the same SDO reference. That could indicate bus problems or starved message IDs because of priority or just a device that is not answering. The spy log file shows the notification waiting for 17 seconds, because the driver becomes unresponsive and reports the internal error.

Could you post a small example that shows the same behavior and your way of storing the references?

And could you try going back to NI-CAN 2.5.2 ? We had some changes to the way we report notification errors in 2.6 and perhaps the older version brings some more error information earlier in the game.

 

DirkW

0 Kudos
Message 2 of 2
(6,110 Views)