From ed74bebcf3800bbd2c3fffbc414248b87c349a3d Mon Sep 17 00:00:00 2001 From: jenish Date: Fri, 5 Mar 2021 14:42:41 +0530 Subject: [PATCH 1/2] added one more v4 multicast address --- lib/src/discovery.dart | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/lib/src/discovery.dart b/lib/src/discovery.dart index c08d93b..86640e5 100644 --- a/lib/src/discovery.dart +++ b/lib/src/discovery.dart @@ -1,6 +1,7 @@ part of upnp; final InternetAddress _v4_Multicast = new InternetAddress("239.255.255.250"); +final InternetAddress _v4_Multicast_1 = new InternetAddress("239.255.255.250"); final InternetAddress _v6_Multicast = new InternetAddress("FF05::C"); class DeviceDiscoverer { @@ -81,6 +82,11 @@ class DeviceDiscoverer { socket.joinMulticast(_v4_Multicast); } on OSError { } + + try { + socket.joinMulticast(_v4_Multicast_1); + } on OSError { + } try { socket.joinMulticast(_v6_Multicast); @@ -92,6 +98,11 @@ class DeviceDiscoverer { socket.joinMulticast(_v4_Multicast, interface); } on OSError { } + + try { + socket.joinMulticast(_v4_Multicast_1, interface); + } on OSError { + } try { socket.joinMulticast(_v6_Multicast, interface); @@ -141,6 +152,11 @@ class DeviceDiscoverer { socket.send(data, _v4_Multicast, 1900); } on SocketException { } + + try { + socket.send(data, _v4_Multicast_1, 1900); + } on SocketException { + } } if (socket.address.type == _v6_Multicast.type) { From b2d0cf622ee72189cb3f72225c20fe656d18c913 Mon Sep 17 00:00:00 2001 From: jenish Date: Fri, 5 Mar 2021 14:46:58 +0530 Subject: [PATCH 2/2] update ip address --- lib/src/discovery.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/discovery.dart b/lib/src/discovery.dart index 86640e5..c8dbd7e 100644 --- a/lib/src/discovery.dart +++ b/lib/src/discovery.dart @@ -1,7 +1,7 @@ part of upnp; final InternetAddress _v4_Multicast = new InternetAddress("239.255.255.250"); -final InternetAddress _v4_Multicast_1 = new InternetAddress("239.255.255.250"); +final InternetAddress _v4_Multicast_1 = new InternetAddress("255.255.255.255"); final InternetAddress _v6_Multicast = new InternetAddress("FF05::C"); class DeviceDiscoverer {