7static const char *
const TAG =
"daikin.climate";
10 uint8_t remote_state[35] = {0x11, 0xDA, 0x27, 0x00, 0xC5, 0x00, 0x00, 0xD7, 0x11, 0xDA, 0x27, 0x00,
11 0x42, 0x49, 0x05, 0xA2, 0x11, 0xDA, 0x27, 0x00, 0x00, 0x00, 0x00, 0x00,
12 0x00, 0x00, 0x00, 0x06, 0x60, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00};
17 remote_state[24] = fan_speed >> 8;
18 remote_state[25] = fan_speed & 0xff;
21 for (
int i = 16; i < 34; i++) {
22 remote_state[34] += remote_state[i];
31 for (
int i = 0; i < 8; i++) {
32 for (uint8_t mask = 1; mask > 0; mask <<= 1) {
34 bool bit = remote_state[i] & mask;
43 for (
int i = 8; i < 16; i++) {
44 for (uint8_t mask = 1; mask > 0; mask <<= 1) {
46 bool bit = remote_state[i] & mask;
55 for (
int i = 16; i < 35; i++) {
56 for (uint8_t mask = 1; mask > 0; mask <<= 1) {
58 bool bit = remote_state[i] & mask;
92 return operating_mode;
134 switch (this->
mode) {
141 return temperature << 1;
152 uint8_t
mode = frame[5];
157 switch (
mode & 0xF0) {
221 for (int8_t bit = 0; bit < 8; bit++) {
228 state_frame[pos] = byte;
233 }
else if (pos == 1) {
237 }
else if (pos == 2) {
241 }
else if (pos == 3) {
245 }
else if (pos == 4) {
ClimateMode mode
The active mode of the climate device.
optional< ClimateFanMode > fan_mode
The active fan mode of the climate device.
float target_temperature
The target temperature of the climate device.
ClimateSwingMode swing_mode
The active swing mode of the climate device.
void publish_state()
Publish the state of the climate device, to be called from integrations.
bool parse_state_frame_(const uint8_t frame[])
uint8_t temperature_() const
uint8_t operation_mode_() const
uint16_t fan_speed_() const
void transmit_state() override
bool on_receive(remote_base::RemoteReceiveData data) override
value_type const & value() const
bool expect_item(uint32_t mark, uint32_t space)
void set_carrier_frequency(uint32_t carrier_frequency)
RemoteTransmitterBase * transmitter_
RemoteTransmitData * get_data()
@ CLIMATE_SWING_OFF
The swing mode is set to Off.
@ CLIMATE_SWING_HORIZONTAL
The fan mode is set to Horizontal.
@ CLIMATE_SWING_VERTICAL
The fan mode is set to Vertical.
@ CLIMATE_SWING_BOTH
The fan mode is set to Both.
@ CLIMATE_MODE_DRY
The climate device is set to dry/humidity mode.
@ CLIMATE_MODE_FAN_ONLY
The climate device only has the fan enabled, no heating or cooling is taking place.
@ CLIMATE_MODE_HEAT
The climate device is set to heat to reach the target temperature.
@ CLIMATE_MODE_COOL
The climate device is set to cool to reach the target temperature.
@ CLIMATE_MODE_HEAT_COOL
The climate device is set to heat/cool to reach the target temperature.
@ CLIMATE_MODE_OFF
The climate device is off.
@ CLIMATE_FAN_MEDIUM
The fan mode is set to Medium.
@ CLIMATE_FAN_AUTO
The fan mode is set to Auto.
@ CLIMATE_FAN_LOW
The fan mode is set to Low.
@ CLIMATE_FAN_QUIET
The fan mode is set to Quiet.
@ CLIMATE_FAN_HIGH
The fan mode is set to High.
const uint8_t DAIKIN_MODE_AUTO
const uint8_t DAIKIN_MODE_OFF
const uint8_t DAIKIN_STATE_FRAME_SIZE
const uint32_t DAIKIN_BIT_MARK
const uint8_t DAIKIN_TEMP_MIN
const uint32_t DAIKIN_IR_FREQUENCY
const uint8_t DAIKIN_FAN_4
const uint32_t DAIKIN_HEADER_MARK
const uint8_t DAIKIN_MODE_COOL
const uint8_t DAIKIN_FAN_5
const uint32_t DAIKIN_MESSAGE_SPACE
const uint32_t DAIKIN_HEADER_SPACE
const uint8_t DAIKIN_FAN_SILENT
const uint32_t DAIKIN_ZERO_SPACE
const uint8_t DAIKIN_MODE_DRY
const uint32_t DAIKIN_ONE_SPACE
const uint8_t DAIKIN_FAN_2
const uint8_t DAIKIN_MODE_ON
const uint8_t DAIKIN_FAN_1
const uint8_t DAIKIN_FAN_AUTO
const uint8_t DAIKIN_FAN_3
const uint8_t DAIKIN_TEMP_MAX
const uint8_t DAIKIN_MODE_HEAT
const uint8_t DAIKIN_MODE_FAN
Providing packet encoding functions for exchanging data with a remote host.