//if HTTP request has ended if (c == '\n') { //lets check if LED should be lighted readString.trim(); if(readString == ("GET /?L=1 HTTP/1.1") ) { //led has to be turned ON digitalWrite(ledPin, HIGH); // set the LED on