Fixing IP Address for ESP32 and PC Communication

e2738729
Posts: 35
Joined: Mon Nov 05, 2018 6:22 pm

Fixing IP Address for ESP32 and PC Communication

Postby e2738729 » Tue Mar 26, 2019 7:20 pm

Hi everyone,

I am not very good at network programming so I hope that someone could give me some directions to try.

I have a PC communicate with ESP32 via TCP/IP. The ESP32 is a server and PC is a client. As you already know, the PC requires the ESP32's IP address and port in order to establish a connection with the ESP32.

My biggest problem is that the ESP32's IP address is not fixed. First day I have "192.168.1.4", but now it is "192.168.1.3" What should I do about this? I dont want to change my python code on PC every time the IP address of the ESP32 changes.

Thanks

WiFive
Posts: 3529
Joined: Tue Dec 01, 2015 7:35 am

Re: Fixing IP Address for ESP32 and PC Communication

Postby WiFive » Wed Mar 27, 2019 1:33 am


ESP_Sprite
Posts: 9723
Joined: Thu Nov 26, 2015 4:08 am

Re: Fixing IP Address for ESP32 and PC Communication

Postby ESP_Sprite » Wed Mar 27, 2019 2:17 am

This is not a hardware question; moved to General Discussion.

User avatar
arunbm123
Posts: 96
Joined: Fri Feb 23, 2018 5:36 am

Re: Fixing IP Address for ESP32 and PC Communication

Postby arunbm123 » Wed Apr 03, 2019 3:56 am

hello,

its simple
Connect to your router at 192.168.1.1 (This is for my router) check the ip on your router backside.

there goto DHCP reserved.

Assign a IP along with mac..Thats it..

e2738729
Posts: 35
Joined: Mon Nov 05, 2018 6:22 pm

Re: Fixing IP Address for ESP32 and PC Communication

Postby e2738729 » Wed Apr 03, 2019 2:10 pm

Thanks for your reply arunbm,

So just to clarify,

"there goto DHCP reserved.
Assign a IP along with mac..Thats it.."

I will do the above two steps on the router website right? Each router whenever I setup requires a website that I can log-in, setup the wifi name and password.

Thanks

User avatar
fly135
Posts: 606
Joined: Wed Jan 03, 2018 8:33 pm
Location: Orlando, FL

Re: Fixing IP Address for ESP32 and PC Communication

Postby fly135 » Wed Apr 03, 2019 5:08 pm

e2738729 wrote:
Wed Apr 03, 2019 2:10 pm
Thanks for your reply arunbm,

So just to clarify,

"there goto DHCP reserved.
Assign a IP along with mac..Thats it.."

I will do the above two steps on the router website right? Each router whenever I setup requires a website that I can log-in, setup the wifi name and password.

Thanks
Yes, it is a function of the router supplying the DHCP addresses. There should be a setup page to fix a DHCP IP to a MAC address.

John A

User avatar
arunbm123
Posts: 96
Joined: Fri Feb 23, 2018 5:36 am

Re: Fixing IP Address for ESP32 and PC Communication

Postby arunbm123 » Thu Apr 04, 2019 3:01 am

hi

Thanks for your reply arunbm,

So just to clarify,

"there goto DHCP reserved.
Assign a IP along with mac..Thats it.."

I will do the above two steps on the router website right? Each router whenever I setup requires a website that I can log-in, setup the wifi name and password.

Thanks
Yes e2738729

e2738729
Posts: 35
Joined: Mon Nov 05, 2018 6:22 pm

Re: Fixing IP Address for ESP32 and PC Communication

Postby e2738729 » Thu Apr 04, 2019 2:52 pm

Thank you you all very much for your helps!

Who is online

Users browsing this forum: No registered users and 80 guests