Toggle navigation
Documentation
The friendly Operating System for the Internet of Things
tsl2561_params.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2017 Inria
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
19
#ifndef TSL2561_PARAMS_H
20
#define TSL2561_PARAMS_H
21
22
#include "board.h"
23
#include "
saul_reg.h
"
24
#include "
tsl2561.h
"
25
26
#ifdef __cplusplus
27
extern
"C"
{
28
#endif
29
34
#ifndef TSL2561_PARAM_I2C_DEV
35
#define TSL2561_PARAM_I2C_DEV I2C_DEV(0)
36
#endif
37
#ifndef TSL2561_PARAM_ADDR
38
#define TSL2561_PARAM_ADDR TSL2561_ADDR_FLOAT
39
#endif
40
#ifndef TSL2561_PARAM_GAIN
41
#define TSL2561_PARAM_GAIN TSL2561_GAIN_1X
42
#endif
43
#ifndef TSL2561_PARAM_INTEGRATION
44
#define TSL2561_PARAM_INTEGRATION TSL2561_INTEGRATIONTIME_402MS
45
#endif
46
47
#ifndef TSL2561_PARAMS
48
#define TSL2561_PARAMS { .i2c_dev = TSL2561_PARAM_I2C_DEV, \
49
.addr = TSL2561_PARAM_ADDR, \
50
.gain = TSL2561_PARAM_GAIN, \
51
.integration = TSL2561_PARAM_INTEGRATION }
52
#endif
53
#ifndef TSL2561_SAUL_INFO
54
#define TSL2561_SAUL_INFO { .name= "tsl2561" }
55
#endif
56
61
static
const
tsl2561_params_t
tsl2561_params
[] =
62
{
63
TSL2561_PARAMS
64
};
65
69
saul_reg_info_t
tsl2561_saul_info
[] =
70
{
71
TSL2561_SAUL_INFO
72
};
73
74
#ifdef __cplusplus
75
}
76
#endif
77
78
#endif
/* TSL2561_PARAMS_H */
79
tsl2561_saul_info
saul_reg_info_t tsl2561_saul_info[]
Allocate and configure entries to the SAUL registry.
Definition:
tsl2561_params.h:69
saul_reg_info_t
Additional data to collect for each entry.
Definition:
saul_reg.h:49
tsl2561.h
Device driver interface for the illuminance TSL2561 sensor.
saul_reg.h
SAUL registry interface definition.
tsl2561_params_t
Device initialization parameters.
Definition:
tsl2561.h:73
tsl2561_params
static const tsl2561_params_t tsl2561_params[]
Configure TSL2561.
Definition:
tsl2561_params.h:61
Generated on Tue Nov 24 2020 19:46:51 by
1.8.17