pub struct Temperature { /* private fields */ }Expand description
A temperature measurement from one sensor sample.
Implementations§
Source§impl Temperature
impl Temperature
Sourcepub fn to_uncalibrated_celsius(&self) -> f32
pub fn to_uncalibrated_celsius(&self) -> f32
Returns the temperature in Celsius before factory calibration.
Sourcepub fn to_celsius(&self) -> Option<f32>
pub fn to_celsius(&self) -> Option<f32>
Returns the calibrated temperature in Celsius.
Returns None if factory calibration data is unavailable.
Sourcepub fn to_fahrenheit(&self) -> Option<f32>
pub fn to_fahrenheit(&self) -> Option<f32>
Returns the calibrated temperature in Fahrenheit, if available.