Outputs humidity to the serial terminal.

Dependencies:   mbed

HIH_5030.h

Committer:
atravieso
Date:
2016-04-14
Revision:
2:4edb77a5ab26
Parent:
HIH_4010.h@ 0:a8fcc4098c24

File content as of revision 2:4edb77a5ab26:



#include "mbed.h"

class HIH4010 {

public:

HIH4010(float dataPin, float supplyVoltage, float referenceVoltage);

float getSensorRH();
float getTrueRH(float temperature);
float vout();

private:
float pin; /* IO pin connected to sensor's data pin */
float vSupply; /* voltage supplying the humidity sensor */
float slope; /* value may be calculated or factory calibrated */
float zeroOffset; /* value may be calcualted or factory calibrated */
float vRef; /* analog voltage reference, in volts */

};