Creating memory maps in LaTeX using the {bytefield} package (update x2)

I’m currently working on some embedded systems stuff. For the documentation (written in LaTeX, of course!) I was searching for a convenient way to draw memory maps. The creation of external images using LaTeX Draw (which I like) was not a good option, as I wanted to change my memory maps in a source file and propagate the change with a single ‚typeset‘ command.

I wanted to share my solution, as I found nothing there (as a matter of fact, nobody seems to draw memory maps, which means that a lot of documentation is missing them ;__;). I use the real handy ‚bytefield‘ package (maybe the way to go for documenting registers) which is quite lightweight and convenient to use. This is an example of a basic bytefield definition:

	\bitbox{8}{Byte 3} \bitbox{8}{Byte 2}
	\bitbox{8}{Byte 1} \bitbox{8}{Byte 0}