Move communication stuff out of main

I think Start should simply start the communication goroutines, not block on them finishing.  Add a WaitForShutdown method instead? (and a Stop or Shutdown if you need to forcibly close it before it cleanly finishes)