Skip to main content

pamoja_tmp117_set_alert_limits

Function pamoja_tmp117_set_alert_limits 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn pamoja_tmp117_set_alert_limits( sensor: *mut PamojaTmp117, high_celsius: f32, low_celsius: f32, ) -> PamojaStatus
Expand description

Writes the high and low limits the part compares each result against.

§Arguments

  • sensor - the driver.
  • high_celsius - the high limit; the factory value is 192 C.
  • low_celsius - the low limit; the factory value is -256 C.

§Returns

PamojaStatus::Ok, PamojaStatus::InvalidArgument for a null driver, or PamojaStatus::Io when the bus fails.

§Safety

sensor must be a live handle or null.