Do you have a hosted version of that source code somewhere? I have been thinking about doing this with my own keyboard at some point.
So then I searched to see if somebody else had created one, and found this[1]
I wrote that!
So there’s my file. I don’t know if I made any improvements to it since posting that, since I can’t find it anymore. Let me know if you encounter any bugs.
[1] https://www.reddit.com/r/olkb/comments/8mxpdp/qmk_code_to_en...