Post a new topicPost a reply Page 1 of 1   [ 4 posts ]
Author Message
 Post subject: Connect to WiFi
PostPosted: Wed Aug 23, 2017 7:33 am 

Joined: Tue Aug 22, 2017 1:30 pm
Posts: 2
Hello,

I have tried connect to my WiFi using this the example code(complex/WiFi_basic_connection). I already change WiFi_SSID and password to my WiFi's name but somehow I could not connect to WiFi.

Do I have to change anything else in the code?

Thank you.


Top
 Profile  
 
 Post subject: Re: Connect to WiFi
PostPosted: Thu Aug 24, 2017 6:40 am 

Joined: Mon Sep 28, 2009 11:06 am
Posts: 10492
Hello Binbin,

No, you haven't. You only have to change WIFI_SSID and WIFI_PASSWORD, for example:

Code:
if (sendATcommand("AT+CWJAP=\"My_wifi_name\",\"f23sd34fdx\"", "OK", 20000))


Regards


Top
 Profile  
 
 Post subject: Re: Connect to WiFi
PostPosted: Thu Aug 24, 2017 10:22 am 

Joined: Tue Aug 22, 2017 1:30 pm
Posts: 2
Thank you for your reply.

I try to send some data to Cloud by using this code

if(sendATcommand("AT+CIPMUX=0" ,"OK",6000))
{
printlnMsg("AT+CIPMUX=0 OK");
}
else{
printlnMsg("AT+CIPMUX=0 Error");

}

if(sendATcommand("AT+CIPSTART=\"TCP\",\"184.106.153.149\",80", "OK", 6000))
{
printlnMsg("Connected thingspeak");
}
else{
printlnMsg("Error Connected thingspeak");

}


if(sendATcommand("AT+CIPSEND=44" ,"OK",6000))

else{
printlnMsg("Send Error");

}
if(sendATcommand("GET /update?key=U7R3OO17ADURT97Q&field=15" ,"OK",6000))"
}


Somehow I can not update my cloud.

Sincere


Top
 Profile  
 
 Post subject: Re: Connect to WiFi
PostPosted: Fri Aug 25, 2017 6:58 am 

Joined: Mon Sep 28, 2009 11:06 am
Posts: 10492
Hello Binbin,

As you can read here:
http://bbs.espressif.com/viewtopic.php?t=1115

Quote:
Please notice that the new line (0x0d 0x0a) is necessary in GET request.


Regards


Top
 Profile  
 
Display posts from previous:  Sort by  
Post a new topicPost a reply Page 1 of 1   [ 4 posts ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:


Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Libelium theme based on 610nm Style by Daniel St. Jules of http://www.gamexe.net


© Libelium Comunicaciones Distribuidas S.L. | Terms of use.