From ad84bb683fea5ab1cf835ba37fa3a975fc85af3d Mon Sep 17 00:00:00 2001 From: coolneng Date: Wed, 15 Mar 2023 04:20:59 +0100 Subject: [PATCH] Change time delay and output format --- src/main.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 283c922..540ffbe 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -15,11 +15,11 @@ void setup() { } void loop() { - char buffer[100]; + char buffer[200]; int analog_val = analogRead(fc28_pin); int soil_percentage = map(analog_val, 0, 1023, 0, 100); - sprintf(buffer, "Temperature: %.2f °C Humidity: %.2f %% Soil humidity: %i %%", + sprintf(buffer, "Temperature: %.2f°C Humidity: %.2f%% Soil humidity: %i%%", dht.readTemperature(), dht.readHumidity(), soil_percentage); Serial.println(buffer); - delay(60000); + delay(30000); }