[SOLVED] Starting a Network of ESP8266s
Posted: Wed Oct 14, 2015 10:22 am
Hi all
I've Started using ESP8266 for a Communicating project, I want to start a network of ESP8266s that are connected to a router (another ESP8266) and send and receive Data. Due to project circumstances i just can't use frameworksor arduino libraries, and i just can use AT commands ,but i've got stocked at the first steps go So, my problem is:
First of all i configured my server like this:
AT+RST
AT+CIPMUX=1
AT+CWSAP="Servername","12345678",4,3
AT+CIPSERVER=1,1234
I did check that with my lap-top WiFi modem and it worked just fine , I got connected to the router (ESP8266) and i had the sending and receiving going on.
Then i started configuring my client side like that:
AT+RST
AT+CIPMUX=1
At + Cwjap = "Servername" , "12345678"
AT+CIPSTART=0,"TCP","192.168.4.1",1234
Note that 192.168.4.1 is my server IP from server configuration. (response to AT+CIFSR when no one is connected),
I've got a error trying to connect to 1234 port (AT+CIPSTART part) and i just couldn't fix that.
Strange thing is , I tried to connect to another router (my internet wireless router) and i checked the client with Hercules on my PC, i it did work just fine when i started to listening the port in Hercules. but then againt, it couldent work with ESP8266 as router ,
Im deeply sorry if my question is typical or already been issued, but ive searched everywhere and ive found nothing it's killing me ! I appreciate any kind of help.
Thank you all!
UPDATE: thanks to lethe, it solved after i changed client mode to station (AT+CWMODE=1) , For further information read lethe's reply below.
I've Started using ESP8266 for a Communicating project, I want to start a network of ESP8266s that are connected to a router (another ESP8266) and send and receive Data. Due to project circumstances i just can't use frameworksor arduino libraries, and i just can use AT commands ,but i've got stocked at the first steps go So, my problem is:
First of all i configured my server like this:
AT+RST
AT+CIPMUX=1
AT+CWSAP="Servername","12345678",4,3
AT+CIPSERVER=1,1234
I did check that with my lap-top WiFi modem and it worked just fine , I got connected to the router (ESP8266) and i had the sending and receiving going on.
Then i started configuring my client side like that:
AT+RST
AT+CIPMUX=1
At + Cwjap = "Servername" , "12345678"
AT+CIPSTART=0,"TCP","192.168.4.1",1234
Note that 192.168.4.1 is my server IP from server configuration. (response to AT+CIFSR when no one is connected),
I've got a error trying to connect to 1234 port (AT+CIPSTART part) and i just couldn't fix that.
Strange thing is , I tried to connect to another router (my internet wireless router) and i checked the client with Hercules on my PC, i it did work just fine when i started to listening the port in Hercules. but then againt, it couldent work with ESP8266 as router ,
Im deeply sorry if my question is typical or already been issued, but ive searched everywhere and ive found nothing it's killing me ! I appreciate any kind of help.
Thank you all!
UPDATE: thanks to lethe, it solved after i changed client mode to station (AT+CWMODE=1) , For further information read lethe's reply below.