72 float cold_junction_low_fault_threshold_deg,
73 float cold_junction_high_fault_threshold_deg,
74 float temperature_low_fault_threshold_deg,
75 float temperature_high_fault_threshold_deg,
76 void (*callback)(uint8_t type))
driver max31856 interrupt include file
uint8_t max31856_stop_continuous_read(max31856_handle_t *handle)
stop the chip reading
uint8_t max31856_set_cold_junction_high_fault_threshold(max31856_handle_t *handle, int8_t threshold)
set cold junction high fault threshold
uint8_t max31856_get_fault_status(max31856_handle_t *handle, uint8_t *status)
get fault status
uint8_t max31856_set_cold_junction_sensor(max31856_handle_t *handle, max31856_bool_t enable)
enable or disable cold junction sensor
uint8_t max31856_set_thermocouple_type(max31856_handle_t *handle, max31856_thermocouple_type_t type)
set thermocouple type
uint8_t max31856_clear_fault(max31856_handle_t *handle)
clear fault
uint8_t max31856_start_continuous_read(max31856_handle_t *handle)
start the chip reading
uint8_t max31856_set_fault_mask(max31856_handle_t *handle, max31856_fault_mask_t mask, max31856_bool_t enable)
set fault mask
uint8_t max31856_set_open_circuit_detection(max31856_handle_t *handle, max31856_open_circuit_detection_t detection)
set open circuit detection
uint8_t max31856_set_temperature_low_fault_threshold(max31856_handle_t *handle, int16_t threshold)
set temperature low fault threshold
uint8_t max31856_continuous_read(max31856_handle_t *handle, int32_t *raw, double *deg)
read data from the chip continuously
uint8_t max31856_temperature_fault_threshold_convert_to_register(max31856_handle_t *handle, float deg, int16_t *reg)
convert the temperature fault threshold to the register raw data
uint8_t max31856_read_cold_junction_temperature(max31856_handle_t *handle, int16_t *raw, double *deg)
read cold junction temperature
uint8_t max31856_deinit(max31856_handle_t *handle)
close the chip
uint8_t max31856_set_noise_rejection_filter(max31856_handle_t *handle, max31856_noise_rejection_filter_t filter)
set noise rejection filter
max31856_thermocouple_type_t
max31856 thermocouple type enumeration definition
uint8_t max31856_init(max31856_handle_t *handle)
initialize the chip
uint8_t max31856_set_cold_junction_low_fault_threshold(max31856_handle_t *handle, int8_t threshold)
set cold junction low fault threshold
struct max31856_handle_s max31856_handle_t
max31856 handle structure definition
uint8_t max31856_cold_junction_fault_threshold_convert_to_register(max31856_handle_t *handle, float deg, int8_t *reg)
convert the cold junction fault threshold to the register raw data
uint8_t max31856_set_sample_average(max31856_handle_t *handle, max31856_sample_average_t average)
set sample average
uint8_t max31856_cold_junction_temperature_offset_convert_to_register(max31856_handle_t *handle, float deg, int8_t *reg)
convert the cold junction temperature offset to the register raw data
uint8_t max31856_set_fault_mode(max31856_handle_t *handle, max31856_fault_mode_t mode)
set fault mode
uint8_t max31856_irq_handler(max31856_handle_t *handle)
irq handler
uint8_t max31856_set_cold_junction_temperature_offset(max31856_handle_t *handle, int8_t offset)
set cold junction temperature offset
uint8_t max31856_set_temperature_high_fault_threshold(max31856_handle_t *handle, int16_t threshold)
set temperature high fault threshold
@ MAX31856_FAULT_MASK_OPEN
@ MAX31856_FAULT_MASK_TCLOW
@ MAX31856_FAULT_MASK_CJHIGH
@ MAX31856_FAULT_MASK_TCHIGH
@ MAX31856_FAULT_MASK_OVUV
@ MAX31856_FAULT_MASK_CJLOW
uint8_t max31856_interrupt_init(max31856_thermocouple_type_t type, float cold_junction_low_fault_threshold_deg, float cold_junction_high_fault_threshold_deg, float temperature_low_fault_threshold_deg, float temperature_high_fault_threshold_deg, void(*callback)(uint8_t type))
interrupt example init
#define MAX31856_INTERRUPT_DEFAULT_NOISE_REJECTION_FILTER
#define MAX31856_INTERRUPT_DEFAULT_COLD_JUNCTION_TEMPERATURE_OFFSET
#define MAX31856_INTERRUPT_DEFAULT_FAULT_MODE
#define MAX31856_INTERRUPT_DEFAULT_OPEN_CIRCUIT_DETECTION
max31856 interrupt example default definition
uint8_t max31856_interrupt_deinit(void)
interrupt example deinit
uint8_t max31856_interrupt_irq_handler(void)
interrupt irq callback
uint8_t max31856_interrupt_read(double *temp_deg, uint8_t *fault)
interrupt example read the temperature
#define MAX31856_INTERRUPT_DEFAULT_SAMPLE_AVERAGE
uint8_t max31856_interrupt_read_cold_junction_temperature(double *temp_deg)
interrupt example read the cold junction temperature
uint8_t max31856_interface_spi_read(uint8_t reg, uint8_t *buf, uint16_t len)
interface spi bus read
void max31856_interface_delay_ms(uint32_t ms)
interface delay ms
uint8_t max31856_interface_spi_init(void)
interface spi bus init
void max31856_interface_debug_print(const char *const fmt,...)
interface print format data
uint8_t max31856_interface_spi_write(uint8_t reg, uint8_t *buf, uint16_t len)
interface spi bus write
uint8_t max31856_interface_spi_deinit(void)
interface spi bus deinit
#define DRIVER_MAX31856_LINK_INIT(HANDLE, STRUCTURE)
initialize max31856_handle_t structure
#define DRIVER_MAX31856_LINK_SPI_INIT(HANDLE, FUC)
link spi_init function
#define DRIVER_MAX31856_LINK_RECEIVE_CALLBACK(HANDLE, FUC)
link receive_callback function
#define DRIVER_MAX31856_LINK_DEBUG_PRINT(HANDLE, FUC)
link debug_print function
#define DRIVER_MAX31856_LINK_DELAY_MS(HANDLE, FUC)
link delay_ms function
#define DRIVER_MAX31856_LINK_SPI_READ(HANDLE, FUC)
link spi_read function
#define DRIVER_MAX31856_LINK_SPI_DEINIT(HANDLE, FUC)
link spi_deinit function
#define DRIVER_MAX31856_LINK_SPI_WRITE(HANDLE, FUC)
link spi_write function