| ISF 2.1 Intelligent Sensing Framework for Kinetis with Processor Expert

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Data Structures | Macros | Enumerations
mpl3115.h File Reference

The mpl3115.h contains the MPL3115 Pressure sensor register definitions, access macros, and device access functions. More...

`#include "isf_types.h"`
`#include "isf.h"`
`#include "isf_devmsg.h"`
`#include "fsl_mpl3115_i2c_1D_press.h"`
Include dependency graph for mpl3115.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Data Structures
struct | mpl3115_Sensor_Specific_Reg_t
struct | mpl3115_Sensor_Specific_Settings_t

## Macros
#define | MPL3115_IIC_ADDRESS 0x60 /*MPL3115A2 Address*/
#define | MPL3115_SET_FIELD(name, val) (((val)<<MPL3115_##name##_SHIFT)&(MPL3115_##name##_MASK))
#define | MPL3115_GET_FIELD(name, val) ((val&MPL3115_##name##_MASK)>>MPL3115_##name##_SHIFT)
#define | STATUS_00_REG 0x00
#define | DR_STATUS_00_REG 0x06
#define | MPL3115_PTOW_MASK 0x80
#define | MPL3115_PTOW_SHIFT 7
#define | MPL3115_PTDR_MASK 0x08
#define | MPL3115_PTDR_SHIFT 3
#define | MPL3115_PDR_MASK 0x04
#define | MPL3115_PDR_SHIFT 2
#define | MPL3115_TDR_MASK 0x02
#define | MPL3115_TDR_SHIFT 1
#define | MPL3115_WHOAMI_VALUE 0xC4
#define | MPL3115_SYSMOD_MASK 0x01
#define | MPL3115_SYSMOD_SHIFT 0
#define | MPL3115_ACTIVE_MASK 1
#define | MPL3115_SRC_DRDY_MASK 0x80
#define | MPL3115_SRC_DRDY_SHIFT 7
#define | MPL3115_SRC_PW_MASK 0x20
#define | MPL3115_SRC_PW_SHIFT 5
#define | MPL3115_SRC_TW_MASK 0x10
#define | MPL3115_SRC_TW_SHIFT 4
#define | MPL3115_SRC_PTH_MASK 0x08
#define | MPL3115_SRC_PTH_SHIFT 3
#define | MPL3115_SRC_TTH_MASK 0x04
#define | MPL3115_SRC_TTH_SHIFT 2
#define | MPL3115_SRC_PCHG_MASK 0x02
#define | MPL3115_SRC_PCHG_SHIFT 1
#define | MPL3115_SRC_TCHG_MASK 0x01
#define | MPL3115_SRC_TCHG_SHIFT 0
#define | MPL3115_DREM_MASK 0x04
#define | MPL3115_DREM_SHIFT 2
#define | MPL3115_PDEFE_MASK 0x02
#define | MPL3115_PDEFE_SHIFT 1
#define | MPL3115_TDEFE_MASK 0x01
#define | MPL3115_TDEFE_SHIFT 0
#define | MPL3115_ALT_MASK 0x80
#define | MPL3115_ALT_SHIFT 7
#define | MPL3115_RAW_MASK 0x40
#define | MPL3115_RAW_SHIFT 6
#define | MPL3115_OS_MASK 0x38
#define | MPL3115_OS_SHIFT 3
#define | MPL3115_RST_MASK 0x04
#define | MPL3115_RST_SHIFT 2
#define | MPL3115_OST_MASK 0x02
#define | MPL3115_OST_SHIFT 1
#define | MPL3115_SBYB_MASK 0x01
#define | MPL3115_SBYB_SHIFT 0
#define | MPL3115_LOAD_OUT_MASK 0x20
#define | MPL3115_LOAD_OUT_SHIFT 5
#define | MPL3115_ALARM_SEL_MASK 0x10
#define | MPL3115_ALARM_SEL_SHIFT 4
#define | MPL3115_ST_MASK 0x0F
#define | MPL3115_ST_SHIFT 0
#define | MPL3115_IPOL1_MASK 0x20
#define | MPL3115_IPOL1_SHIFT 5
#define | MPL3115_PP_OD1_MASK 0x10
#define | MPL3115_PP_OD1_SHIFT 4
#define | MPL3115_IPOL2_MASK 0x02
#define | MPL3115_IPOL2_SHIFT 1
#define | MPL3115_PP_OD2_MASK 0x01
#define | MPL3115_PP_OD2_SHIFT 0
#define | MPL3115_INT_EN_DRDY_MASK 0x80
#define | MPL3115_INT_EN_DRDY_SHIFT 7
#define | MPL3115_INT_EN_PW_MASK 0x20
#define | MPL3115_INT_EN_PW_SHIFT 5
#define | MPL3115_INT_EN_TW_MASK 0x10
#define | MPL3115_INT_EN_TW_SHIFT 4
#define | MPL3115_INT_EN_PTH_MASK 0x08
#define | MPL3115_INT_EN_PTH_SHIFT 3
#define | MPL3115_INT_EN_TTH_MASK 0x04
#define | MPL3115_INT_EN_TTH_SHIFT 2
#define | MPL3115_INT_EN_PCHG_MASK 0x02
#define | MPL3115_INT_EN_PCHG_SHIFT 1
#define | MPL3115_INT_EN_TCHG_MASK 0x01
#define | MPL3115_INT_EN_TCHG_SHIFT 0
#define | MPL3115_INT_CFG_DRDY_MASK 0x80
#define | MPL3115_INT_CFG_DRDY_SHIFT 7
#define | MPL3115_INT_CFG_PW_MASK 0x20
#define | MPL3115_INT_CFG_PW_SHIFT 5
#define | MPL3115_INT_CFG_TW_MASK 0x10
#define | MPL3115_INT_CFG_TW_SHIFT 4
#define | MPL3115_INT_CFG_PTH_MASK 0x08
#define | MPL3115_INT_CFG_PTH_SHIFT 3
#define | MPL3115_INT_CFG_TTH_MASK 0x04
#define | MPL3115_INT_CFG_TTH_SHIFT 2
#define | MPL3115_INT_CFG_PCHG_MASK 0x02
#define | MPL3115_INT_CFG_PCHG_SHIFT 1
#define | MPL3115_INT_CFG_TCHG_MASK 0x01
#define | MPL3115_INT_CFG_TCHG_SHIFT 0

## Enumerations
enum | { MPL3115_STATUS_00 = 0, MPL3115_OUT_P_MSB, MPL3115_OUT_P_CSB, MPL3115_OUT_P_LSB, MPL3115_OUT_T_MSB, MPL3115_OUT_T_LSB, MPL3115_OUT_DR_STATUS, MPL3115_OUT_P_DELTA_MSB, MPL3115_OUT_P_DELTA_CSB, MPL3115_OUT_P_DELTA_LSB, MPL3115_OUT_T_DELTA_MSB, MPL3115_OUT_T_DELTA_LSB, MPL3115_WHO_AM_I, MPL3115_F_STATUS, MPL3115_F_DATA, MPL3115_F_SETUP, MPL3115_TIME_DLY, MPL3115_SYSMOD, MPL3115_INT_SOURCE, MPL3115_PT_DATA_CFG, MPL3115_BAR_IN_MSB, MPL3115_BAR_IN_LSB, MPL3115_P_ARM_MSB, MPL3115_P_ARM_LSB, MPL3115_T_ARM, MPL3115_P_ARM_WND_MSB, MPL3115_P_ARM_WND_LSB, MPL3115_T_ARM_WND, MPL3115_P_MIN_MSB, MPL3115_P_MIN_CSB, MPL3115_P_MIN_LSB, MPL3115_T_MIN_MSB, MPL3115_T_MIN_LSB, MPL3115_P_MAX_MSB, MPL3115_P_MAX_CSB, MPL3115_P_MAX_LSB, MPL3115_T_MAX_MSB, MPL3115_T_MAX_LSB, MPL3115_CTRL_REG1, MPL3115_CTRL_REG2, MPL3115_CTRL_REG3, MPL3115_CTRL_REG4, MPL3115_CTRL_REG5, MPL3115_OFF_P, MPL3115_OFF_T, MPL3115_OFF_H }
enum | mpl3115_status_t { MPL3115_SUCCESS, MPL3115_ERROR }

## Detailed Description

The mpl3115.h contains the MPL3115 Pressure sensor register definitions, access macros, and device access functions.

Copyright
  Copyright (c) 2014, Freescale Semiconductor, Inc.

Definition in file mpl3115.h.

## Macro Definition Documentation

#define DR_STATUS_00_REG 0x06

Definition at line 89 of file mpl3115.h.

#define MPL3115_ACTIVE_MASK 1

Definition at line 109 of file mpl3115.h.

#define MPL3115_ALARM_SEL_MASK 0x10

Definition at line 160 of file mpl3115.h.

#define MPL3115_ALARM_SEL_SHIFT 4

Definition at line 161 of file mpl3115.h.

#define MPL3115_ALT_MASK 0x80

Definition at line 142 of file mpl3115.h.

#define MPL3115_ALT_SHIFT 7

Definition at line 143 of file mpl3115.h.

#define MPL3115_DREM_MASK 0x04

Definition at line 132 of file mpl3115.h.

#define MPL3115_DREM_SHIFT 2

Definition at line 133 of file mpl3115.h.

#define MPL3115_GET_FIELD | ( |  | name,
|  |  | val
| ) |  | ((val&MPL3115_##name##_MASK)>>MPL3115_##name##_SHIFT)

Definition at line 83 of file mpl3115.h.

#define MPL3115_IIC_ADDRESS 0x60 /*MPL3115A2 Address*/

Definition at line 20 of file mpl3115.h.

#define MPL3115_INT_CFG_DRDY_MASK 0x80

Definition at line 197 of file mpl3115.h.

#define MPL3115_INT_CFG_DRDY_SHIFT 7

Definition at line 198 of file mpl3115.h.

#define MPL3115_INT_CFG_PCHG_MASK 0x02

Definition at line 207 of file mpl3115.h.

#define MPL3115_INT_CFG_PCHG_SHIFT 1

Definition at line 208 of file mpl3115.h.

#define MPL3115_INT_CFG_PTH_MASK 0x08

Definition at line 203 of file mpl3115.h.

#define MPL3115_INT_CFG_PTH_SHIFT 3

Definition at line 204 of file mpl3115.h.

#define MPL3115_INT_CFG_PW_MASK 0x20

Definition at line 199 of file mpl3115.h.

#define MPL3115_INT_CFG_PW_SHIFT 5

Definition at line 200 of file mpl3115.h.

#define MPL3115_INT_CFG_TCHG_MASK 0x01

Definition at line 209 of file mpl3115.h.

#define MPL3115_INT_CFG_TCHG_SHIFT 0

Definition at line 210 of file mpl3115.h.

#define MPL3115_INT_CFG_TTH_MASK 0x04

Definition at line 205 of file mpl3115.h.

#define MPL3115_INT_CFG_TTH_SHIFT 2

Definition at line 206 of file mpl3115.h.

#define MPL3115_INT_CFG_TW_MASK 0x10

Definition at line 201 of file mpl3115.h.

#define MPL3115_INT_CFG_TW_SHIFT 4

Definition at line 202 of file mpl3115.h.

#define MPL3115_INT_EN_DRDY_MASK 0x80

Definition at line 180 of file mpl3115.h.

#define MPL3115_INT_EN_DRDY_SHIFT 7

Definition at line 181 of file mpl3115.h.

#define MPL3115_INT_EN_PCHG_MASK 0x02

Definition at line 190 of file mpl3115.h.

#define MPL3115_INT_EN_PCHG_SHIFT 1

Definition at line 191 of file mpl3115.h.

#define MPL3115_INT_EN_PTH_MASK 0x08

Definition at line 186 of file mpl3115.h.

#define MPL3115_INT_EN_PTH_SHIFT 3

Definition at line 187 of file mpl3115.h.

#define MPL3115_INT_EN_PW_MASK 0x20

Definition at line 182 of file mpl3115.h.

#define MPL3115_INT_EN_PW_SHIFT 5

Definition at line 183 of file mpl3115.h.

#define MPL3115_INT_EN_TCHG_MASK 0x01

Definition at line 192 of file mpl3115.h.

#define MPL3115_INT_EN_TCHG_SHIFT 0

Definition at line 193 of file mpl3115.h.

#define MPL3115_INT_EN_TTH_MASK 0x04

Definition at line 188 of file mpl3115.h.

#define MPL3115_INT_EN_TTH_SHIFT 2

Definition at line 189 of file mpl3115.h.

#define MPL3115_INT_EN_TW_MASK 0x10

Definition at line 184 of file mpl3115.h.

#define MPL3115_INT_EN_TW_SHIFT 4

Definition at line 185 of file mpl3115.h.

#define MPL3115_IPOL1_MASK 0x20

Definition at line 168 of file mpl3115.h.

#define MPL3115_IPOL1_SHIFT 5

Definition at line 169 of file mpl3115.h.

#define MPL3115_IPOL2_MASK 0x02

Definition at line 172 of file mpl3115.h.

#define MPL3115_IPOL2_SHIFT 1

Definition at line 173 of file mpl3115.h.

#define MPL3115_LOAD_OUT_MASK 0x20

Definition at line 158 of file mpl3115.h.

#define MPL3115_LOAD_OUT_SHIFT 5

Definition at line 159 of file mpl3115.h.

#define MPL3115_OS_MASK 0x38

Definition at line 146 of file mpl3115.h.

#define MPL3115_OS_SHIFT 3

Definition at line 147 of file mpl3115.h.

#define MPL3115_OST_MASK 0x02

Definition at line 150 of file mpl3115.h.

#define MPL3115_OST_SHIFT 1

Definition at line 151 of file mpl3115.h.

#define MPL3115_PDEFE_MASK 0x02

Definition at line 134 of file mpl3115.h.

#define MPL3115_PDEFE_SHIFT 1

Definition at line 135 of file mpl3115.h.

#define MPL3115_PDR_MASK 0x04

Definition at line 95 of file mpl3115.h.

#define MPL3115_PDR_SHIFT 2

Definition at line 96 of file mpl3115.h.

#define MPL3115_PP_OD1_MASK 0x10

Definition at line 170 of file mpl3115.h.

#define MPL3115_PP_OD1_SHIFT 4

Definition at line 171 of file mpl3115.h.

#define MPL3115_PP_OD2_MASK 0x01

Definition at line 174 of file mpl3115.h.

#define MPL3115_PP_OD2_SHIFT 0

Definition at line 175 of file mpl3115.h.

#define MPL3115_PTDR_MASK 0x08

Definition at line 93 of file mpl3115.h.

#define MPL3115_PTDR_SHIFT 3

Definition at line 94 of file mpl3115.h.

#define MPL3115_PTOW_MASK 0x80

Definition at line 91 of file mpl3115.h.

#define MPL3115_PTOW_SHIFT 7

Definition at line 92 of file mpl3115.h.

#define MPL3115_RAW_MASK 0x40

Definition at line 144 of file mpl3115.h.

#define MPL3115_RAW_SHIFT 6

Definition at line 145 of file mpl3115.h.

#define MPL3115_RST_MASK 0x04

Definition at line 148 of file mpl3115.h.

Referenced by mpl3115_Reset().

#define MPL3115_RST_SHIFT 2

Definition at line 149 of file mpl3115.h.

#define MPL3115_SBYB_MASK 0x01

Definition at line 152 of file mpl3115.h.

#define MPL3115_SBYB_SHIFT 0

Definition at line 153 of file mpl3115.h.

#define MPL3115_SET_FIELD | ( |  | name,
|  |  | val
| ) |  | (((val)<<MPL3115_##name##_SHIFT)&(MPL3115_##name##_MASK))

Definition at line 82 of file mpl3115.h.

Referenced by mpl3115_SetConfig().

#define MPL3115_SRC_DRDY_MASK 0x80

Definition at line 114 of file mpl3115.h.

#define MPL3115_SRC_DRDY_SHIFT 7

Definition at line 115 of file mpl3115.h.

#define MPL3115_SRC_PCHG_MASK 0x02

Definition at line 124 of file mpl3115.h.

#define MPL3115_SRC_PCHG_SHIFT 1

Definition at line 125 of file mpl3115.h.

#define MPL3115_SRC_PTH_MASK 0x08

Definition at line 120 of file mpl3115.h.

#define MPL3115_SRC_PTH_SHIFT 3

Definition at line 121 of file mpl3115.h.

#define MPL3115_SRC_PW_MASK 0x20

Definition at line 116 of file mpl3115.h.

#define MPL3115_SRC_PW_SHIFT 5

Definition at line 117 of file mpl3115.h.

#define MPL3115_SRC_TCHG_MASK 0x01

Definition at line 126 of file mpl3115.h.

#define MPL3115_SRC_TCHG_SHIFT 0

Definition at line 127 of file mpl3115.h.

#define MPL3115_SRC_TTH_MASK 0x04

Definition at line 122 of file mpl3115.h.

#define MPL3115_SRC_TTH_SHIFT 2

Definition at line 123 of file mpl3115.h.

#define MPL3115_SRC_TW_MASK 0x10

Definition at line 118 of file mpl3115.h.

#define MPL3115_SRC_TW_SHIFT 4

Definition at line 119 of file mpl3115.h.

#define MPL3115_ST_MASK 0x0F

Definition at line 162 of file mpl3115.h.

#define MPL3115_ST_SHIFT 0

Definition at line 163 of file mpl3115.h.

#define MPL3115_SYSMOD_MASK 0x01

Definition at line 107 of file mpl3115.h.

#define MPL3115_SYSMOD_SHIFT 0

Definition at line 108 of file mpl3115.h.

#define MPL3115_TDEFE_MASK 0x01

Definition at line 136 of file mpl3115.h.

#define MPL3115_TDEFE_SHIFT 0

Definition at line 137 of file mpl3115.h.

#define MPL3115_TDR_MASK 0x02

Definition at line 97 of file mpl3115.h.

#define MPL3115_TDR_SHIFT 1

Definition at line 98 of file mpl3115.h.

#define MPL3115_WHOAMI_VALUE 0xC4

Definition at line 102 of file mpl3115.h.

Referenced by mpl3115_CheckId().

#define STATUS_00_REG 0x00

Definition at line 88 of file mpl3115.h.

## Enumeration Type Documentation

anonymous enum

Enumerator
MPL3115_STATUS_00 |
MPL3115_OUT_P_MSB |
MPL3115_OUT_P_CSB |
MPL3115_OUT_P_LSB |
MPL3115_OUT_T_MSB |
MPL3115_OUT_T_LSB |
MPL3115_OUT_DR_STATUS |
MPL3115_OUT_P_DELTA_MSB |
MPL3115_OUT_P_DELTA_CSB |
MPL3115_OUT_P_DELTA_LSB |
MPL3115_OUT_T_DELTA_MSB |
MPL3115_OUT_T_DELTA_LSB |
MPL3115_WHO_AM_I |
MPL3115_F_STATUS |
MPL3115_F_DATA |
MPL3115_F_SETUP |
MPL3115_TIME_DLY |
MPL3115_SYSMOD |
MPL3115_INT_SOURCE |
MPL3115_PT_DATA_CFG |
MPL3115_BAR_IN_MSB |
MPL3115_BAR_IN_LSB |
MPL3115_P_ARM_MSB |
MPL3115_P_ARM_LSB |
MPL3115_T_ARM |
MPL3115_P_ARM_WND_MSB |
MPL3115_P_ARM_WND_LSB |
MPL3115_T_ARM_WND |
MPL3115_P_MIN_MSB |
MPL3115_P_MIN_CSB |
MPL3115_P_MIN_LSB |
MPL3115_T_MIN_MSB |
MPL3115_T_MIN_LSB |
MPL3115_P_MAX_MSB |
MPL3115_P_MAX_CSB |
MPL3115_P_MAX_LSB |
MPL3115_T_MAX_MSB |
MPL3115_T_MAX_LSB |
MPL3115_CTRL_REG1 |
MPL3115_CTRL_REG2 |
MPL3115_CTRL_REG3 |
MPL3115_CTRL_REG4 |
MPL3115_CTRL_REG5 |
MPL3115_OFF_P |
MPL3115_OFF_T |
MPL3115_OFF_H |

Definition at line 26 of file mpl3115.h.

enum mpl3115_status_t

Enumerator
MPL3115_SUCCESS |
MPL3115_ERROR |

Definition at line 219 of file mpl3115.h.

- © Freescale Semiconductor, Inc. 2015. All Rights Reserved.