I2C SPI USB CAN eSPI Cable Testing View All Quick Start Guides User Manuals Software Downloads Knowledge Base Videos Case Studies App Notes White Papers Sales Support How to Order
Products Blog Sales Support Contact Search

How to Measure CAN Bus Load with the Komodo CAN Duo Interface

Published: 2019-04-25 Updated: 2026-10-09
Rena Ayeras

 

Komodo API Software can be used to create custom functions for your setup.

 

CAN bus load measures how much of the available CAN bus bandwidth is being used by network traffic. Measuring CAN bus load can help engineers determine whether a CAN network has sufficient capacity for its current traffic and whether additional messages or devices could overload the bus.

The Komodo CAN Duo Interface and Komodo Software API can be used to measure CAN bus load by capturing CAN frames over a defined period and calculating the amount of bus capacity used. This approach is useful when monitoring CAN traffic programmatically and evaluating system capacity.

What Is CAN Bus Load?

CAN bus load is the percentage of available bus bandwidth occupied by CAN traffic during a given period.

The basic calculation is:

CAN bus load (%) = used bus capacity / maximum bus capacity × 100

The maximum capacity is determined by the CAN bus bitrate. For example, a CAN bus operating at 125 kbit/s has a theoretical maximum capacity of:

125,000 bits/s

In practice, CAN frames contain more than just payload data. Frame fields, acknowledgments, , inter-frame spacing, and bit stuffing contribute to the total number of bits transmitted on the bus. As a result, measuring bus load requires accounting for the complete transmitted frames rather than only the payload bytes.

How to Measure CAN Bus Load

One way to measure CAN bus load is to capture CAN traffic over a defined time interval, determine the total number of transmitted bits, and compare that value with the bus's maximum capacity.

A longer capture period can provide a more representative measurement when CAN traffic varies over time. For example, on a 125 kbit/s CAN bus, the maximum theoretical capacity is 125,000 bits per second. The measured number of bits transmitted during the capture can then be compared with the capacity available during the same time period.

Measuring CAN Bus Load with the Komodo CAN Duo Interface

The Komodo CAN Duo Interface can monitor CAN traffic and provide packet information through the Data Center Software and the Komodo Software API. Although the API returns decoded CAN packet data rather than the raw bit stream, the captured packet information can be used to estimate CAN bus load.

The km_can_read() function returns CAN packet information, including the packet timestamp, bitrate, identifier, data length code (DLC), and other CAN information. By accumulating the captured packets and using their timestamps, it is possible to calculate the amount of bus traffic occurring during a defined interval.

CAN Bus Load Measurement with the Komodo API

A practical approach is to accumulate CAN frames during a five-second capture period and use the timestamps and packet information returned by the Komodo Software API.

The process is:

  1. Determine the CAN bus bitrate, which is included in the packet information returned by km_can_read().
  2. Call km_can_read() continuously during the capture interval.
  3. Accumulate the CAN packets returned by the Komodo interface.
  4. Record the timestamp of the first packet as t0.
  5. Record the timestamp of the last packet as t1.
  6. Calculate the total capture time based on the packet timestamps and the duration of the final packet.
  7. Determine the total number of bits represented by the captured CAN frames.
  8. Calculate the bus load by comparing the total transmitted bits with the maximum number of bits available during the capture period.

For a CAN bus operating at 125 kbit/s, the maximum available capacity during a capture period of t seconds is:

125,000 × t bits

The resulting bus load can therefore be expressed as:

CAN bus load (%) = total bits transmitted / (125,000 × t) × 100

The same calculation can be applied to other CAN bitrates by replacing 125,000 with the configured bus bitrate.

Factors That Affect CAN Bus Load Measurements

Several factors should be considered when calculating CAN bus load.

CAN Bitrate

The CAN bitrate determines the maximum theoretical number of bits that can be transmitted per second. A higher bitrate provides greater available bandwidth, while a lower bitrate reaches its capacity with less traffic.

Frame Overhead

CAN frames contain fields in addition to the application payload. These include identifiers, control information, CRC, acknowledgments, and other protocol fields. Bit stuffing can also increase the number of bits transmitted.

Because of this overhead, calculating bus load from payload bytes alone will not provide an accurate representation of the bandwidth used by the CAN bus.

Capture Duration

CAN traffic may change depending on system activity. A short capture may represent only a particular operating condition, while a longer capture can provide a better view of average bus utilization.

For systems with periodic or bursty CAN traffic, it can be useful to measure bus load during multiple operating conditions rather than relying on a single capture.

Capture Accuracy

The accuracy of a calculated bus load depends on accurately determining the number of transmitted bits and the time interval over which they were transmitted. When using a CAN interface and API, packet timestamps and CAN frame information can be used to establish the capture interval and calculate the resulting bus utilization.

Use the Komodo CAN Duo for CAN Bus Monitoring and Analysis

The Komodo CAN Duo Interface provides two independent CAN channels for monitoring and transmitting CAN traffic. With the Komodo Software API, engineers can integrate CAN communication and monitoring into custom applications and test systems.

For applications that require programmatic CAN bus monitoring, the API provides access to received CAN packets, timestamps, bitrate information, error information, and other CAN bus events. This makes it possible to build custom CAN analysis and measurement functions, including CAN bus load measurement.

For more information about CAN communication and analysis, check out our CAN protocol page for resources and FAQs. The Komodo Software API documentation provides additional information about API functions, examples, and supported programming environments when using the Komodo CAN Duo Interface.

If you have questions about measuring CAN bus load or using Total Phase CAN tools in your application, feel free to email us at sales@totalphase.com. You can also request a demo that is specific for your application.