mirror of
https://github.com/esp8266/Arduino.git
synced 2025-07-11 15:22:13 +03:00
Add destinationIP method to WiFiUDP
Might be useful to distinguish between normal and multicast packets arriving at the same port (#105)
This commit is contained in:
@ -240,6 +240,17 @@ uint16_t WiFiUDP::remotePort()
|
||||
return _ctx->getRemotePort();
|
||||
}
|
||||
|
||||
IPAddress WiFiUDP::destinationIP()
|
||||
{
|
||||
IPAddress addr;
|
||||
|
||||
if (!_ctx)
|
||||
return addr;
|
||||
|
||||
addr = _ctx->getDestAddress();
|
||||
return addr;
|
||||
}
|
||||
|
||||
uint16_t WiFiUDP::localPort()
|
||||
{
|
||||
if (!_ctx)
|
||||
|
Reference in New Issue
Block a user