HIH-8131  00
Funktionen
Hih-8131

Funktionen

void hih_mr (void)
 Humidity and Temperature Measurement Request. Mehr ...
 
uint8_t hih_df (uint16_t *hum, uint16_t *tmp)
 Humidity and Temperature Data Fetch. Mehr ...
 
uint8_t hih_scanaddr (void)
 Scan the i2C Address, only for a Single Device on Bus. Mehr ...
 
void hih_setaddr (uint8_t addr)
 Set the i2C Address. Mehr ...
 
uint8_t hih_getrht (float *rh, float *t)
 Make a complete Measurement Cycle and convert RH in % and T in C° Mehr ...
 

Ausführliche Beschreibung

Communication with the Honeywell HumidIconTM Digital Humidity/Temperature Sensors. Use's the I2C Master library from Peter Fleury pfleu.nosp@m.ry@g.nosp@m.mx.ch http://jump.to/fleury

Example usage:

#include "hih-8131.h"
void main(void){
float hr, t;
uint8_t status = hih_getrht(&rh, &t);
if(status<0x40){ printf("RH = %f T = %f", rh, t);}
else {printf("ERROR %i,status);}
}

Dokumentation der Funktionen

uint8_t hih_df ( uint16_t *  hum,
uint16_t *  tmp 
)

Humidity and Temperature Data Fetch.

Parameter
huma Pointer to Humidity Data 14 Bit
tmpa Pointer to Temperature Data 14 Bit
Rückgabewerte
0Normal Operation
1Stale Data
2Device in Command Mode
3Not Used
uint8_t hih_getrht ( float *  rh,
float *  t 
)

Make a complete Measurement Cycle and convert RH in % and T in C°

Parameter
rha Pointer to Relativ Humidity Data in %
ta Pointer to Temperature Data in C°
Rückgabewerte
<0x40Normal Operation
0x7FStale Data
0xBFDevice in Command Mode
0xFFNot Used
void hih_mr ( void  )

Humidity and Temperature Measurement Request.

uint8_t hih_scanaddr ( void  )

Scan the i2C Address, only for a Single Device on Bus.

Rückgabe
i2c Address
void hih_setaddr ( uint8_t  addr)

Set the i2C Address.

Parameter
addri2c Address