![]() |
LibDriver MAX31865
|
driver max31865 source file More...
#include "driver_max31865.h"Go to the source code of this file.
Macros | |
| #define | CHIP_NAME "Maxim Integrated MAX31865" |
| chip information definition | |
| #define | MANUFACTURER_NAME "Maxim Integrated" |
| #define | SUPPLY_VOLTAGE_MIN 3.0f |
| #define | SUPPLY_VOLTAGE_MAX 3.6f |
| #define | MAX_CURRENT 5.75f |
| #define | TEMPERATURE_MIN -40.0f |
| #define | TEMPERATURE_MAX 85.0f |
| #define | DRIVER_VERSION 2000 |
| #define | MAX31865_REG_CONFIG 0x00 |
| chip register definition | |
| #define | MAX31865_REG_RTD_MSB 0x01 |
| #define | MAX31865_REG_RTD_LSB 0x02 |
| #define | MAX31865_REG_HIGH_FAULT_MSB 0x03 |
| #define | MAX31865_REG_HIGH_FAULT_LSB 0x04 |
| #define | MAX31865_REG_LOW_FAULT_MSB 0x05 |
| #define | MAX31865_REG_LOW_FAULT_LSB 0x06 |
| #define | MAX31865_REG_FAULT_STATUS 0x07 |
| #define | WRITE_ADDRESS_MASK 0x80 |
| calculate definition | |
| #define | RTD_A 3.9083e-3f |
| #define | RTD_B -5.775e-7f |
Functions | |
| uint8_t | max31865_init (max31865_handle_t *handle) |
| initialize the chip | |
| uint8_t | max31865_deinit (max31865_handle_t *handle) |
| close the chip | |
| uint8_t | max31865_set_filter_select (max31865_handle_t *handle, max31865_filter_select_t filter) |
| set the filter type | |
| uint8_t | max31865_get_filter_select (max31865_handle_t *handle, max31865_filter_select_t *filter) |
| get the filter type | |
| uint8_t | max31865_set_wire (max31865_handle_t *handle, max31865_wire_t wire) |
| set the pt resistor wire | |
| uint8_t | max31865_get_wire (max31865_handle_t *handle, max31865_wire_t *wire) |
| get the pt resistor wire | |
| uint8_t | max31865_set_reference_resistor (max31865_handle_t *handle, float value) |
| set the reference resistor | |
| uint8_t | max31865_get_reference_resistor (max31865_handle_t *handle, float *value) |
| get the reference resistor | |
| uint8_t | max31865_set_resistor (max31865_handle_t *handle, max31865_resistor_t resistor) |
| set the pt resistor | |
| uint8_t | max31865_get_resistor (max31865_handle_t *handle, max31865_resistor_t *resistor) |
| get the pt resistor | |
| uint8_t | max31865_set_vbias (max31865_handle_t *handle, max31865_bool_t enable) |
| set the chip vbias | |
| uint8_t | max31865_get_vbias (max31865_handle_t *handle, max31865_bool_t *enable) |
| get the chip vbias | |
| uint8_t | max31865_clear_fault_status (max31865_handle_t *handle) |
| clear all fault status | |
| uint8_t | max31865_get_fault_status (max31865_handle_t *handle, uint8_t *status) |
| get the fault status | |
| uint8_t | max31865_set_high_fault_threshold (max31865_handle_t *handle, uint16_t threshold) |
| set the high fault threshold | |
| uint8_t | max31865_get_high_fault_threshold (max31865_handle_t *handle, uint16_t *threshold) |
| get the high fault threshold | |
| uint8_t | max31865_set_low_fault_threshold (max31865_handle_t *handle, uint16_t threshold) |
| set the low fault threshold | |
| uint8_t | max31865_get_low_fault_threshold (max31865_handle_t *handle, uint16_t *threshold) |
| get the low fault threshold | |
| uint8_t | max31865_set_fault_detection_cycle_control (max31865_handle_t *handle, max31865_fault_detection_cycle_control_t control) |
| set the fault detection cycle control | |
| uint8_t | max31865_get_fault_detection_cycle_control (max31865_handle_t *handle, max31865_fault_detection_cycle_control_status_t *status) |
| get the fault detection cycle control | |
| uint8_t | max31865_single_read (max31865_handle_t *handle, uint16_t *raw, float *temp) |
| read data once | |
| uint8_t | max31865_start_continuous_read (max31865_handle_t *handle) |
| start reading | |
| uint8_t | max31865_stop_continuous_read (max31865_handle_t *handle) |
| stop reading | |
| uint8_t | max31865_continuous_read (max31865_handle_t *handle, uint16_t *raw, float *temp) |
| read data continuously | |
| uint8_t | max31865_set_reg (max31865_handle_t *handle, uint8_t reg, uint8_t value) |
| set the chip register | |
| uint8_t | max31865_get_reg (max31865_handle_t *handle, uint8_t reg, uint8_t *value) |
| get the chip register | |
| uint8_t | max31865_info (max31865_info_t *info) |
| get chip's information | |
driver max31865 source file
Copyright (c) 2015 - present LibDriver All rights reserved
The MIT License (MIT)
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
| Date | Version | Author | Description |
|---|---|---|---|
| 2021/02/22 | 2.0 | Shifeng Li | format the code |
| 2020/10/17 | 1.0 | Shifeng Li | first upload |
Definition in file driver_max31865.c.
| #define CHIP_NAME "Maxim Integrated MAX31865" |
| #define DRIVER_VERSION 2000 |
driver version
Definition at line 50 of file driver_max31865.c.
| #define MANUFACTURER_NAME "Maxim Integrated" |
manufacturer name
Definition at line 44 of file driver_max31865.c.
| #define MAX31865_REG_CONFIG 0x00 |
| #define MAX31865_REG_FAULT_STATUS 0x07 |
fault status register
Definition at line 62 of file driver_max31865.c.
| #define MAX31865_REG_HIGH_FAULT_LSB 0x04 |
high fault lsb register
Definition at line 59 of file driver_max31865.c.
| #define MAX31865_REG_HIGH_FAULT_MSB 0x03 |
high fault msb register
Definition at line 58 of file driver_max31865.c.
| #define MAX31865_REG_LOW_FAULT_LSB 0x06 |
low fault lsb register
Definition at line 61 of file driver_max31865.c.
| #define MAX31865_REG_LOW_FAULT_MSB 0x05 |
low fault msb register
Definition at line 60 of file driver_max31865.c.
| #define MAX31865_REG_RTD_LSB 0x02 |
rtd lsb register
Definition at line 57 of file driver_max31865.c.
| #define MAX31865_REG_RTD_MSB 0x01 |
rtd msb register
Definition at line 56 of file driver_max31865.c.
| #define MAX_CURRENT 5.75f |
chip max current
Definition at line 47 of file driver_max31865.c.
| #define RTD_A 3.9083e-3f |
rtd a
Definition at line 68 of file driver_max31865.c.
| #define RTD_B -5.775e-7f |
rtd b
Definition at line 69 of file driver_max31865.c.
| #define SUPPLY_VOLTAGE_MAX 3.6f |
chip max supply voltage
Definition at line 46 of file driver_max31865.c.
| #define SUPPLY_VOLTAGE_MIN 3.0f |
chip min supply voltage
Definition at line 45 of file driver_max31865.c.
| #define TEMPERATURE_MAX 85.0f |
chip max operating temperature
Definition at line 49 of file driver_max31865.c.
| #define TEMPERATURE_MIN -40.0f |
chip min operating temperature
Definition at line 48 of file driver_max31865.c.
| #define WRITE_ADDRESS_MASK 0x80 |