Protocol header (Bytefield)
A custom binary protocol is where these diagrams earn their keep, because there is no RFC for the reader to check against.
#What this example shows
A magic number, which is how the format identifies itself.
Version and flags fields, sized deliberately.
A trailing checksum after a variable body.
#A worked example
Open it, edit it, or copy the source below.
The source, which you can paste into a new diagram and edit:
#Making it your own
Put the magic number first; it is how a parser rejects the wrong file quickly.
Name the endianness on the fields where it matters, as this one does.
Reserve fields explicitly rather than leaving gaps for later.
#Related
The offsets are computed, not drawn.
