I’ve used adapters from CANable in the past when I needed to do CAN Bus testing. Unfortunately, their adapters have not been in stock recently, so I ordered a few clones off eBay:
They appear to come installed with firmware that exposes the device as a native CAN controller (vs a serial port):
[430148.232094] gs_usb 5-3.3:1.0: Configuring for 1 interfaces
[430216.983448] usb 5-3.5: new full-speed USB device number 29 using xhci_hcd
[430217.089189] usb 5-3.5: New USB device found, idVendor=1d50, idProduct=606f, bcdDevice= 0.00
[430217.089194] usb 5-3.5: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[430217.089196] usb 5-3.5: Product: canable gs_usb
[430217.089198] usb 5-3.5: Manufacturer: canable.io
[430217.089200] usb 5-3.5: SerialNumber: 004D00324146570D20313238
[430217.095155] gs_usb 5-3.5:1.0: Configuring for 1 interfaces
[430598.396465] IPv6: ADDRCONF(NETDEV_CHANGE): can0: link becomes ready
[430599.713408] IPv6: ADDRCONF(NETDEV_CHANGE): can1: link becomes ready
[430635.640557] can: controller area network core
[430635.640604] NET: Registered PF_CAN protocol family
[430635.645971] can: raw protocol
Perhaps the CandleLight firmware?
At any rate, can0
and can1
network devices showed up and appear to work:
sudo ip link set can0 type can bitrate 1000000
sudo ip link set can1 type can bitrate 1000000
sudo ip link set up can0
sudo ip link set up can1
In one terminal:
candump can0
can0 123 [8] 01 23 45 67 89 AB CD EF
In another terminal:
cansend can1 123#0123456789abcdef