MP automatically retrying network connection after fail

I’m very successfully using a 4G/LTE connection to monitor/control a PixHawk (using a Raspberry pi). I’m using an Amazon ec2 server running a reverse SSH tunnel (necessary to keep Verizon happy) and both ends can use network names. I even get 1280 X 960 @30 fps streaming video from the Raspberry pi camera at the same time.

Every once in awhile, the 4G signal fades and the data link fails. At that time, MP shows an “X” over the signal strength, but the “Connect” icon shows everything is still connected. When the 4G link re-establishes itself, I can force a reconnection to the Amazon server from the Pixhawk end, but MP does not recover. The PC to Amazon server doesn’t automatically reconnect. I realize that something may have to be done at the server end, but I can’t find anyone who can tell me what that would be. Is there any way that MP - when using tcp or UDP protocols, could re-try contacting the server at 5-10 sec intervals when the “signal strength” drops to zero so that it would automatically reconnect - and without reloading all the parameters? I would think this might be a useful feature.

I probably need a custom protocol, or to make some changes to MP, but I’m not versed enough to do that.

Any thoughts would be appreciated.

what protocol where you testing with?
udp is connection less, so MP will not know that there is nothing at the other end, but at the same time if something resumes sending data MP is still listerning.

TCP on the other hand has a connection state, so any drop can be retried.

also what are you using to bounce the data? and is that dropping the connection to MP when the connection dies?

Unfortunately, I’m set up for tcp only. I’m “bouncing” the data using an Amazon ec2 server set up as a reverse SSH tunnel. I’m running SSH from the copter to the server and tcp from the server to the ground station. I’ll see if I can modify the protocol to UDP.

  Things work great, but I need to make the system more robust and automatic. Both ends are initiating the connection to the same server, so dynamic ip addresses are no issue.  Also, I need very simple software in the Raspberry and unmodified Mission Planner.  My latency is only about 30mSec, so joystick control using MP works well.

Charles Linquist

2 PM, Michael Oborne wrote: