// #include <OneWire.h>
// #include <DallasTemperature.h>
// #define ONE_WIRE_BUS 27
// #define LED_PIN_RED_UP 12
// #define LED_PIN_YELLOW_UP 14
// #define LED_PIN_GREEN 26
// #define LED_PIN_YELLOW_DOWN 25
// #define LED_PIN_RED_DOWN 33
// OneWire oneWire(ONE_WIRE_BUS);
// DallasTemperature sensors(&oneWire);
// void setup() {
// Serial.begin(9600);
// sensors.begin();
// pinMode(LED_PIN_GREEN, OUTPUT);
// pinMode(LED_PIN_YELLOW_UP, OUTPUT);
// pinMode(LED_PIN_RED_UP, OUTPUT);
// pinMode(LED_PIN_YELLOW_DOWN, OUTPUT);
// pinMode(LED_PIN_RED_DOWN, OUTPUT);
// }
// void loop() {
// sensors.requestTemperatures();
// float waterTemperatureC = sensors.getTempCByIndex(0);
// if (waterTemperatureC == -127.00) {
// Serial.println("Error reading temperature!");
// } else {
// Serial.print("Water Temperature (°C): ");
// Serial.println(waterTemperatureC);
// if (waterTemperatureC >= 28.0 && waterTemperatureC < 29.0) {
// // 28-29 degrees: Green LED on
// digitalWrite(LED_PIN_GREEN, HIGH);
// digitalWrite(LED_PIN_YELLOW_UP, LOW);
// digitalWrite(LED_PIN_RED_UP, LOW);
// digitalWrite(LED_PIN_YELLOW_DOWN, LOW);
// digitalWrite(LED_PIN_RED_DOWN, LOW);
// } else if (waterTemperatureC >= 29.0 && waterTemperatureC <= 30.0) {
// // 29-30 degrees: Green and Yellow Up LEDs on
// digitalWrite(LED_PIN_GREEN, HIGH);
// digitalWrite(LED_PIN_YELLOW_UP, HIGH);
// digitalWrite(LED_PIN_RED_UP, LOW);
// digitalWrite(LED_PIN_YELLOW_DOWN, LOW);
// digitalWrite(LED_PIN_RED_DOWN, LOW);
// } else if (waterTemperatureC > 30.0) {
// // Above 30 degrees: Green, Yellow Up, and Red Up LEDs on
// digitalWrite(LED_PIN_GREEN, HIGH);
// digitalWrite(LED_PIN_YELLOW_UP, HIGH);
// digitalWrite(LED_PIN_RED_UP, HIGH);
// digitalWrite(LED_PIN_YELLOW_DOWN, LOW);
// digitalWrite(LED_PIN_RED_DOWN, LOW);
// } else if (waterTemperatureC >= 27.0 && waterTemperatureC < 28.0) {
// // 27-28 degrees: Green and Yellow Down LEDs on
// digitalWrite(LED_PIN_GREEN, HIGH);
// digitalWrite(LED_PIN_YELLOW_UP, LOW);
// digitalWrite(LED_PIN_RED_UP, LOW);
// digitalWrite(LED_PIN_YELLOW_DOWN, HIGH);
// digitalWrite(LED_PIN_RED_DOWN, LOW);
// } else if (waterTemperatureC < 27.0) {
// // Below 27 degrees: Green, Yellow Down, and Red Down LEDs on
// digitalWrite(LED_PIN_GREEN, HIGH);
// digitalWrite(LED_PIN_YELLOW_UP, LOW);
// digitalWrite(LED_PIN_RED_UP, LOW);
// digitalWrite(LED_PIN_YELLOW_DOWN, HIGH);
// digitalWrite(LED_PIN_RED_DOWN, HIGH);
// }
// }
// delay(1000);
// }