Hi team,
I have a function to force call an API via cellular
Everything is good but we got a problem when we test on a SIM that enabled VoLTE.
When 4G is on only, we scan and found and IP for both cellular (pdpip0) and VoLTE (pdpip1)
But when wifi is on also,
cellular IP is gone. only VoLTE is there.
lo0 ?
lo0 127.0.0.1
lo0 ::1
lo0 fe80::1%lo0
pdpip0 ?
pdpip2 ?
pdpip4 ?
pdpip1 ?
pdpip1 10.108.12.211
pdpip3 ?
ap1 02:00:00:00:00:00
en0 02:00:00:00:00:00
en0 fe80::10e4:7cd7:7595:85ff%en0
en0 192.168.17.28
en1 02:00:00:00:00:00
en2 02:00:00:00:00:00
en2 fe80::8dc:ce98:268c:c858%en2
en2 169.254.117.122
awdl0 02:00:00:00:00:00
awdl0 fe80::14e4:b0ff:fe49:7693%awdl0
utun0 ?
utun0 fe80::ced8:eb7b:b3ea:5292%utun0
utun1 ?
utun1 fe80::1f06:b0ec:53f0:a5b6%utun1
llw0 02:00:00:00:00:00
llw0 fe80::14e4:b0ff:fe49:7693%llw0
utun2 ?
utun2 fe80::9737:ca6e:29c5:863a%utun2
ipsec0 ?
utun3 ?
utun3 fe80::82ba:180d:e32f:c460%utun3
utun4 ?
utun4 fe80::68be:6948:3c07:4777%utun4
ipsec1 ?
ipsec1 10.108.12.211
ipsec2 ?
ipsec2 10.108.12.211
ipsec3 ?
ipsec3 10.108.12.211
ipsec4 ?
ipsec4 10.108.12.211
Do you know why it's gone and how to detect the cellular IP in this case?
Thanks a lot
I have a function to force call an API via cellular
Everything is good but we got a problem when we test on a SIM that enabled VoLTE.
When 4G is on only, we scan and found and IP for both cellular (pdpip0) and VoLTE (pdpip1)
But when wifi is on also,
cellular IP is gone. only VoLTE is there.
lo0 ?
lo0 127.0.0.1
lo0 ::1
lo0 fe80::1%lo0
pdpip0 ?
pdpip2 ?
pdpip4 ?
pdpip1 ?
pdpip1 10.108.12.211
pdpip3 ?
ap1 02:00:00:00:00:00
en0 02:00:00:00:00:00
en0 fe80::10e4:7cd7:7595:85ff%en0
en0 192.168.17.28
en1 02:00:00:00:00:00
en2 02:00:00:00:00:00
en2 fe80::8dc:ce98:268c:c858%en2
en2 169.254.117.122
awdl0 02:00:00:00:00:00
awdl0 fe80::14e4:b0ff:fe49:7693%awdl0
utun0 ?
utun0 fe80::ced8:eb7b:b3ea:5292%utun0
utun1 ?
utun1 fe80::1f06:b0ec:53f0:a5b6%utun1
llw0 02:00:00:00:00:00
llw0 fe80::14e4:b0ff:fe49:7693%llw0
utun2 ?
utun2 fe80::9737:ca6e:29c5:863a%utun2
ipsec0 ?
utun3 ?
utun3 fe80::82ba:180d:e32f:c460%utun3
utun4 ?
utun4 fe80::68be:6948:3c07:4777%utun4
ipsec1 ?
ipsec1 10.108.12.211
ipsec2 ?
ipsec2 10.108.12.211
ipsec3 ?
ipsec3 10.108.12.211
ipsec4 ?
ipsec4 10.108.12.211
Do you know why it's gone and how to detect the cellular IP in this case?
Thanks a lot
BSD names (for example, pdp_***) are not considered API. If you’re using those names to force a connection to run over WWAN, you will run into problems like this.
If you want to force a TCP connection (or UDP flow) to run over WWAN, the best option is to use NWConnection and set the requiredInterfaceType property of the parameters you use to create the connection.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
If you want to force a TCP connection (or UDP flow) to run over WWAN, the best option is to use NWConnection and set the requiredInterfaceType property of the parameters you use to create the connection.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"