/* BOSCH Pressure Sensor Driver * * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and * may be copied, distributed, and modified under those terms. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * */ #ifndef BOSCH_BARO_H #define BOSCH_BARO_H #include /***************************************************** | sensor | chip id | 7-bit i2c address | -----------------------------------------------------| | bmp180 | 0x55 | 0x77 | *****************************************************/ /* apply low pass filter on output */ /*#define CONFIG_BMP_LOWPASS*/ /*#define CONFIG_ID_TEMPERATURE*/ /*#define CONFIG_I2C_BASIC_FUNCTION*/ #define BMP_DRIVER_VERSION "V1.2" #define BMP_DEV_NAME "bmp180" #define C_MAX_FIR_LENGTH (32) #define MAX_SENSOR_NAME (32) #define BMP_DATA_NUM 1 #define BMP_PRESSURE 0 #define BMP_BUFSIZE 128 /* common definition */ #define BMP_GET_BITSLICE(regvar, bitname)\ ((regvar & bitname##__MSK) >> bitname##__POS) #define BMP_SET_BITSLICE(regvar, bitname, val)\ ((regvar & ~bitname##__MSK) | ((val<