fixes for running on windows.

Fixes for running on windows.

Optional use of tcp based sockets, since windows doesn't support unix IPC sockets.
The file read/write functions in brewpiJson failed - the python docs hinted that a seek to the current position is needed to help synchronize the file handle.

I have tested these changes on Windows. To test on the rpi, program the arduino from the web, and let the system log a few temperature values. That touches all the code changed.