Loading...
Searching...
No Matches
isl29125-internal.h
Go to the documentation of this file.
1/*
2 * Copyright 2015 Ludwig Knüpfer
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
9#pragma once
10
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
28#define ISL29125_I2C_ADDRESS 0x44
29
34#define ISL29125_ID 0x7D
36
41/* main register */
42#define ISL29125_REG_ID 0x00
43#define ISL29125_REG_RESET 0x00
44/* configuration registers */
45#define ISL29125_REG_CONF1 0x01
46#define ISL29125_REG_CONF2 0x02
47#define ISL29125_REG_CONF3 0x03
48/* interrupt mode threshold registers */
49#define ISL29125_REG_LTHLB 0x04
50#define ISL29125_REG_LTHHB 0x05
51#define ISL29125_REG_HTHLB 0x06
52#define ISL29125_REG_HTHHB 0x07
53/* status register */
54#define ISL29125_REG_STATUS 0x08
55/* sensor readout registers (double buffered) */
56#define ISL29125_REG_GDLB 0x09
57#define ISL29125_REG_GDHB 0x0A
58#define ISL29125_REG_RDLB 0x0B
59#define ISL29125_REG_RDHB 0x0C
60#define ISL29125_REG_BDLB 0x0D
61#define ISL29125_REG_BDHB 0x0E
63
68#define ISL29125_CMD_RESET 0x46
70
75/* ISL29125_REG_CONF1 B2:B0 */
76#define ISL29125_CON1_MASK_MODE 0x07
77/* ISL29125_REG_CONF1 B3 */
78#define ISL29125_CON1_MASK_RANGE 0x08
79/* ISL29125_REG_CONF1 B4 */
80#define ISL29125_CON1_MASK_RES 0x10
81/* ISL29125_REG_CONF1 B5 */
82#define ISL29125_CON1_MASK_SYNC 0x20
83#define ISL29125_CON1_SYNCOFF 0x00
84#define ISL29125_CON1_SYNCON 0x20
86
87#ifdef __cplusplus
88}
89#endif
90