Struct can_utils::CanFrame [] [src]

pub struct CanFrame {
    pub id: u32,
    pub dlc: u8,
    pub data: [u8; 8],
    pub rtr: bool,
    pub ide: bool,
    pub reserved0: bool,
    pub reserved1: bool,
}

A low level representation of the frames that might be sent and received on a CAN bus.

This struct can represent any CAN frame, as described in the CAN specification version 2.0, published September 1991 by Bosch GmbH. They can be used for either transmission or reception.

Fields

This contains either the Base Identifier or the Extended Identifier, depending on ide.

Number of bytes in the payload.

The frame's data payload, only the first dlc bytes are valid.

True iff this frame is a Remote Transmission Request.

True iff the id field is extended (ie 29 bits long, as opposed to 11).

At the time of this writing this field isn't specified, but it can be received as either value and subsequent protocols may end up using it.

At the time of this writing this field isn't specified, but it can be received as either value and subsequent protocols may end up using it.