Function xensiv_pas_gas_r290_init(xensiv_pas_gas_t *, xensiv_pas_gas_interface_t, void *)
Defined in File xensiv_pas_gas_r290.h
Function Documentation
-
int32_t xensiv_pas_gas_r290_init(xensiv_pas_gas_t *dev, xensiv_pas_gas_interface_t itf, void *ctx)
Initializes the XENSIV™ PAS GAS R290 device. It initializes the dev structure, verifies the integrity of the communication layer of the serial communication interface, and checks whether the sensor is ready.
- Parameters:
dev – [inout] Pointer to a XENSIV™ PAS GAS R290 sensor device structure allocated by the user, but the init function will initialize its contents
itf – [in] Communication interface (I2C/UART)
ctx – [in] Pointer to the platform-specific specific protocol communication handler
- Returns:
XENSIV_PAS_GAS_OK if the initialization was successful; an error indicating what went wrong otherwise