Forum Software Ferduino code Doubt about DHCP and IP

Doubt about DHCP and IP  [SOLVED]


Post Number:#1 Post Sat Jun 23, 2018 2:30 pm
Posts: 22
Topics: 9
Images: 2
Solve rating: 0
Joined: Wed Aug 16, 2017 12:35 pm
Topics: 9
Age: 42
Gender: None specified
National Flag:
Brazil
I do not understand network settings, and I use a modem with wi fi connection and a router to boost the wi fi signal on a homemade cable internet network. In this case I have to enable the DHCP command line?

// Comment this line to use static IP.
// Comment this line to use static IP
// # define USE_DHCP // Uncheck this line to use DHCP


Another question, in these lines below do I have to change some configuration? Or do I keep everything as it is?

#ifndef USE_ESP8266 //Do not change this line 
byte mac[] = {0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED }; // Este MAC deve ser único na sua rede local.
byte ip[] = {192, 168, 0, 177};                     // Configure o IP conforme a sua rede local.
IPAddress dnsServer(8, 8, 8, 8);                    // Configure o IP conforme a sua rede local. Este é o DNS do Google, geralmente não é necessário mudar.
IPAddress gateway(192, 168, 0, 1);                  // Configure o "Gateway" conforme a sua rede local.
IPAddress subnet(255, 255, 255, 0);                 // Configure a máscara de rede conforme a sua rede local.


Rômulo.
Last edited by Fernando Garcia on Sat Jun 23, 2018 3:53 pm, edited 1 time in total.
Reason: Please use tags [code][/code] to post any code here.

Post Number:#2 Post Sat Jun 23, 2018 3:52 pm
Posts: 1578
Topics: 38
Images: 271
Solve rating: 213
Joined: Mon Mar 03, 2014 5:59 pm
Topics: 38
Age: 34
Location: São Paulo
Gender: Male
National Flag:
Brazil

There's nothing to change on code when using WiFi.

The meaning of this line:

#ifndef USE_ESP8266


Is: If not defined USE_ESP8266

In others words if not using ESP8266 then...

You should set static IP in router settings.
Please do not PM me for support unless it is absolutely necessary.

I'll not write custom function to nobody unless you can pay for my job.




Return to Ferduino code





Who is online

Users viewing this topic: No registered users and 1 guest