updated to write to local files so we can see a log and the current levels from anywhere when connected to the device