MPL115A2 (I2C) Pressure sensor interface

Dependents:   MPL115A2Sample dataloger_for_modelrocket ARLISS2012_Hidaka

main.cpp

Committer:
yamaguch
Date:
2011-04-26
Revision:
1:b1d4ab9b1e84

File content as of revision 1:b1d4ab9b1e84:

#include "mbed.h"
#include "MPL115A2.h"

int main() {
    MPL115A2 mpl115a2(p28, p27);

    while (1) {
        printf("temperature = %3.1f degree, pressure = %d hPa\n",
               mpl115a2.readTemperature(), mpl115a2.readPressure());
        wait(1);
    }
}