small cleanups
use sprintf for better logging
Log when sending on/off api calls
Don't sync the state twice at boot
More syslog and less println
Handle locking on api and state callbacks
Make boot messages more obvious where they come from
Fixed locking typo
Fix on/off timeout issue
Use locking on target mac callback
Fix lock behavior on mac callback
Try to let the syn/ack buffer flush after a on/off callback
Try to add more locking mechanisms
Added tcp waiting to prevent multiple tcp streams at the same time
Handle non-200 responses
Set the initial state to be 0