Skip to content

WiFiC3 - dnsIP(n) getter added #176

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

Merged
merged 1 commit into from
Dec 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions libraries/WiFi/src/WiFi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,11 @@ IPAddress CWifi::gatewayIP() {
return IPAddress((uint32_t)0);
}

/* -------------------------------------------------------------------------- */
IPAddress CWifi::dnsIP(int n) {
return CLwipIf::getInstance().getDns(n);
}

/* -------------------------------------------------------------------------- */
const char* CWifi::SSID(uint8_t networkItem) {
return CLwipIf::getInstance().getSSID(networkItem);
Expand Down
7 changes: 7 additions & 0 deletions libraries/WiFi/src/WiFiC3.h
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,13 @@ class CWifi {
*/
IPAddress gatewayIP();

/*
* Get the DNS server IP address.
*
* return: DNS server IP address value
*/
IPAddress dnsIP(int n = 0);

/*
* Return the current SSID associated with the network
*
Expand Down