Finally works! Well, on my test core, at least. Next up is a real core.
These aren't used by ZMZ, but there's no reason to not share it, in case someone else wants it for something.