fix: increase delay in start_scale function for improved stability

This commit is contained in:
2025-08-29 18:30:58 +02:00
parent 02e31878ee
commit f0eced8585

View File

@@ -111,7 +111,7 @@ void start_scale(bool touchSensorConnected) {
scale.begin(LOADCELL_DOUT_PIN, LOADCELL_SCK_PIN); scale.begin(LOADCELL_DOUT_PIN, LOADCELL_SCK_PIN);
oledShowProgressBar(6, 7, DISPLAY_BOOT_TEXT, "Tare scale"); oledShowProgressBar(6, 7, DISPLAY_BOOT_TEXT, "Tare scale");
for (uint16_t i = 0; i < 2000; i++) { for (uint16_t i = 0; i < 3000; i++) {
yield(); yield();
vTaskDelay(pdMS_TO_TICKS(1)); vTaskDelay(pdMS_TO_TICKS(1));
esp_task_wdt_reset(); esp_task_wdt_reset();
@@ -121,7 +121,8 @@ void start_scale(bool touchSensorConnected) {
vTaskDelay(pdMS_TO_TICKS(5000)); vTaskDelay(pdMS_TO_TICKS(5000));
} }
scale.set_scale(calibrationValue); // this value is obtained by calibrating the scale with known weights; see the README for details scale.set_scale(calibrationValue);
vTaskDelay(pdMS_TO_TICKS(5000));
scale.tare(); scale.tare();
// Display Gewicht // Display Gewicht