|
|
|
|
|
by dmitrygr
1323 days ago
|
|
> Suppose that you can pack that info (sensor id, metric type and data) in 32 bytes I suppose you haven't worked with such constraints before, so that's why you think this needs 32 bytes. In reality, 4 or 6 will likely do. Send diff in metric value if applicable, use variable-length encoding to not waste bytes. Allocate bits and not whole ints to things (like metric type). ID is already part of lower level protocol - the address, so you do not need it |
|