 int sensor1 = 0;
 int sensor1Pin = A0;    // select the input pin for the potentiometer
 
+// HW declaration
+#define TOTAL_NUM_PINS 20
+int aiPinStates[TOTAL_NUM_PINS];
 
 EthernetUDP _udpIn;
 //char colors[8*N_PANNEL] = "#000000,#000000,#000000";
 char  retMessage[(1+1+4+1)]="0,1023";
 
 //-----------------------------------------------------------
-// Process recieved message here.... 
+// Process recieved message from the webpage here.... 
 //------------------------------------------------------------
 void processTouch(char* in) {
 

#include <string.h>
#include <sys/time.h>
#include <assert.h>


#include <syslog.h>


#include <signal.h>


#define N_PANNEL 3
IPAddress ip[N_PANNEL]; 


    loop(); // call  Arduino loop as we have taken over the execution flow :[

  }
  libwebsocket_context_destroy(context);
  closelog();
  return 0;
}

void setup()
{
  // put your setup code here, to run once:
  Serial.begin(9600);
  Serial.println("Starting WebServer");
  system("/home/root/startAP");

  // Init Galileo HW
  pinMode(led, OUTPUT);
  digitalWrite(led, LOW);

  // Init pin state variables
  for(int i=0; i<TOTAL_NUM_PINS; i++)
    aiPinStates[i] = 0;


  _udpIn.begin(3333);
  _udpIn.listen();



  Serial.println("Starting WebSocket");
  initWebsocket();  
