Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/IRMQTTServer/IRMQTTServer.h
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ const uint16_t kJsonAcStateMaxSize = 1024; // Bytes
// ----------------- End of User Configuration Section -------------------------

// Constants
#define _MY_VERSION_ "v1.7.0"
#define _MY_VERSION_ "v1.7.1"

const uint8_t kRebootTime = 15; // Seconds
const uint8_t kQuickDisplayTime = 2; // Seconds
Expand Down
13 changes: 6 additions & 7 deletions examples/IRMQTTServer/IRMQTTServer.ino
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,7 @@
* - "Middle"
* - "Low"
* - "Lowest"
* # `power_command_topic` is probably not needed for most HA configurations
* # power_command_topic: "ir_server/ac/cmnd/power"
* power_command_topic: "ir_server/ac/cmnd/power"
* mode_command_topic: "ir_server/ac/cmnd/mode"
* mode_state_topic: "ir_server/ac/stat/mode"
* temperature_command_topic: "ir_server/ac/cmnd/temp"
Expand Down Expand Up @@ -300,8 +299,7 @@
* - "Middle"
* - "Low"
* - "Lowest"
* # `power_command_topic` is probably not needed for most HA configurations
* # power_command_topic: "ir_server/ac/cmnd/power"
* power_command_topic: "ir_server/ac/cmnd/power"
* mode_command_topic: "ir_server/ac/cmnd/mode"
* mode_state_topic: "ir_server/ac/stat/mode"
* temperature_command_topic: "ir_server/ac/cmnd/temp"
Expand Down Expand Up @@ -3135,9 +3133,6 @@ bool sendClimate(const String topic_prefix, const bool retain,
#else // MQTT_CLIMATE_HA_MODE
String mode_str = IRac::opmodeToString(next.mode);
#endif // MQTT_CLIMATE_HA_MODE
// I don't know why, but the modes need to be lower case to work with
// Home Assistant & Google Home.
mode_str.toLowerCase();
#if MQTT_CLIMATE_HA_MODE
// Home Assistant want's these two bound together.
if (prev.power != next.power || prev.mode != next.mode || forceMQTT) {
Expand All @@ -3151,6 +3146,10 @@ bool sendClimate(const String topic_prefix, const bool retain,
}
if (prev.mode != next.mode || forceMQTT) {
#endif // MQTT_CLIMATE_HA_MODE
// I don't know why, but the modes need to be lower case to work with
// Home Assistant & Google Home.
mode_str.toLowerCase();

success &= sendString(topic_prefix + KEY_MODE, mode_str, retain);
diff = true;
}
Expand Down