Skip to content
This repository has been archived by the owner on Oct 4, 2021. It is now read-only.

Commit

Permalink
Michael's fixes for (v2) normalize command infrastructure for devices…
Browse files Browse the repository at this point in the history
… (mqtt & console) #445
  • Loading branch information
proddy committed Aug 4, 2020
1 parent e192960 commit c3d81d8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/devices/thermostat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1746,9 +1746,9 @@ void Thermostat::thermostat_cmd_mode(const char * message) {
set_mode(message, AUTO_HEATING_CIRCUIT);
}

void Thermostat::set_temperature_value(const char * value, const uint8_t id, const uint8_t mode) {
void Thermostat::set_temperature_value(const char * value, const int8_t id, const uint8_t mode) {
float f = 0;
uint8_t hc_num = (id == -1) ? DEFAULT_HEATING_CIRCUIT : id;
uint8_t hc_num = (id == -1) ? AUTO_HEATING_CIRCUIT : id;
if (Helpers::value2float(value, f)) {
set_temperature(f, mode, hc_num);
}
Expand Down
2 changes: 1 addition & 1 deletion src/devices/thermostat.h
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ class Thermostat : public EMSdevice {

// internal helper functions
void set_mode_n(const uint8_t mode, const uint8_t hc_num);
void set_temperature_value(const char * value, const uint8_t hc, const uint8_t mode);
void set_temperature_value(const char * value, const int8_t id, const uint8_t mode);
void set_temperature(const float temperature, const std::string & mode, const uint8_t hc_num);
void set_temperature(const float temperature, const uint8_t mode, const uint8_t hc_num);

Expand Down

0 comments on commit c3d81d8

Please sign in to comment.