🚌 CAN Bit Timing Calculator

Solve BRP, TSEG1, TSEG2 and SJW for a target CAN bitrate and sample point.

Peripheral clock feeding the CAN controller.
e.g. 125000, 250000, 500000, 1000000.
87.5% is the common CANopen/DeviceNet default.

How it works

A CAN bit is divided into 1 + TSEG1 + TSEG2 time quanta, each of length tq = (BRP + 1) / fCANCLK:

bitrate = fCANCLK ÷ ((BRP + 1) × (1 + TSEG1 + TSEG2))
sample point = (1 + TSEG1) ÷ (1 + TSEG1 + TSEG2) × 100%

The tool sweeps the total quanta per bit (8..25) and prescaler to find exact or near-exact bitrate matches, then splits the remaining quanta between TSEG1 and TSEG2 to land as close as possible to your target sample point. SJW (synchronization jump width) is capped at min(TSEG2, 4), the typical hardware limit.