 // 0% humidity (air):	575
 // 100% humidity (water): 285
 #define MIN_LEVEL 300	// 99% humidity
-#define MAX_LEVEL 550	// 1% humidity
+#define MAX_LEVEL 450	// 1% humidity
 #define LOW_LEVEL_THRESHOLD 1	// minimum threshold for the water level (=desert dry soil)
 
-int ledPins[] = {3, 4, 5, 6, 7, 8, 9, 10, 11};
-int ledArraySize = (sizeof(ledPins)/sizeof(int));
+#define BRIGHTNESS_OFF 0
+#define BRIGHTNESS_MIN 10
+#define BRIGHTNESS_MAX 150
+#define BRIGHTNESS_PIN A2
+#define BRIGHTNESS_THRESHOLD 70
 
 int sensorValue = 0;  // variable to store the value coming from the sensor
 
 int ledLevel = 0;
+CRGB smartLed[NUM_LEDS];
 
 bool blink = false;
 

	if ((unsigned long)(currentTime - flashTimer) >= FLASH_TIME_INTERVAL) {

		if (ledLevel <= LOW_LEVEL_THRESHOLD) {
			if (blink)
				setLedLevel(1);	// turn on first (red) LED
			else
				setLedLevel(0); // turn off all LEDs

			blink = !blink;
		}


// Arduino Hygrometer
// version: 1.0
// Author: Mika Hassinen

#include <FastLED.h>

// fastled defines
#define NUM_LEDS 1
#define DATA_PIN 0
#define MAX_LED_VALUE 255

// timer and sensor
#define TIME_INTERVAL 1000	// 1 second interval
#define FLASH_TIME_INTERVAL 400	// 400 ms flash interval
#define SENSOR_PIN A1		// input pin for the sensor

