opt/1085-optimization-and-cleanup #37

Merged
ismail merged 36 commits from opt/1085-optimization-and-cleanup into dev 2025-09-05 10:05:42 +02:00
Showing only changes of commit ae33204a87 - Show all commits

View File

@@ -516,7 +516,7 @@ static void relay_chn_tilt_execute_forward(relay_chn_tilt_ctl_t *tilt_ctl)
if (relay_chn_output_reverse(tilt_ctl->chn_ctl->output) != ESP_OK) {
ESP_LOGE(TAG, "relay_chn_tilt_execute_forward: Failed to output reverse for relay channel #%d!", tilt_ctl->chn_ctl->id);
// Stop tilting because of the error
relay_chn_tilt_dispatch_cmd(tilt_ctl, RELAY_CHN_TILT_CMD_STOP);
relay_chn_tilt_execute_stop(tilt_ctl);
return;
}
// Set the move time timer
@@ -530,7 +530,7 @@ static void relay_chn_tilt_execute_reverse(relay_chn_tilt_ctl_t *tilt_ctl)
if (relay_chn_output_forward(tilt_ctl->chn_ctl->output) != ESP_OK) {
ESP_LOGE(TAG, "relay_chn_tilt_execute_reverse: Failed to output forward for relay channel #%d!", tilt_ctl->chn_ctl->id);
// Stop tilting because of the error
relay_chn_tilt_dispatch_cmd(tilt_ctl, RELAY_CHN_TILT_CMD_STOP);
relay_chn_tilt_execute_stop(tilt_ctl);
return;
}
// Set the move time timer
@@ -545,7 +545,7 @@ static void relay_chn_tilt_execute_pause(relay_chn_tilt_ctl_t *tilt_ctl)
if (relay_chn_output_stop(tilt_ctl->chn_ctl->output) != ESP_OK) {
ESP_LOGE(TAG, "relay_chn_tilt_execute_pause: Failed to output stop for relay channel #%d!", tilt_ctl->chn_ctl->id);
// Stop tilting because of the error
relay_chn_tilt_dispatch_cmd(tilt_ctl, RELAY_CHN_TILT_CMD_STOP);
relay_chn_tilt_execute_stop(tilt_ctl);
return;
}
@@ -553,7 +553,7 @@ static void relay_chn_tilt_execute_pause(relay_chn_tilt_ctl_t *tilt_ctl)
if (relay_chn_tilt_count_update(tilt_ctl) == 0) {
ESP_LOGD(TAG, "relay_chn_tilt_execute_pause: Relay channel cannot tilt anymore");
// Stop tilting since the tilting limit has been reached
relay_chn_tilt_dispatch_cmd(tilt_ctl, RELAY_CHN_TILT_CMD_STOP);
relay_chn_tilt_execute_stop(tilt_ctl);
return;
}