Upvoted you however it did solve the author’s problem and if he decides to post to GitHub then it could help someone later. Plenty of people working on retro architectures that wish they had things like this