More success with Nonpareil Message #1 Posted by Eric Smith on 7 May 2005, 11:35 p.m.
This morning I was trying to figure out why Nonpareil isn’t coming anywhere close to simulating the HP-67 correctly. It comes up with a single decimal point lit in the display, and the only visible responses to the keyboard are for the decimal point to move to another position or disappear.
So I captured an execution trace from the simulator, and started studying it. Almost immediately, I found that they are doing a “DELAYED ROM SELECT” instruction preceding a “A -> ROM” instruction.
On the real hardware, I don’t know whether DELAYED ROM SELECT is only delayed by one instruction, or whether it is delayed until the next branch. When I wrote the Woodstock CPU code, I implemented it as being delayed until the next branch. But I forgot to handle it with the “GOTO KEYS” and “A -> ROM” instructions, which are computed branches based on the keycode and A register, respectively.
I also determined that opcode 0120 octal is almost certainly the “KEYS -> A” instruction.
Adding KEYS->A and fixing the DELAYED ROM SELECT did not fix the HP-67 problem. But it did fix the problems with the HP-34C, HP-37E, HP-38E, and HP-38C, all of which now seem to work correctly!
Edited: 8 May 2005, 4:49 p.m.
|