modm API documentation
modm::ltc2984< SpiMaster, Cs >::Data Struct Reference

Public Types

enum  Status : uint8_t {
  ValidIf1 = Bit0, AdcOutOfRangeFault = Bit1, SensorUnderRangeFault = Bit2, SensorOverRangeFault = Bit3,
  CJSoftFault = Bit4, CJHardFault = Bit5, AdcHardFault = Bit6, SensorHardFault = Bit7
}
 

Public Member Functions

 MODM_FLAGS8 (Status)
 
 Data (uint32_t data)
 
uint32_t & operator= (uint32_t data)
 
bool isValid ()
 
Status getStatus () const
 
float getTemperatureFloat () const
 
int32_t getTemperatureFixed () const
 
int16_t getTemperatureInteger () const
 

Public Attributes

uint32_t data
 

Member Function Documentation

template<class SpiMaster , class Cs >
Status modm::ltc2984< SpiMaster, Cs >::Data::getStatus ( ) const
inline
Returns
status code of result
template<class SpiMaster , class Cs >
int32_t modm::ltc2984< SpiMaster, Cs >::Data::getTemperatureFixed ( ) const
inline
Returns
the temperature in the configured unit divided by 1'024
template<class SpiMaster , class Cs >
float modm::ltc2984< SpiMaster, Cs >::Data::getTemperatureFloat ( ) const
inline
Returns
the temperature as a signed float in the configured unit
template<class SpiMaster , class Cs >
int16_t modm::ltc2984< SpiMaster, Cs >::Data::getTemperatureInteger ( ) const
inline
Returns
the temperature rounded to nearest integer in the configured unit
template<class SpiMaster , class Cs >
bool modm::ltc2984< SpiMaster, Cs >::Data::isValid ( )
inline
Returns
check for a valid result

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