 /*
   CONFIGURATION for ENDNODE PCB
-  25/04/2019
-  Version 17.0 XX
+  30/04/2019
+  Version 17.1 XX
   Author: Franco Parenti
   Url:
   Support for Arduino Fio V3, Arduino Leonardo

    else
    { //read sensors
      sensors[i][1] = analogRead(sensors[i][0]);
      //Serial.print(sensors[i][0]);
      //Serial.print(" ");
      //Serial.println(sensors[i][1]);
    }
  }


  Serial.println( msg[num]);
}

void checkAwinig()
{
  if (awning_started == true) {
    if (millis() - AWRUNTIME > awning_starttime) {
      digitalWrite(10, LOW); //Disattiva il comando (fase/neutro)
      digitalWrite(11, LOW); //disattiva led tenda 1
      digitalWrite(14, LOW); //disattiva led tenda 2
      awning_started = false;
      tone(8, 4500, 100);
    }
  }
  else if (awning_started == false) {
    if (sensors[0][1] == 1023 || sensors[1][1] == 1023) {
      digitalWrite(10, LOW); //Disattiva il comando (fase/neutro)
      digitalWrite(11, LOW); //disattiva led tenda 1
      digitalWrite(14, LOW); //disattiva led tenda 2
      tone(8, 4500, 100);
    }
  }
}
