| 1 | /**************************************************************************//** |
| 2 | * @file AD7175_2_regs.h |
| 3 | * @brief AD7175_2 Registers Definitions. |
| 4 | * @author dnechita ([email protected]) |
| 5 | * |
| 6 | ******************************************************************************* |
| 7 | * Copyright 2015(c) Analog Devices, Inc. |
| 8 | * |
| 9 | * All rights reserved. |
| 10 | * |
| 11 | * Redistribution and use in source and binary forms, with or without modification, |
| 12 | * are permitted provided that the following conditions are met: |
| 13 | * - Redistributions of source code must retain the above copyright |
| 14 | * notice, this list of conditions and the following disclaimer. |
| 15 | * - Redistributions in binary form must reproduce the above copyright |
| 16 | * notice, this list of conditions and the following disclaimer in |
| 17 | * the documentation and/or other materials provided with the |
| 18 | * distribution. |
| 19 | * - Neither the name of Analog Devices, Inc. nor the names of its |
| 20 | * contributors may be used to endorse or promote products derived |
| 21 | * from this software without specific prior written permission. |
| 22 | * - The use of this software may or may not infringe the patent rights |
| 23 | * of one or more patent holders. This license does not release you |
| 24 | * from the requirement that you obtain separate licenses from these |
| 25 | * patent holders to use this software. |
| 26 | * - Use of the software either in source or binary form, must be run |
| 27 | * on or directly connected to an Analog Devices Inc. component. |
| 28 | * |
| 29 | * THIS SOFTWARE IS PROVIDED BY ANALOG DEVICES "AS IS" AND ANY EXPRESS OR IMPLIED |
| 30 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, NON-INFRINGEMENT, MERCHANTABILITY |
| 31 | * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
| 32 | * IN NO EVENT SHALL ANALOG DEVICES BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 33 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
| 34 | * INTELLECTUAL PROPERTY RIGHTS, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
| 35 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
| 36 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 37 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
| 38 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 39 | ******************************************************************************/ |
| 40 | |
| 41 | #ifndef __AD7175_2_REGS_H__ |
| 42 | #define __AD7175_2_REGS_H__ |
| 43 | |
| 44 | #include "ad717x.h" |
| 45 | |
| 46 | #ifdef AD7175_2_INIT |
| 47 | /*! Array holding the info for the AD7175_2 registers - address, initial value, size */ |
| 48 | ad717x_st_reg ad7175_2_regs[] = |
| 49 | { |
| 50 | { AD717X_STATUS_REG, 0x00, 1 }, |
| 51 | { AD717X_ADCMODE_REG, 0x0000, 2 }, |
| 52 | { |
| 53 | AD717X_IFMODE_REG, |
| 54 | AD717X_IFMODE_REG_DOUT_RESET | AD717X_IFMODE_REG_CRC_EN, |
| 55 | 2 |
| 56 | }, |
| 57 | { AD717X_REGCHECK_REG, 0x0000, 3}, |
| 58 | { AD717X_DATA_REG, 0x0000, 3 }, |
| 59 | { AD717X_GPIOCON_REG, 0x0000, 2 }, |
| 60 | { AD717X_ID_REG, 0x0000, 2 }, |
| 61 | { |
| 62 | AD717X_CHMAP0_REG, |
| 63 | AD717X_CHMAP_REG_CH_EN | AD717X_CHMAP_REG_AINNEG(2), |
| 64 | 2 |
| 65 | }, |
| 66 | { AD717X_CHMAP1_REG, 0x0000, 2 }, |
| 67 | { AD717X_CHMAP2_REG, 0x0000, 2 }, |
| 68 | { AD717X_CHMAP3_REG, 0x0000, 2 }, |
| 69 | { AD717X_SETUPCON0_REG, 0x0000, 2 }, |
| 70 | { AD717X_SETUPCON1_REG, 0x0000, 2 }, |
| 71 | { AD717X_SETUPCON2_REG, 0x0000, 2 }, |
| 72 | { AD717X_SETUPCON3_REG, 0x0000, 2 }, |
| 73 | { |
| 74 | AD717X_FILTCON0_REG, |
| 75 | AD717X_FILT_CONF_REG_ENHFILT(2) | AD717X_FILT_CONF_REG_ODR(10), |
| 76 | 2 |
| 77 | }, |
| 78 | { |
| 79 | AD717X_FILTCON1_REG, |
| 80 | AD717X_FILT_CONF_REG_ENHFILT(2), |
| 81 | 2 |
| 82 | }, |
| 83 | { |
| 84 | AD717X_FILTCON2_REG, |
| 85 | AD717X_FILT_CONF_REG_ENHFILT(2), |
| 86 | 2 |
| 87 | }, |
| 88 | { |
| 89 | AD717X_FILTCON3_REG, |
| 90 | AD717X_FILT_CONF_REG_ENHFILT(2), |
| 91 | 2 |
| 92 | }, |
| 93 | { AD717X_OFFSET0_REG, 0, 3 }, |
| 94 | { AD717X_OFFSET1_REG, 0, 3 }, |
| 95 | { AD717X_OFFSET2_REG, 0, 3 }, |
| 96 | { AD717X_OFFSET3_REG, 0, 3 }, |
| 97 | { AD717X_GAIN0_REG, 0, 3 }, |
| 98 | { AD717X_GAIN1_REG, 0, 3 }, |
| 99 | { AD717X_GAIN2_REG, 0, 3 }, |
| 100 | { AD717X_GAIN3_REG, 0, 3 }, |
| 101 | }; |
| 102 | #endif |
| 103 | |
| 104 | #define AD7175_2_SLAVE_ID 1 |
| 105 | |
| 106 | #endif /*__AD7175_2_REGS_H__ */ |