Skip to main content

pamoja_tmp117_init

Function pamoja_tmp117_init 

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

Checks the part is a TMP117, waits for its EEPROM to finish loading, and writes the settings with the part in shutdown.

§Arguments

  • sensor - the driver.

§Returns

PamojaStatus::Ok; PamojaStatus::InvalidArgument for a null driver; PamojaStatus::Io when the bus fails or the EEPROM never reports ready; or PamojaStatus::Codec when the device id is not a TMP117’s.

§Safety

sensor must be a live handle or null.