Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
ad7280a.h
Go to the documentation of this file.
1 /*
2  * AD7280A Lithium Ion Battery Monitoring System
3  *
4  * Copyright 2011 Analog Devices Inc.
5  *
6  * Licensed under the GPL-2.
7  */
8 
9 #ifndef IIO_ADC_AD7280_H_
10 #define IIO_ADC_AD7280_H_
11 
12 /*
13  * TODO: struct ad7280_platform_data needs to go into include/linux/iio
14  */
15 
16 #define AD7280A_ACQ_TIME_400ns 0
17 #define AD7280A_ACQ_TIME_800ns 1
18 #define AD7280A_ACQ_TIME_1200ns 2
19 #define AD7280A_ACQ_TIME_1600ns 3
20 
21 #define AD7280A_CONV_AVG_DIS 0
22 #define AD7280A_CONV_AVG_2 1
23 #define AD7280A_CONV_AVG_4 2
24 #define AD7280A_CONV_AVG_8 3
25 
26 #define AD7280A_ALERT_REMOVE_VIN5 (1 << 2)
27 #define AD7280A_ALERT_REMOVE_VIN4_VIN5 (2 << 2)
28 #define AD7280A_ALERT_REMOVE_AUX5 (1 << 0)
29 #define AD7280A_ALERT_REMOVE_AUX4_AUX5 (2 << 0)
30 
32  unsigned acquisition_time;
36 };
37 
38 #endif /* IIO_ADC_AD7280_H_ */