Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WiFi - static IP auto gw,mask,dns as in Arduino libraries #9031

Merged
merged 3 commits into from
Nov 24, 2023

Conversation

JAndrassy
Copy link
Contributor

@JAndrassy JAndrassy commented Nov 15, 2023

a version of config with two parameters local_ip and dns IP. dns IP is optional. gateway IP is calculated, dns IP is calculated if not provided. then the other config is invoked.

this now allows, these versions

config(ip); <- new
config(ip, dns); <- new
config(ip, dns, gw);
config(ip, gw, mask);  
config(ip, dns, gw, mask);
config(ip, gw, mask, dns);
config(ip, dns, gw, mask, dns2);
config(ip, gw, mask, dns, dns2);

it also allows WiFi.config(INADDR_NONE) to return to DHCP as in other WiFi libraries.

@d-a-v d-a-v merged commit 9a4e178 into esp8266:master Nov 24, 2023
28 checks passed
@JAndrassy JAndrassy deleted the wifi_config_auto branch November 24, 2023 18:13
@TD-er
Copy link
Contributor

TD-er commented Dec 4, 2023

I'll link my comment here also, as I'm really not happy with this new config function.
9a4e178#r134164761

IMHO, it is an inconvenience function, not a convenience function because it makes incorrect assumptions about what will be universally applicable.

d-a-v added a commit to d-a-v/Arduino that referenced this pull request Dec 8, 2023
hasenradball pushed a commit to hasenradball/Arduino that referenced this pull request Nov 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants