Loading...
Searching...
No Matches
hm330x_params.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2021 Inria
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6#pragma once
7
17
18#include "board.h"
19#include "saul_reg.h"
20
21#include "hm330x.h"
22#include "hm330x_constants.h"
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
35#ifndef HM330X_PARAM_I2C_DEV
36#define HM330X_PARAM_I2C_DEV I2C_DEV(0)
37#endif
41#ifndef HM330X_PARAM_RESET_PIN
42#define HM330X_PARAM_RESET_PIN GPIO_UNDEF
43#endif
47#ifndef HM330X_PARAM_SET_PIN
48#define HM330X_PARAM_SET_PIN GPIO_UNDEF
49#endif
53#ifndef HM330X_SAUL_INFO
54#define HM330X_SAUL_INFO { .name = "hm330x" }
55#endif
59#ifndef HM330X_PARAMS
60#define HM330X_PARAMS { .i2c = HM330X_PARAM_I2C_DEV, \
61 .reset_pin = HM330X_PARAM_RESET_PIN, \
62 .set_pin = HM330X_PARAM_SET_PIN }
63#endif
65
70{
72};
73
77#define HM330X_NUMOF ARRAY_SIZE(hm330x_params)
78
86
90#define HM330X_INFO_NUM ARRAY_SIZE(hm330x_saul_info)
91
92#ifdef __cplusplus
93}
94#endif
95
Internal addresses, registers and constants.
static const saul_reg_info_t hm330x_saul_info[]
Additional meta information to keep in the SAUL registry.
#define HM330X_SAUL_INFO
HM330X default SAUL information.
static const hm330x_params_t hm330x_params[]
Configuration struct.
#define HM330X_PARAMS
HM330X default parameters.
SAUL registry interface definition.
Device initialization parameters.
Definition hm330x.h:79
Additional data to collect for each entry.
Definition saul_reg.h:48