usb-can
usb-can copied to clipboard
Build for ubuntu 22.04
Hi,
I am trying to build this for ubuntu 22.04 but the master branch gives me the following error:
make -C /lib/modules/6.2.0-26-generic/build/ M=/home/tester/Downloads/usb-can-master(1)/usb-can-master/src/module modules /bin/sh: 1: Syntax error: "(" unexpected make: *** [Makefile:11: all] Error 2 Building userpace tools make: Nothing to be done for 'all'.
When trying to use usb-can-native-kernel-driver, gives the following error
fatal error: module/hlcan.h: No such file or directory 47 | #include "module/hlcan.h"
Please can you help me with this.
Most likely the same issue as in https://github.com/alexmohr/usb-can/issues/44
Make sure you've installed the kernel modules for your kernel. It's also likely that 6.2 is not even supported anymore as the serial interface of the kernel got a major overhaul leading to incompatibility of this module. It will require a complete rewrite of this and I did not have the time to do so.
This driver works to get values on serial monitor, https://github.com/kobolt/usb-can
But I am more interested in next step, i.e., using can0 interface
That's because the kobolt version is a standalone application and not a driver. It does not depend on kernel interfaces but runs entirely in userspace.
I started rewriting this into a native kernel driver which does not depend on the slcan Interface anymore but it's not working yet. So if you can't get it to run after installing the kernel header you won't be able to use this for the time being.
I am interested in getting this to work again but don't expect this to be implemented any time soon. Sorry ...
Ok, no problem.
I have the kernel installed. It is 6.x, which, in my case, is already installed on Ubuntu 22.04