Is there a way to force a network connection through 4G, even if WiFi is turned on and connected?

I have an application that controls the Sony RX10 camera via Wi-Fi. I need to upload photos to the server after taking them, and it seems to me that I read somewhere that this is possible, but now I can not find it anywhere ... The problem is that the camera acts as a router, but it does not have Internet access. Thus, the tablet / phone connected to it is trying to transfer the media on this channel, but I need it to use the 4G antenna instead and transmit this path.

Is it possible to force a device to connect to a server (HTTP) via a cellular network, even if it is connected via WiFi to one that does not have Internet access?

+4
source share
1 answer

Definitely yes . You must use the C code. You must periodically list the network interfaces. You must bind a socket to each IP address. I have an exaple for iOS, but I keep thinking about Android all the time. https://gist.github.com/avesus/fdb465b60a4f5204845c

+1
source

Source: https://habr.com/ru/post/1546378/


All Articles