Cleanup of packed payload encoder
- Cleanup of write*int functions - Multiply pressure by 10 (decoder was already dividing by 10) - Fix undefined behavior on intToBytes function.
This commit is contained in:
1 parent
88db2cca2b
commit
45b0bae945
2 files changed
+23
-17
No files matched your search
+2
-1
@@ -67,9 +67,10 @@ private:
|
||||
private:
|
||||
uint8_t *buffer;
|
||||
uint8_t cursor;
|
||||
void intToBytes(uint8_t pos, int32_t i, uint8_t byteSize);
|
||||
void uintToBytes(uint64_t i, uint8_t byteSize);
|
||||
void writeUptime(uint64_t unixtime);
|
||||
void writeLatLng(double latitude, double longitude);
|
||||
void writeUint64(uint64_t i);
|
||||
void writeUint32(uint32_t i);
|
||||
void writeUint16(uint16_t i);
|
||||
void writeUint8(uint8_t i);
|
||||
|
||||
Reference in new issue
Block a user