Si7013
[Drivers]

Collaboration diagram for Si7013:

Defines

#define SI7013_ADDR   0x82
 I2C device address for Si7013.

Functions

int Si7013_MeasureRHAndTemp (I2C_TypeDef *i2c, uint8_t addr, uint32_t *rhData, int32_t *tData)
 Reads relative humidity and temperature from a Si7013 sensor.
bool Si7013_Detect (I2C_TypeDef *i2c, uint8_t addr)
 Checks if a Si7013 is present on the I2C bus or not.

Define Documentation

#define SI7013_ADDR   0x82

I2C device address for Si7013.

Definition at line 42 of file si7013.h.


Function Documentation

bool Si7013_Detect ( I2C_TypeDef *  i2c,
uint8_t  addr 
)

Checks if a Si7013 is present on the I2C bus or not.

Parameters:
[in] i2c The I2C peripheral to use (Not used).
[in] addr The I2C address to probe.
Returns:
True if a Si7013 is detected, false otherwise.

Definition at line 147 of file si7013.c.

References I2CDRV_Transfer().

Here is the call graph for this function:

int Si7013_MeasureRHAndTemp ( I2C_TypeDef *  i2c,
uint8_t  addr,
uint32_t *  rhData,
int32_t *  tData 
)

Reads relative humidity and temperature from a Si7013 sensor.

Parameters:
[in] i2c The I2C peripheral to use.
[in] addr The I2C address of the sensor.
[out] rhData The relative humidity in percent (multiplied by 1000).
[out] tData The temperature in milli-Celsius.
Returns:
Returns zero on OK, non-zero otherwise.

Definition at line 108 of file si7013.c.

References Si7013_Measure().

Here is the call graph for this function: