Compare commits
	
		
			1 Commits
		
	
	
		
			da7a1be183
			...
			feature/wi
		
	
	| Author | SHA256 | Date | |
|---|---|---|---|
| d14ae528c0 | 
| @ -59,13 +59,18 @@ void taskControl(void *pvParameters) | ||||
|     bool bBurnerFaultDetected = false; | ||||
|     int64_t i64BurnerEnableTimestamp = esp_timer_get_time(); | ||||
|  | ||||
|     time_t now; | ||||
|  | ||||
|     while (1) | ||||
|     { | ||||
|         // Get the current time | ||||
|         time(&now); | ||||
|         ESP_LOGW(TAG, "Control loop time: %lli", now); | ||||
|         vTaskDelay(PERIODIC_INTERVAL * 1000U / portTICK_PERIOD_MS); | ||||
|  | ||||
|         if (getSafetyState() != SAFETY_NO_ERROR) | ||||
|         { | ||||
|             ESP_LOGW(TAG, "Control not possible due to safety fault!"); | ||||
|             //ESP_LOGW(TAG, "Control not possible due to safety fault!"); | ||||
|             sControlState = CONTROL_FAULT_SAFETY; | ||||
|             if (bHeatingInAction == true) | ||||
|             { | ||||
|  | ||||
| @ -189,12 +189,12 @@ void taskInput(void *pvParameters) | ||||
|  | ||||
|             if (ds18x20_scan_devices(uDS18B20Pin, uOneWireAddresses, MAX_DN18B20_SENSORS, &sSensorCount) != ESP_OK) | ||||
|             { | ||||
|                 ESP_LOGE(TAG, "1-Wire device scan error!"); | ||||
|                // ESP_LOGE(TAG, "1-Wire device scan error!"); | ||||
|             } | ||||
|  | ||||
|             if (!sSensorCount) | ||||
|             { | ||||
|                 ESP_LOGW(TAG, "No 1-Wire devices detected!"); | ||||
|                // ESP_LOGW(TAG, "No 1-Wire devices detected!"); | ||||
|             } | ||||
|             else | ||||
|             { | ||||
| @ -203,14 +203,14 @@ void taskInput(void *pvParameters) | ||||
|                 if (sSensorCount > MAX_DN18B20_SENSORS) | ||||
|                 { | ||||
|                     sSensorCount = MAX_DN18B20_SENSORS; | ||||
|                     ESP_LOGW(TAG, "More 1-Wire devices found than expected!"); | ||||
|                    // ESP_LOGW(TAG, "More 1-Wire devices found than expected!"); | ||||
|                 } | ||||
|  | ||||
|                 for (size_t iReadLoop = 0; iReadLoop < ONE_WIRE_LOOPS; iReadLoop++) | ||||
|                 { | ||||
|                     if (ds18x20_measure_and_read_multi(uDS18B20Pin, uOneWireAddresses, sSensorCount, fDS18B20Temps) != ESP_OK) | ||||
|                     { | ||||
|                         ESP_LOGE(TAG, "1-Wire devices read error"); | ||||
|                       //  ESP_LOGE(TAG, "1-Wire devices read error"); | ||||
|                         vTaskDelay(PERIODIC_INTERVAL * 100U / portTICK_PERIOD_MS); // Wait 100ms if bus error occurred | ||||
|                     } | ||||
|                     else | ||||
|  | ||||
| @ -85,7 +85,7 @@ void checkSensorSanity(void) | ||||
|  | ||||
|         if (sCurrentMeasurement.state == MEASUREMENT_FAULT) | ||||
|         { | ||||
|             ESP_LOGE(TAG, "%s Sensor not found!", sanityChecks[i].name); | ||||
|             //ESP_LOGE(TAG, "%s Sensor not found!", sanityChecks[i].name); | ||||
|             sanityChecks[i].state = SENSOR_NOT_FOUND; | ||||
|             sSafetyState = SAFETY_SENSOR_ERROR; | ||||
|         } | ||||
|  | ||||
		Reference in New Issue
	
	Block a user