can-utils icon indicating copy to clipboard operation
can-utils copied to clipboard

unable to transmit CAN frames with ixxat USB-to-CAN v2

Open josselinL69 opened this issue 1 year ago • 5 comments

Hello,

Subject : I try to set up a CAN connection between an STM32U5 and my computer using an USB-to-CAN v2.

Currently i'm able to receive data from the STM32 in my computer with candump. But when i try to send data to the STM from my computeur, there is error in communication.

I tried to send data in loopback mod in order to see sended data in candump but nothing is shown.

I have successfully installed the driver for ixxat USB-to-CAN in the kernel and there is no error when i do this command for initialization :

sudo ip link set down can0
sudo ip link set can0 type can bitrate 1000000
sudo ip link set can0 type can loopback on
sudo ip link set up can0

driver : ix_usb_can_2.0.367-MOD

here the result of ip -details link show can0 before sending data : image

here the result of ip -details link show can0 after sending data : image

Thanks per advance for any kind of help !

josselinL69 avatar Apr 24 '24 14:04 josselinL69

Which driver are you using for the USB-to-CAN v2?

marckleinebudde avatar Apr 24 '24 14:04 marckleinebudde

This is not a mainline Linux CAN driver. Please ask the authors of this driver for support.

marckleinebudde avatar Apr 24 '24 14:04 marckleinebudde

If you configure the driver for loopback mode you cannot send any data. If it's correctly implemented by the driver and USB firmware.

marckleinebudde avatar Apr 24 '24 14:04 marckleinebudde

If you device is in ERROR_PASSIVE, it's likely that the your STM has no received the data correctly.

marckleinebudde avatar Apr 24 '24 14:04 marckleinebudde

Feel free to reopen, if you have any issues.

marckleinebudde avatar May 28 '24 10:05 marckleinebudde