67 static_assert(
sizeof(StateByteStatus) == 1,
"TelemetryStateByte0 must be 1 byte");
68 static_assert(
sizeof(StateByteFaults) == 1,
"TelemetryStateByte1 must be 1 byte");
82 static_cast<__u8
>(
apps_5v & 0xFF),
84 static_cast<__u8
>(((
apps_3v3 >> 6) & 0x0F) | ((
brake & 0x0F) << 4)),
115 static_cast<__u8
>((
motor_rpm >> 8) & 0xFF),
constexpr canid_t TELEMETRY_PEDAL_MSG
constexpr canid_t TELEMETRY_MOTOR_MSG
constexpr canid_t TELEMETRY_BMS_MSG
Enumeration definitions for the VCU.
CarStatus
Main car status state machine.
Represents the state of the car. Holds telemetry data and status, used as central data sharing struct...
TelemetryFramePedal pedal
TelemetryFrameMotor motor
Telemetry frame structure for the BMS data.
constexpr can_frame toCanFrame() const
Converts the TelemetryFrameBms to a CAN frame.
Telemetry frame structure for motor signals.
constexpr can_frame toCanFrame() const
Converts the TelemetryFrameMotor to a CAN frame.
Bitfield representation of the fault bits.
Bitfield representation of the status bits.
Telemetry frame structure for the Pedals.
constexpr can_frame toCanFrame() const
Converts the TelemetryFramePedal to a CAN frame.
Union of bits for pedal faults.
struct TelemetryFramePedal::StateByteFaults::Bits bits
Union of bits for car status besides Pedal.
struct TelemetryFramePedal::StateByteStatus::Bits bits