I'm making a udp connection between a PC and a mobile (Android device) over 3G to stream video and other things. I tested my code over Wifi connection and it works just fine.
The problem is: when connecting over 3G, the connection doesn't work unless the first two fields of the IPs are the same
for example:
- if the
PC IP = 10.220.x.x
and themobile IP = 10.220.x.x
, the connection works. - if
PC IP = 10.220.x.x
and themobile IP = 10.219.x.x
, the connection doesn't work.
Anyone knows where the problem is or how could it be solved? I mean it's so hard to get similar IPs, I could keep disconnecting and re-connecting to get different IPs forever and just get two similar IPs once in a million (since i cannot manually change IP in a 3G network) and it is driving me crazy.
Thanks