Wifi ESP8266 module

after connecting to server
I use this sequence to post data to url using esp8266 wifi module
String postRequest = String("POST ");

postRequest = postRequest + uri + " HTTP/1.1\r\n" +
"Host: " + server + "\r\n" +

"Content-Type: application/json\r\n"+
"Content-Length: " + 50 + "\r\n" +
"\r\n"+data ;

delay(1000);
Serial.println("Request Sent:");
Serial.println(postRequest);
delay(1000);
Serial.println("Data Sent:");
delay(1000);
ESP826.print("AT+CIPSEND=50\r\n");
delay(1000);
while(ESP826.available())
{
Serial.write(ESP826.read());//Forward what Software Serial received to Serial Port
}
delay(1000);

Serial.println("Sending..");
delay(1000);
ESP826.print(postRequest);
delay(2000);
  while(ESP826.available()) 
    {
      Serial.write(ESP826.read());//Forward what Software Serial received to Serial Port
    }
    
delay(2000);

I got no response, anyone knows what is the wrong about this?!

Your topic has been moved. Please do not post in "Uncategorized";m see the sticky topics in Uncategorized - Arduino Forum.

Please use code tags when posting code; see How to get the best out of this forum. Please fix that.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.