refactor: remove redundant scale calibration checks and enhance task management
This commit is contained in:
parent
0afc543b5f
commit
3818c2c059
@ -110,6 +110,7 @@ uint8_t calibrate_scale() {
|
||||
|
||||
//vTaskSuspend(RfidReaderTask);
|
||||
vTaskDelete(RfidReaderTask);
|
||||
vTaskDelete(ScaleTask);
|
||||
pauseBambuMqttTask = true;
|
||||
pauseMainTask = 1;
|
||||
|
||||
@ -170,12 +171,6 @@ uint8_t calibrate_scale() {
|
||||
esp_task_wdt_reset();
|
||||
}
|
||||
|
||||
if (scale.wait_ready_timeout(1000))
|
||||
{
|
||||
scale.set_scale(verifyValue); // this value is obtained by calibrating the scale with known weights; see the README for details
|
||||
scale.tare();
|
||||
}
|
||||
|
||||
oledShowMessage("Calibration done");
|
||||
|
||||
for (uint16_t i = 0; i < 2000; i++) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user