ESPHome 2026.5.0b1
Loading...
Searching...
No Matches
max31855.h
Go to the documentation of this file.
1#pragma once
2
6
7#include <cinttypes>
8
9namespace esphome::max31855 {
10
12 public PollingComponent,
13 public spi::SPIDevice<spi::BIT_ORDER_MSB_FIRST, spi::CLOCK_POLARITY_HIGH,
14 spi::CLOCK_PHASE_TRAILING, spi::DATA_RATE_4MHZ> {
15 public:
16 void set_reference_sensor(sensor::Sensor *temperature_sensor) { temperature_reference_ = temperature_sensor; }
17
18 void setup() override;
19 void dump_config() override;
20
21 void update() override;
22
23 protected:
24 void read_data_();
26};
27
28} // namespace esphome::max31855
This class simplifies creating components that periodically check a state.
Definition component.h:602
sensor::Sensor * temperature_reference_
Definition max31855.h:25
void set_reference_sensor(sensor::Sensor *temperature_sensor)
Definition max31855.h:16
Base-class for all sensors.
Definition sensor.h:47
The SPIDevice is what components using the SPI will create.
Definition spi.h:429