Loading...
Searching...
No Matches
max31865_params.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2025 David Picard
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 "max31865.h"
22#include "max31865_internal.h"
23#include "max31865_lut.h"
24
25#ifdef __cplusplus
26extern "C" {
27#endif
28
33
37#ifndef MAX31865_PARAM_SPI
38# define MAX31865_PARAM_SPI (SPI_DEV(0))
39#endif
40
44#ifndef MAX31865_PARAM_CS_PIN
45# define MAX31865_PARAM_CS_PIN (GPIO_PIN(0, 5))
46#endif
47
51#ifndef MAX31865_PARAM_CFG_BYTE
52# define MAX31865_PARAM_CFG_BYTE MAX31865_CFG_VBIAS_ON | \
53 MAX31865_CFG_CONV_AUTO | \
54 MAX31865_CFG_3WIRE | \
55 MAX31865_CFG_FILTER_50HZ
56#endif
57
61#ifndef MAX31865_PARAM_TEMP_THRES_LOW
62# define MAX31865_PARAM_TEMP_THRES_LOW -19900
63#endif
64
68#ifndef MAX31865_PARAM_TEMP_THRES_HIGH
69# define MAX31865_PARAM_TEMP_THRES_HIGH 64900
70#endif
71
75#ifndef MAX31865_PARAMS
76# define MAX31865_PARAMS { \
77 .spi = MAX31865_PARAM_SPI, \
78 .cs_pin = MAX31865_PARAM_CS_PIN, \
79 .cfg_byte = MAX31865_PARAM_CFG_BYTE, \
80 .temp_low_threshold = MAX31865_PARAM_TEMP_THRES_LOW, \
81 .temp_high_threshold = MAX31865_PARAM_TEMP_THRES_HIGH, \
82 .lut = &max31865_lut, \
83 .lut_numlines = MAX31865_LUT_NUMLINES, \
84}
85#endif
89#ifndef MAX31865_SAUL_INFO
90#define MAX31865_SAUL_INFO { .name = "max31865_rtd" }
91#endif
93
101
109
110#ifdef __cplusplus
111}
112#endif
113
Internal addresses, registers and constants.
Default lookup table.
static const saul_reg_info_t max31865_saul_info[]
Allocate and configure entries to the SAUL registry.
static const max31865_params_t max31865_params[]
Configuration structs for the MAX31865 driver.
#define MAX31865_SAUL_INFO
Default SAUL info for the MAX31865 driver.
#define MAX31865_PARAMS
Default parameters for the MAX31865 driver.
SAUL registry interface definition.
Device initialization parameters.
Definition max31865.h:126
Additional data to collect for each entry.
Definition saul_reg.h:48