Skip to content
Open in AI

KCAN firmware ​

KCAN is Kunhong’s USB-CAN/FD firmware for high-bandwidth, low-latency applications. It is the default firmware for Kunhong’s second-generation USB-CAN/FD devices.

Communication features ​

  • Concurrent channels. All available CAN FD channels can operate simultaneously at full bus load, with data-phase rates up to 12 Mbps. Four-channel operation with KCAN X4 requires both four-channel hardware and a firmware license that enables all four channels.
  • Error-state monitoring. Check the error state of each channel to identify which channel is experiencing communication problems.
  • Bus load measurement. View and compare bus utilization across channels.

KCAN X4 specifications ​

KCAN X4 mode; requires a device with 4 CAN interfaces and a license for this mode.

Communication capabilities ​

ParameterCapability / valueNotes
CAN channels4 CAN / CAN FD channels supportedEach channel supports transmission and reception.
Frame formats11 / 29-bit IDs; Classic CAN 0–8 B, CAN FD up to 64 BClassic RTR supported; CAN FD supports BRS enabled or disabled.
Classic CAN bit rateUp to 1 Mbit/sConfigure the bus bit rate in the host software.
CAN FD data-phase bit rateUp to 12 Mbit/sConfigure arbitration and data phases independently; use transceivers and bus wiring suitable for the selected rates.

Timestamps ​

ParameterCapability / valueNotes
Hardware receive timestampsSupportedLinux / SocketCAN can read hardware frame reception times.
Timestamp resolution (Linux / SocketCAN reception)1 µsRead the hardware timestamp field to analyze intervals between received frames.

Software and APIs ​

ParameterCapability / valueNotes
Host platformsWindows / Linux supportedUse the corresponding KCAN driver and SDK.
Software and APIkcan-bus / KCANBasic supportedFor frame transmission, reception and application development.

Windows debugging and development ​

Windows uses its built-in WinUSB driver. No separate device driver installation is required.

  • Graphical debugging. On Windows x64, use kcan-bus with a device running KCAN X4 native firmware. Select a channel and configure its nominal and data-phase bit rates to exchange frames, run transmit tasks or record traffic. Download and user guide
  • Windows application development. Use the KCANBasic API to integrate a KCAN device into your application. The library is available from the kcan-bus project. KCANBasic library and project documentation

Linux access and development ​

Use the SocketCAN Command Generator to build common interface configuration, frame transmission, reception and bus load commands.

On Linux, KCAN firmware works with the KH-UCANFD-Linux-SDK. Install its kcan driver to access each CAN channel as a SocketCAN network interface such as can0.

  • Device and channel setup. List interfaces with lskcan. Use ip link to set the nominal and CAN FD data-phase bit rates and bring up a channel. Use stable channel naming in multi-device installations.
  • Command-line traffic. Use the can-utils commands candump can0 to listen, cansend to send a single frame, and canbusload to monitor bus utilization.
  • SDK utilities. kcan_monitor displays channel status and frame rates. kcanfd_test runs transmit and receive stress tests on physically paired channels. kcan_fw_tool queries device versions and manages firmware.
  • Application APIs. With the SocketCAN C socket API, create a CAN_RAW socket, bind it to a channel with bind(), and exchange frames with read() and write(). Python applications can use the python-can SocketCAN backend.