Developer Blog

Detecting Overflow Conditions with CANlib

When developing software applications that rely heavily on communication protocols, one of the key concerns is that the application is handling incoming data quickly enough that messages are not dropped.  This situation could be caused by the application spending too much time processing a message,  the application is paused waiting for user interaction, or the ... Read More

Building for Raspberry Pi using distcc

Building locally on a Raspberry Pi can be slow. The most common way around this is to cross-compile, which is much quicker, but requires more setup.1 There is also a third alternative, distcc, which distributes the compilation to remote computers in a transparent manner. Setting up distcc is somewhat simpler compared to cross-compiling, but we ... Read More

Building CANlib (linuxcan) on Raspberry Pi

When compiling CANlib (linuxcan) on any Linux computer, you need to make sure that you are using the correct version of kernel header files. For example, on Ubuntu you can issue the command: sudo apt install linux-headers-$(uname -r) A Linux header package is currently not available on the Rasbian so instead you have to do some digging. It's ... Read More

Custom Channel Name

One of the new features in CANlib v5.17 is the addition of Custom Channel Name. On supported devices1, this gives you an opportunity to identify a specific device's channel. When starting Kvaser Hardware, a new row is shown as can be seen in Figure 1. We have not yet assigned any Custom Channel Name, and thus Kvaser Hardware shows ... Read More

Running Python wrapper on Linux

Today we take a look at how to setup and send a CAN message using Kvaser's new Python package canlib. For this example we use the Kvaser USBcan Pro 2xHS v2, but any Kvaser interface can be used. First step is to download and install Kvaser Linux Driver and SDK (the current version of CANlib is v5.18): $ ... Read More