Nice project! I like the idea of an '816-ified AIM!
Re troubleshooting, I have several comments, and of course I'm half guessing. But maybe I can raise some ideas that indirectly become helpful.
Marta wrote:
Installed [a different MCU] and it fails to even boot. [...] My conclusion is that I have either a marginal timin, marginal levels or a bad MCU.
Maybe it's not the MCU that made the difference but just the act of changing it. Remember it's possible you disturbed a marginal connection between the socket and the MCU pins or between the socket and the wires connecting to it. As you say, it's newly built hardware and anything can happen.
Quote:
It has a hc245 and hc373 closest to the MCU
Regarding the '245, HCT might be a better choice than HC. Some RAMs and PROMs --
including many modern CMOS ones -- don't output good CMOS levels, only TTL levels.
(If you don't have an HCT245, you could experiment with pullup resistors on the memory data bus.)
Quote:
The four lowest address lines and R/W are buffered by a 245.
This probably isn't necessary, at least with modern WDC parts (which have very strong outputs and don't require buffering). But there's no downside to buffering except for the added delay. And that won't matter unless your margins are slim (such as when pushing for a high clock rate). BTW, what
is your clock rate? Regarding the possibility of marginal timing, have you tried switching to a lower clock rate?
Quote:
That also drives ph2 that has everything connected in parallel, the VIA, CRTC and quite a few gate inputs.
Can you clarify regarding clocking, please. Is the CPU Phi2 input driven by the 245, or just the Phi2 for the other logic?
BTW, HC logic may be incapable of providing the fast rise and fall times which the CPU Phi2 input requires (at least according to the datasheet).
Marta wrote:
The JSR (ABS,X) does not jump to the desired target. [...] JSR to a JMP (ABS,X) works perfectly...
Quote:
I will work around the failing instruction and complete the program so that a readback of memory becomes possible.
Readback of memory adds another layer to the equation, and may become a rabbit hole due to other gremlins not yet detected. How comfortable are you with the oscilloscope? You could use
it for readback, as follows. Set up the jump table so that the JSR (ABS,X) should always jump back to itself. Then you can use the 'scope to observe what happens, cycle by cycle, as
just one single instruction executes again and again. (This will trash the stack, so you may need to use emulation mode to contain the damage to page $01.)
Have fun and keep us posted!
-- Jeff