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
GroveO2 Class Reference

API for the Grove O2 Oxygen Gas Sensor. More...

Detailed Description

The Grove O2 Oxygen Gas sensor measures the oxygen concentration in the air

// The was tested with the O2 Oxygen Concentration Sensor Module
// Instantiate a GroveO2 on analog pin A0
upm::GroveO2 *O2 = new upm::GroveO2(0);
while (shouldRun)
cout << "The output voltage is: " << O2->voltageValue() << "mV" << endl;

Public Member Functions

 GroveO2 (int pin)
 ~GroveO2 ()
float voltageValue ()

Constructor & Destructor Documentation

GroveO2 ( int  pin)

Grove O2 Oxygen Gas sensor constructor

pinAnalog pin to use
~GroveO2 ( )

GroveO2 destructor

Member Function Documentation

float voltageValue ( )

Measures O2 from the sensor

Oxygen concentration as voltage

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