upm  1.3.0
Sensor/Actuator repository for libmraa (v1.7.0)
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Public Member Functions
MICSV89 Class Reference

API for the MICS-VZ89 Gas Sensor. More...

Detailed Description

The MiCS-VZ-86/89 combines state-of-the-art MOS sensor technology with intelligent detection algorithms to monitor VOCs and CO2 equivalent variations in confined spaces.

The MICSV89 comes in 4 variants, PWM and I2C in 3.3 volts and 5 volts. This library only implements the I2c version of the device.

Device output is not valid until a warm up of 15 minutes of operation.

upm::MICSV89 *sensor = new upm::MICSV89(6);
cout << "co2: " << sensor->co2equ() << endl;
cout << "short: " << sensor->vocshort() << endl;
cout << "tvoc: " << sensor->tvoc() << endl;
cout << "resistor: " << sensor->resistor() << endl;
cout << "****************************" << endl;
delete sensor;

Public Member Functions

 MICSV89 (int bus, uint8_t address=0x70)
 ~MICSV89 ()
std::string name ()
float co2equ ()
int vocshort ()
float tvoc ()
float resistor ()
void update ()
bool valid ()

Constructor & Destructor Documentation

MICSV89 ( int  bus,
uint8_t  address = 0x70 

MICSV89 constructor

busi2c bus the sensor is attached to.
addressDevice address. Default is 0x70.
~MICSV89 ( )

MICSV89 destructor

Member Function Documentation

std::string name ( )

Returns the name of the sensor

float co2equ ( )

Returns the CO2 equivalent value.

int vocshort ( )

Returns VOC Short value.

float tvoc ( )

Returns Total VOC.

float resistor ( )

Returns resistor value.

void update ( void  )

Performs a write/read cycle.

bool valid ( )

Returns true if a valid write/read cycle has been completed. At startup and during write/read cycle will be false.

The documentation for this class was generated from the following files: