library for AMS ENS210 temperature and humidity sensor
Dependents: rIoTwear-temp-humid
Diff: AMS_ENS210.h
- Revision:
- 5:22b8ef3a65e1
- Parent:
- 3:3b427231e5a7
- Child:
- 6:475b764b720d
--- a/AMS_ENS210.h Thu Jan 19 11:55:39 2017 +0000 +++ b/AMS_ENS210.h Fri Jan 20 14:33:17 2017 +0000 @@ -14,25 +14,25 @@ /* Library defaults */ -#define CONFIG_TEMP_OP_MODE 0 // single shot -#define CONFIG_HUMID_OP_MODE 0 // single shot -#define CONFIG_POWER_MODE 1 // low power +#define CONFIG_TEMP_OP_MODE 0 // single shot +#define CONFIG_HUMID_OP_MODE 0 // single shot +#define CONFIG_POWER_MODE 1 // low power /* Library Constants */ -#define SLAVE_ADDR_RAW 0x43 -#define SLAVE_ADDR SLAVE_ADDR_RAW << 1 // 0x86 -#define SLAVE_ADDR_W SLAVE_ADDR -#define SLAVE_ADDR_R SLAVE_ADDR | 1 // 0x87 +#define ENS210_SLAVE_ADDR_RAW 0x43 +#define ENS210_SLAVE_ADDR ENS210_SLAVE_ADDR_RAW << 1 // 0x86 +#define ENS210_SLAVE_ADDR_W ENS210_SLAVE_ADDR +#define ENS210_SLAVE_ADDR_R ENS210_SLAVE_ADDR | 1 // 0x87 -#define SYS_CONFIG 0x10 -#define SYS_STATUS 0x11 +#define SYS_CONFIG 0x10 +#define SYS_STATUS 0x11 -#define SENS_OP_MODE 0x21 -#define SENS_START 0x22 -#define SENS_STOP 0x23 -#define SENS_STATUS 0x24 -#define SENS_TEMP 0x30 -#define SENS_HUMID 0x33 +#define SENS_OP_MODE 0x21 +#define SENS_START 0x22 +#define SENS_STOP 0x23 +#define SENS_STATUS 0x24 +#define SENS_TEMP 0x30 +#define SENS_HUMID 0x33 /** The AMS ENS210 class */