Add keep-alive ability

Ping the gateway once every two minutes to keep the connection alive.