PCAN USB FD and ISO-TP error after some transmissions

This forum covers PCAN-Linux and Linux development issues concerning our products
Post Reply
devotip
Posts: 8
Joined: Tue 31. Oct 2017, 08:38

PCAN USB FD and ISO-TP error after some transmissions

Post by devotip » Tue 31. Oct 2017, 09:30

I'm having an unexpected error after few successful transmissions.

With the following test context
adapter is not connected to anything
ubuntu 16.04 with latest updates
installed can-utils
installed iso-tp module from https://github.com/hartkopp/can-isotp

can interface init as follow
sudo ip link set can0 type can bitrate 500000
sudo ip link set can0 txqueuelen 4000
sudo ip link set up can0

have the iso-tp module available
sudo modprobe can
sudo insmod ./net/can/can-isotp.ko


Then is possible to trigger the issue with basic tools in two separate windows
isotprcv -s 123 -d 321 -l can0

echo 00 00 00 00 00 00 00 00 00 00 00 00 00 | isotpsend -s 321 -d 123 can0

the send is successful and rcv prints the data but after repeating the send an exact number of times (less then ten) the data is not received anymore. PCAN USB blinks red to signal an error.
To recover turn the interface down then up.

Having candump active shows that the last flow control frame is not followed by the data

Now two questions:
any idea of what makes the interface to miss the flow control frame and get stuck?
what is the suggested practice to to reset the interface without having to turn down and up everything

If more details are needed just ask

M.Maidhof
Support
Support
Posts: 1751
Joined: Wed 22. Sep 2010, 14:00

Re: PCAN USB FD and ISO-TP error after some transmissions

Post by M.Maidhof » Wed 1. Nov 2017, 17:31

Hi,

please connect a second CAN node with a terminated CAN cable and same baudrate settings to your PCAN-USB-FD, otherwise the PCAN-USB-FD will always run into the acknowledge errors, due to the missing ack bit. CAN needs at least two active nodes.

regards

Michael

Post Reply