Red Bird Racing VCU v2
 
Loading...
Searching...
No Matches
TelemetryFramePedal Struct Reference

Telemetry frame structure for the Pedals. More...

#include <CarState.hpp>

Collaboration diagram for TelemetryFramePedal:

Classes

union  StateByteFaults
 Union of bits for pedal faults. More...
 
union  StateByteStatus
 Union of bits for car status besides Pedal. More...
 

Public Member Functions

constexpr can_frame toCanFrame () const
 Converts the TelemetryFramePedal to a CAN frame.
 

Public Attributes

uint16_t apps_5v
 
uint16_t apps_3v3
 
uint16_t brake
 
uint16_t hall_sensor
 
StateByteStatus status
 
StateByteFaults faults
 

Detailed Description

Telemetry frame structure for the Pedals.

Definition at line 24 of file CarState.hpp.

Member Function Documentation

◆ toCanFrame()

constexpr can_frame TelemetryFramePedal::toCanFrame ( ) const
inlineconstexpr

Converts the TelemetryFramePedal to a CAN frame.

Returns
CAN frame representing the Pedal telemetry signals.

Definition at line 77 of file CarState.hpp.

References apps_3v3, apps_5v, brake, TelemetryFramePedal::StateByteStatus::byte, TelemetryFramePedal::StateByteFaults::byte, faults, hall_sensor, status, and TELEMETRY_PEDAL_MSG.

Referenced by Telemetry::sendPedal().

Here is the caller graph for this function:

Member Data Documentation

◆ apps_3v3

uint16_t TelemetryFramePedal::apps_3v3

ADC reading for 3.3V APPS

Definition at line 27 of file CarState.hpp.

Referenced by Pedal::checkPedalFault(), Pedal::sendFrame(), and toCanFrame().

◆ apps_5v

uint16_t TelemetryFramePedal::apps_5v

ADC reading for 5V APPS

Definition at line 26 of file CarState.hpp.

Referenced by Pedal::checkPedalFault(), Pedal::sendFrame(), and toCanFrame().

◆ brake

uint16_t TelemetryFramePedal::brake

ADC reading for brake pedal

Definition at line 28 of file CarState.hpp.

Referenced by loop(), Pedal::sendFrame(), and toCanFrame().

◆ faults

StateByteFaults TelemetryFramePedal::faults

Pedal Faults

Definition at line 71 of file CarState.hpp.

Referenced by toCanFrame(), and Pedal::update().

◆ hall_sensor

uint16_t TelemetryFramePedal::hall_sensor

ADC reading for hall sensor

Definition at line 29 of file CarState.hpp.

Referenced by loop(), and toCanFrame().

◆ status


The documentation for this struct was generated from the following file: