NHS31xx SW API
humid_dft.h
1 /*
2  * Copyright 2018-2019 NXP
3  * This software is owned or controlled by NXP and may only be used strictly
4  * in accordance with the applicable license terms. By expressly accepting
5  * such terms or by downloading, installing, activating and/or otherwise using
6  * the software, you are agreeing that you have read, and that you agree to
7  * comply with and are bound by, such license terms. If you do not agree to
8  * be bound by the applicable license terms, then you may not retain, install,
9  * activate or otherwise use the software.
10  */
11 
22 #ifndef __HUMID_DFT_H_
23 #define __HUMID_DFT_H_
24 
25 #ifndef HUMID_CHIP_HTU21D
26 
34  #define HUMID_CHIP_HTU21D 1
35 #endif
36 
37 #ifndef HUMID_CHIP_SHTC3
38 
46  #define HUMID_CHIP_SHTC3 0
47 #endif
48 
49 #if HUMID_CHIP_HTU21D && HUMID_CHIP_SHTC3
50  #error Only one of HUMID_CHIP_HTU21D and HUMID_CHIP_SHTC3 may be set to a non-zero value.
51 #endif
52 #if !HUMID_CHIP_HTU21D && !HUMID_CHIP_SHTC3
53  #error One of HUMID_CHIP_HTU21D and HUMID_CHIP_SHTC3 must be set to a non-zero value.
54 #endif
55 
56 #ifndef HUMID_I2C_HW
57 
61  #define HUMID_I2C_HW 1
62 #endif
63 
64 #ifndef HUMID_I2C_BB
65 
71  #define HUMID_I2C_BB 0
72 #endif
73 
74 #if HUMID_I2C_HW && HUMID_I2C_BB
75  #error Only one of HUMID_I2C_HW and HUMID_I2C_BB may be set to a non-zero value.
76 #endif
77 #if !HUMID_I2C_HW && !HUMID_I2C_BB
78  #error One of HUMID_I2C_HW and HUMID_I2C_BB must be set to a non-zero value.
79 #endif
80 
81 #ifndef HUMID_POWER_PIN
82 
86  #define HUMID_POWER_PIN 6
87 #endif
88 
89 #if !HUMID_PULLUP_COUNT && !defined(HUMID_PULLUPS)
90 
95  #define HUMID_PULLUP_COUNT 0
96 
103  #define HUMID_PULLUPS NULL
104 #elif HUMID_PULLUP_COUNT && defined(HUMID_PULLUPS)
105  /* OK */
106 #else
107  #error Both HUMID_PULLUP_COUNT and HUMID_PULLUPS must be both defined or undefined.
108  #error Define HUMID_PULLUPS as an array of type uint32_t and size HUMID_PULLUP_COUNT.
109 #endif
110 
111 #endif