In order to complete my mission, I adapted the raw code generated by DASMx to the syntax of the A09 assembler (
https://github.com/Arakula/A09).
I had used this assembler in the past, as it was the only one I could find at the time, which supported the 6301 instruction set.
Besides replacing the data byte and word mnemonics I also went many times through the code until it assembled properly.
The result is a binary identical ROM image.
I also took care to replace all references to addresses inside the Forth ROM by labels (e.g. the LFA, NFA, CFA, PFA fields in the header of each word).
For better readability I also rewrite the last characters of each string which had its high bit set.
This should make it possible to move code around, e.g. when inserting or deleting words without breaking the system.
However it is very likely that there are still some places which have to be reworked.
In some places I have added comments with ???? to highlight areas where I am not sure what happens there.
This is also true for the block of trailing bytes, which seem to be unused, but may be used by indexed access.
I did not investigate this detail further, nor did I fill these bytes with zeroes to try what happens.
The assembler understands some constructs like if/else/endif which can be used to adapt the source to different HX-20 ROM constellations.
Unfortunately my Workhorse-HX-20 has developed a keyboard problem. Something with the contact sheets not contacting anymore on three keys. I have to revert to a different machine and/or try to repair this. Too bad, as I had already replaced all capacitors and of course the battery.
The broken keys are not on a single row or column, so it is not a wiring or connector problem.
Unfortunately it is not possible to replace individual switches. I guess that the coating on these thin membranes wears over time. And the membranes seem to be glued together, forming the thin black layer on top of the pcb.
Anyone has an extra keyboard (without key caps and springs)... in Europe?
Martin