Skip to content

Commit

Permalink
Merge pull request emsesp#1257 from MichaelDvP/dev
Browse files Browse the repository at this point in the history
  • Loading branch information
proddy authored Aug 11, 2023
2 parents ac889d9 + 86737fb commit faec42a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
4 changes: 3 additions & 1 deletion src/devices/mixer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,9 @@ bool Mixer::set_pump(const char * value, const int8_t id) {
return false;
}
if (flags() == EMSdevice::EMS_DEVICE_FLAG_MM10) {
write_command(0xAC, 1, b ? 0x64 : 0, 0xAB);
// AC telegram can only be written with offset 0
uint8_t dat[2] = {flowSetTemp_, b ? (uint8_t)0x64 : (uint8_t)0};
write_command(0xAC, 0, dat, sizeof(dat), 0xAB);
return true;
}
if (flags() == EMSdevice::EMS_DEVICE_FLAG_IPM) {
Expand Down
11 changes: 6 additions & 5 deletions src/system.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1016,12 +1016,13 @@ bool System::check_restore() {
std::string settings_type = input["type"];
if (settings_type == "settings") {
// It's a settings file. Parse each section separately. If it's system related it will require a reboot
reboot_required = saveSettings(NETWORK_SETTINGS_FILE, "Network Settings", input);
reboot_required |= saveSettings(AP_SETTINGS_FILE, "AP Settings", input);
reboot_required |= saveSettings(MQTT_SETTINGS_FILE, "MQTT Settings", input);
reboot_required |= saveSettings(NTP_SETTINGS_FILE, "NTP Settings", input);
reboot_required |= saveSettings(SECURITY_SETTINGS_FILE, "Security Settings", input);
reboot_required = saveSettings(NETWORK_SETTINGS_FILE, "Network", input);
reboot_required |= saveSettings(AP_SETTINGS_FILE, "AP", input);
reboot_required |= saveSettings(MQTT_SETTINGS_FILE, "MQTT", input);
reboot_required |= saveSettings(NTP_SETTINGS_FILE, "NTP", input);
reboot_required |= saveSettings(SECURITY_SETTINGS_FILE, "Security", input);
reboot_required |= saveSettings(EMSESP_SETTINGS_FILE, "Settings", input);
reboot_required |= saveSettings(OTA_SETTINGS_FILE, "OTA", input);
} else if (settings_type == "customizations") {
// it's a customization file, just replace it and there's no need to reboot
saveSettings(EMSESP_CUSTOMIZATION_FILE, "Customizations", input);
Expand Down

0 comments on commit faec42a

Please sign in to comment.