[<<][c][>>][..]
Tue Feb 12 14:24:29 CET 2013

Universal header

For storing things in Flash over a non-error-free channel, I found
that there are 2 things important to make handling easier:
- protect individual headers with a small CRC
- don't make chunk sizes too large

struct uh {
    u8 crc;
    u8 size;
    u8 type;
    u8 _reserved_;
};

crc is necessary to verify the whole message
size is necessary to buffer the whole message and skip to the next one
type is necessary to know how to process

_reserved_ is an extra byte that can be used by one of the other
fields.



[Reply][About]
[<<][c][>>][..]