Yevgeny Simkin
Yevgeny Simkin

Reputation: 28349

Is there a way to force a network connection over 4G, even when WiFi is enabled and connected?

I have an app that controls the Sony RX10 camera over WiFi. I need to offload the photos to the server after they're taken, and I feel like I read somewhere that this is possible, but now I can't find it anywhere... The problem is that the camera acts as a router, but it has no access to the Internet. So, the tablet/phone that's connected to it is attempting to transmit the media over that channel but what I need it to do is to use its 4G antenna instead and transmit that way.

Is it possible to force the device to connect to the server (HTTP) over the cellular network even when it's connected via WiFi to something that has no access to the Internet?

Upvotes: 6

Views: 2383

Answers (1)

Brian Cannard
Brian Cannard

Reputation: 873

Definitely yes. You should use a C code. You should periodically enumerate network interfaces. You should bind a socket per IP address. I have an exaple for iOS, but I shure on Android all things work same. https://gist.github.com/avesus/fdb465b60a4f5204845c

Upvotes: 1

Related Questions