B4R Question esp8266 wifi and data network it is possible?

3394509365

Active Member
Licensed User
Longtime User
I'm starting to use the esp8266 wifi, do you know if it is possible to use it as well as from a wifi network using the data network maybe through an IP?

Can I also use b4A?
 

candide

Active Member
Licensed User
for esp8266, yes you can use B4R and it is the easier way to program something on it.
After installation of B4R, you can find a good documentation with several examples of code to connect it to network . Also this forum is a real bible of code for esp8266 with B4R
 
Upvote 0

3394509365

Active Member
Licensed User
Longtime User
thank candide

for janderkan

I try to make myself better.
Once I have made the connection with the home modem, if I am away from home and out of range of the modem can I access the ESP8266 anyway?
 
Upvote 0

candide

Active Member
Licensed User
as soon as your esp is connected to your internal network it will have an internal ip address like 192.168.1.45 and your esp can access to external network, but for an access from external network to your esp, you have to create a NAT link in your adsl box from external IP address+ port => esp local IP address.
you can use also an indirect way : your mobile and esp can connect to same external server and both can communicate .(like cloudMQTT.com )
you can use firebase and in this case it is push process...
 
Upvote 0

3394509365

Active Member
Licensed User
Longtime User
Thanks for the reply.
I followed a tutorial and was able to connect through my router,
The strange thing is that they burn gives me the IP 192.168.4.2 instead I have to use what I find in the Modem however it works.

On the other hand, if I try to access from my smartphone away from home, it gives me as ip 127.0.0.1,
I use this ip + port 2000 to connect, but nothing.

Do you have any idea what to do?

If I can't connect remotely what's the use?
 
Upvote 0

tigrot

Well-Known Member
Licensed User
Longtime User
Remember that some mobile provider blocks some ports. Use a dynamic DNS to find your public IP and redirect the port to your device. 127.0.0.1 is equivalent to localhost, the device itself. This is impossible to work! If you have a static IP address you can check it once by https://www.myip.com/ or if it is dynamic you must check everytime you need.
 
Upvote 0
Top