   tft.fillScreen(BLACK);
   
   tft.drawRect(1, 1, tft.TFTWIDTH-2, tft.TFTHEIGHT/4, YELLOW);
-  tft.drawString(6, 3, "Soil moisture level:", CYAN);
-  tft.drawString(130, 3, soilSensorPrintout, WHITE);
+  tft.drawString(6, 3, "Soil moisture:", CYAN, 2);
+  tft.drawString(170, 3, soilSensorPrintout, WHITE, 2);
 
   
   float previous = soilValues[0];

    //previous = soilValues[i];
  }
  tft.drawRect(1, tft.TFTHEIGHT/4, tft.TFTWIDTH-2, tft.TFTHEIGHT/4, YELLOW);
  tft.fillRect(0.5*button_padding, tft.TFTHEIGHT/4+0.5*button_padding, tft.TFTWIDTH-button_padding-3, tft.TFTHEIGHT/4-button_padding, GREEN);
  tft.drawString(text_left_padding, tft.TFTHEIGHT/4+35, "Water now", BLACK);
  
  tft.drawRect(1, 2*tft.TFTHEIGHT/4, tft.TFTWIDTH-2, tft.TFTHEIGHT/4, YELLOW);
  tft.drawString(6, tft.TFTHEIGHT/2+3, "Watering level:", CYAN);
  int block_size = (tft.TFTWIDTH-button_padding) / 5;
  for (int i = 0; i < watering_level; i++)
  {
    tft.fillRect(0.5*button_padding+i*block_size, 2*tft.TFTHEIGHT/4+0.5*button_padding+10, block_size-5, tft.TFTHEIGHT/4-button_padding-10, BLUE);
  }
  
  tft.drawRect(1, 3*tft.TFTHEIGHT/4, tft.TFTWIDTH-2, tft.TFTHEIGHT/4, YELLOW);
  
  if (watering_disabled)
  {
    tft.fillRect(0.5*button_padding, 3*tft.TFTHEIGHT/4+0.5*button_padding, tft.TFTWIDTH-button_padding-3, tft.TFTHEIGHT/4-button_padding, GREEN);
    tft.drawString(text_left_padding, 3*tft.TFTHEIGHT/4+35, "Enable watering", WHITE);
  } else {
    tft.fillRect(0.5*button_padding, 3*tft.TFTHEIGHT/4+0.5*button_padding, tft.TFTWIDTH-button_padding-3, tft.TFTHEIGHT/4-button_padding, RED);
    tft.drawString(text_left_padding, 3*tft.TFTHEIGHT/4+35, "Disable watering", WHITE);
  }
  
}


//#include "reg51.h"

//#define PUMP_DIRECTION_PIN 2 //Waterpump direction, connected to B_IB pin on HG7881 (L9110) Dual Channel Motor Driver Module
#define PUMP_A_PIN 2 //Waterpump speed, connected to B_IA pin on HG7881 (L9110) Dual Channel Motor Driver Module
#define PUMP_B_PIN 3
#define PWM_SLOW 50
#define PWM_FAST 200 

