Orion BMS 2 CAN Bus 0x6B0 DBC Frame Decoder (Motorola Big-Endian)

Decode Orion BMS 2 default 0x6B0 Motorola big-endian CAN telemetry (Pack Current, Instant Voltage, SOC, Relay State) with C99 & Python 3 codegen.

Jump to results

Inputs

Captured payload
Classic CAN 8 bytes or CAN FD 16 bytes. Spaces are optional.
DBC signals
Signal 1
Signal 2
Signal 3
Signal 4

Results

Estimates
Decoded signals4
Pack Current
45 A
Pack Inst Voltage
352 V
Pack SOC
82.5 %
Relay State
3
Bit map · 64 bits
B0 · 01B1 · C2B2 · 0DB3 · C0B4 · A5B5 · 03B6 · 00B7 · 0076543210 Bit 7 = 0 · Pack Current 0 Bit 6 = 0 · Pack Current 0 Bit 5 = 0 · Pack Current 0 Bit 4 = 0 · Pack Current 0 Bit 3 = 0 · Pack Current 0 Bit 2 = 0 · Pack Current 0 Bit 1 = 0 · Pack Current 0 Bit 0 = 1 · Pack Current 1 Bit 15 = 1 · Pack Current 1 Bit 14 = 1 · Pack Current 1 Bit 13 = 0 · Pack Current 0 Bit 12 = 0 · Pack Current 0 Bit 11 = 0 · Pack Current 0 Bit 10 = 0 · Pack Current 0 Bit 9 = 1 · Pack Current 1 Bit 8 = 0 · Pack Current 0 Bit 23 = 0 · Pack Inst Voltage 0 Bit 22 = 0 · Pack Inst Voltage 0 Bit 21 = 0 · Pack Inst Voltage 0 Bit 20 = 0 · Pack Inst Voltage 0 Bit 19 = 1 · Pack Inst Voltage 1 Bit 18 = 1 · Pack Inst Voltage 1 Bit 17 = 0 · Pack Inst Voltage 0 Bit 16 = 1 · Pack Inst Voltage 1 Bit 31 = 1 · Pack Inst Voltage 1 Bit 30 = 1 · Pack Inst Voltage 1 Bit 29 = 0 · Pack Inst Voltage 0 Bit 28 = 0 · Pack Inst Voltage 0 Bit 27 = 0 · Pack Inst Voltage 0 Bit 26 = 0 · Pack Inst Voltage 0 Bit 25 = 0 · Pack Inst Voltage 0 Bit 24 = 0 · Pack Inst Voltage 0 Bit 39 = 1 · Pack SOC 1 Bit 38 = 0 · Pack SOC 0 Bit 37 = 1 · Pack SOC 1 Bit 36 = 0 · Pack SOC 0 Bit 35 = 0 · Pack SOC 0 Bit 34 = 1 · Pack SOC 1 Bit 33 = 0 · Pack SOC 0 Bit 32 = 1 · Pack SOC 1 Bit 47 = 0 · Relay State 0 Bit 46 = 0 · Relay State 0 Bit 45 = 0 · Relay State 0 Bit 44 = 0 · Relay State 0 Bit 43 = 0 · Relay State 0 Bit 42 = 0 · Relay State 0 Bit 41 = 1 · Relay State 1 Bit 40 = 1 · Relay State 1 Bit 55 = 0 · unassigned 0 Bit 54 = 0 · unassigned 0 Bit 53 = 0 · unassigned 0 Bit 52 = 0 · unassigned 0 Bit 51 = 0 · unassigned 0 Bit 50 = 0 · unassigned 0 Bit 49 = 0 · unassigned 0 Bit 48 = 0 · unassigned 0 Bit 63 = 0 · unassigned 0 Bit 62 = 0 · unassigned 0 Bit 61 = 0 · unassigned 0 Bit 60 = 0 · unassigned 0 Bit 59 = 0 · unassigned 0 Bit 58 = 0 · unassigned 0 Bit 57 = 0 · unassigned 0 Bit 56 = 0 · unassigned 0

Select a bit to see its position and matching signals.

  • Pack Current
  • Pack Inst Voltage
  • Pack SOC
  • Relay State

An asterisk marks an overlapping bit.

Decoded signal values
SignalEncodingRaw integerRaw hexPhysical
Pack CurrentMotorola4500x1C245 A
Pack Inst VoltageMotorola35200xDC0352 V
Pack SOCMotorola1650xA582.5 %
Relay StateMotorola30x33
Generated C99 masks and functions
#include <stdint.h>

/* Pass a validated payload of at least 8 bytes. */
#define DBC_BIT(data, b) ((uint64_t)(((data)[(b) / 8] >> ((b) % 8)) & 1u))

#define DBC_1_PACK_CURRENT_MASK UINT64_C(0xFFFF)
#define DBC_1_PACK_CURRENT_RAW(data) (( \
    (DBC_BIT((data), 8) << 0) | \
    (DBC_BIT((data), 9) << 1) | \
    (DBC_BIT((data), 10) << 2) | \
    (DBC_BIT((data), 11) << 3) | \
    (DBC_BIT((data), 12) << 4) | \
    (DBC_BIT((data), 13) << 5) | \
    (DBC_BIT((data), 14) << 6) | \
    (DBC_BIT((data), 15) << 7) | \
    (DBC_BIT((data), 0) << 8) | \
    (DBC_BIT((data), 1) << 9) | \
    (DBC_BIT((data), 2) << 10) | \
    (DBC_BIT((data), 3) << 11) | \
    (DBC_BIT((data), 4) << 12) | \
    (DBC_BIT((data), 5) << 13) | \
    (DBC_BIT((data), 6) << 14) | \
    (DBC_BIT((data), 7) << 15) \
) & DBC_1_PACK_CURRENT_MASK)
static inline double dbc_1_pack_current_physical(const uint8_t data[static 8]) {
    const uint64_t raw = DBC_1_PACK_CURRENT_RAW(data);
    const int64_t value = raw & (UINT64_C(1) << 15)
        ? -INT64_C(1) - (int64_t)(DBC_1_PACK_CURRENT_MASK ^ raw) : (int64_t)raw;
    return (double)value * (0.1) + (0.0);
}

#define DBC_2_PACK_INST_VOLTAGE_MASK UINT64_C(0xFFFF)
#define DBC_2_PACK_INST_VOLTAGE_RAW(data) (( \
    (DBC_BIT((data), 24) << 0) | \
    (DBC_BIT((data), 25) << 1) | \
    (DBC_BIT((data), 26) << 2) | \
    (DBC_BIT((data), 27) << 3) | \
    (DBC_BIT((data), 28) << 4) | \
    (DBC_BIT((data), 29) << 5) | \
    (DBC_BIT((data), 30) << 6) | \
    (DBC_BIT((data), 31) << 7) | \
    (DBC_BIT((data), 16) << 8) | \
    (DBC_BIT((data), 17) << 9) | \
    (DBC_BIT((data), 18) << 10) | \
    (DBC_BIT((data), 19) << 11) | \
    (DBC_BIT((data), 20) << 12) | \
    (DBC_BIT((data), 21) << 13) | \
    (DBC_BIT((data), 22) << 14) | \
    (DBC_BIT((data), 23) << 15) \
) & DBC_2_PACK_INST_VOLTAGE_MASK)
static inline double dbc_2_pack_inst_voltage_physical(const uint8_t data[static 8]) {
    const uint64_t raw = DBC_2_PACK_INST_VOLTAGE_RAW(data);
    const uint64_t value = raw;
    return (double)value * (0.1) + (0.0);
}

#define DBC_3_PACK_SOC_MASK UINT64_C(0xFF)
#define DBC_3_PACK_SOC_RAW(data) (( \
    (DBC_BIT((data), 32) << 0) | \
    (DBC_BIT((data), 33) << 1) | \
    (DBC_BIT((data), 34) << 2) | \
    (DBC_BIT((data), 35) << 3) | \
    (DBC_BIT((data), 36) << 4) | \
    (DBC_BIT((data), 37) << 5) | \
    (DBC_BIT((data), 38) << 6) | \
    (DBC_BIT((data), 39) << 7) \
) & DBC_3_PACK_SOC_MASK)
static inline double dbc_3_pack_soc_physical(const uint8_t data[static 8]) {
    const uint64_t raw = DBC_3_PACK_SOC_RAW(data);
    const uint64_t value = raw;
    return (double)value * (0.5) + (0.0);
}

#define DBC_4_RELAY_STATE_MASK UINT64_C(0xFF)
#define DBC_4_RELAY_STATE_RAW(data) (( \
    (DBC_BIT((data), 40) << 0) | \
    (DBC_BIT((data), 41) << 1) | \
    (DBC_BIT((data), 42) << 2) | \
    (DBC_BIT((data), 43) << 3) | \
    (DBC_BIT((data), 44) << 4) | \
    (DBC_BIT((data), 45) << 5) | \
    (DBC_BIT((data), 46) << 6) | \
    (DBC_BIT((data), 47) << 7) \
) & DBC_4_RELAY_STATE_MASK)
static inline double dbc_4_relay_state_physical(const uint8_t data[static 8]) {
    const uint64_t raw = DBC_4_RELAY_STATE_RAW(data);
    const uint64_t value = raw;
    return (double)value * (1.0) + (0.0);
}
Generated Python 3 decoder
# Pure Python 3 CAN decoder for a 8-byte payload.
FRAME_LEN = 8

def dbc_1_pack_current_physical(data: bytes) -> float:
    if len(data) < 8:
        raise ValueError("Expected at least 8 payload bytes")
    raw = (int.from_bytes(data[:8], "big") >> 48) & 0xFFFF
    if raw & (1 << 15):
        raw -= 1 << 16
    return raw * (0.1) + (0.0)

def dbc_2_pack_inst_voltage_physical(data: bytes) -> float:
    if len(data) < 8:
        raise ValueError("Expected at least 8 payload bytes")
    raw = (int.from_bytes(data[:8], "big") >> 32) & 0xFFFF
    return raw * (0.1) + (0.0)

def dbc_3_pack_soc_physical(data: bytes) -> float:
    if len(data) < 8:
        raise ValueError("Expected at least 8 payload bytes")
    raw = (int.from_bytes(data[:8], "big") >> 24) & 0xFF
    return raw * (0.5) + (0.0)

def dbc_4_relay_state_physical(data: bytes) -> float:
    if len(data) < 8:
        raise ValueError("Expected at least 8 payload bytes")
    raw = (int.from_bytes(data[:8], "big") >> 16) & 0xFF
    return raw * (1.0) + (0.0)

def decode_frame(data: bytes) -> dict[str, float]:
    return {
        "dbc_1_pack_current": dbc_1_pack_current_physical(data),
        "dbc_2_pack_inst_voltage": dbc_2_pack_inst_voltage_physical(data),
        "dbc_3_pack_soc": dbc_3_pack_soc_physical(data),
        "dbc_4_relay_state": dbc_4_relay_state_physical(data),
    }

Decode Orion BMS 2 default 0x6B0 Motorola big-endian EV/ESS frames

Orion BMS 2 ships with a default 0x6B0 broadcast frame using Motorola big-endian byte order: Bytes 0–1 carry signed Pack Current (0.1 A/bit, positive discharge), Bytes 2–3 carry unsigned Pack Instantaneous Voltage (0.1 V/bit), Byte 4 carries Pack SOC (0.5%/bit), and Byte 5 carries the Relay State bitmask.

In payload 01 C2 0D C0 A5 03 00 00, big-endian 0x01C2 decodes to +450 (+45.0 A), 0x0DC0 decodes to 3,520 (352.0 V EV pack), 0xA5 (165) scales to 82.5% SOC, and 0x03 indicates Discharge + Charge relays enabled.

Formulas

  • Pack Current (Motorola signed) = 0x01C2 = +450 × 0.1 = +45.0 A (0xFED4 = −30.0 A)
  • Pack Inst Voltage = 0x0DC0 = 3,520 × 0.1 = 352.0 V
  • Pack SOC = 0xA5 = 165 × 0.5 = 82.5% · Relay State = 0x03 (bits 0+1 active)

Worked example

Payload 01 C2 0D C0 A5 03 00 00 decodes via Motorola big-endian DBC bitfields to +45 A, 352 V, 82.5% SOC and Relay State 3, generating ready-to-use C99 and Python 3 unpackers.

Frequently asked questions

Does Orion BMS 2 default CAN message 0x6B0 use Intel or Motorola byte order?

Orion BMS 2 defaults to Motorola big-endian (MSB first) across its standard 0x6B0 and 0x6B1 messages, though custom CAN messages can be set to Intel little-endian in the Orion Utility.

Why is Orion BMS 2 Pack Current positive during discharge and negative during charging?

Orion follows the EV traction convention where discharge out of the battery is positive current and regenerative braking / charging into the battery is negative.

Can I import an Orion BMS 2 .dbc file directly into this decoder?

Yes—export your custom .dbc file from the Orion BMS Utility and drop it into the Local .dbc loader above to inspect every configured CAN ID locally in your browser.