Contiki 2.5
Macros | Functions
pressure-mpl115a.h File Reference

    MPL115A Pressure Sensor (Barometer) interface definitions
More...

#include "../drv/mspi-drv.h"
#include <util/delay.h>

Go to the source code of this file.

Macros

#define MPL115A_CS   4
 
#define MPL115A_PRESSURE_OUT_MSB   0x80 | (0x00 << 1)
 
#define MPL115A_PRESSURE_OUT_LSB   0x80 | (0x01 << 1)
 
#define MPL115A_TEMP_OUT_MSB   0x80 | (0x02 << 1)
 
#define MPL115A_TEMP_OUT_LSB   0x80 | (0x03 << 1)
 
#define MPL115A_COEFF_ADDR_A0_M   0x80 | (0x04 << 1)
 
#define MPL115A_COEFF_ADDR_A0_L   0x80 | (0x05 << 1)
 
#define MPL115A_COEFF_ADDR_B1_M   0x80 | (0x06 << 1)
 
#define MPL115A_COEFF_ADDR_B1_L   0x80 | (0x07 << 1)
 
#define MPL115A_COEFF_ADDR_B2_M   0x80 | (0x08 << 1)
 
#define MPL115A_COEFF_ADDR_B2_L   0x80 | (0x09 << 1)
 
#define MPL115A_COEFF_ADDR_C12_M   0x80 | (0x0A << 1)
 
#define MPL115A_COEFF_ADDR_C12_L   0x80 | (0x0B << 1)
 
#define MPL115A_COEFF_ADDR_C11_M   0x80 | (0x0C << 1)
 
#define MPL115A_COEFF_ADDR_C11_L   0x80 | (0x0D << 1)
 
#define MPL115A_COEFF_ADDR_C22_M   0x80 | (0x0E << 1)
 
#define MPL115A_COEFF_ADDR_C22_L   0x80 | (0x0F << 1)
 
#define MPL115A_START_P_CONV   (0x10 << 1)
 
#define MPL115A_START_T_CONV   (0x11 << 1)
 
#define MPL115A_START_B_CONV   (0x12 << 1)
 

Functions

void mpl115a_init (void)
 Initialize the MPL115A Pressure Sensor. More...
 
uint16_t mpl115a_get_pressure (void)
 Get raw pressure value (10Bit) More...
 
uint16_t mpl115a_get_temp (void)
 Get raw temperature value (10Bit) More...
 
uint8_t mpl115a_cmd (uint8_t reg)
 This function reads and writes from the given register of the MPL115A. More...
 

Detailed Description

    MPL115A Pressure Sensor (Barometer) interface definitions
Author
Ulf Kulau kulau.nosp@m.@ibr.nosp@m..cs.t.nosp@m.u-bs.nosp@m..de

Definition in file pressure-mpl115a.h.