I'm developing a driver which connects to a relay board via tcp socket;
I have used the interfaces.rawSocket.connect method to establish the connection. The driver is working fine atm.
what is the usual/recommended way to startup a socket connection and to keep it alive?
I currently had the connection setup to start on device creation and a refresh loop to run every 5 minutes (using runEvery5Minutes).