Refactored cloud connection, added packet wrapper to device communications with checksum