Post Reply 
4K HP 67 Games rom attached for testing
11-03-2016, 07:59 PM (This post was last modified: 11-03-2016 08:11 PM by Dieter.)
Post: #89
RE: 4K HP 67 Games rom attached for testing
(11-03-2016 07:23 PM)RobertM Wrote:  In my version, you will notice the two branch instructions back to back (X=Y? followed by ISG). Thus if X does not equal Y (Alglog is not in this quadrant) then the CLX will happen. The reason for the CLX is to disable stack lift, so the next RCL (or number entry E1) doesn't lift the stack, thus the "target quadrant" stays in Y.

Correct. But now assume that X (say: R21) does equal Y. Then the ISG increments the Alglog counter but the following CLX will not be executed. The next RCL 22 will lift the stack. Now X is R22 and Y holds the previously tested register. But since this is equal to the previous X the test should still work OK.

I now begin to understand how this is supposed to work and why it actually seems to be a valid solution.

(11-03-2016 07:23 PM)RobertM Wrote:  Pretty sure this works correctly, but I could be wrong.

Yes, it really works this way. Thank you for pointing in the right direction. I even tried this piece of code on a "real" HP41 and Bingo – it works.

Dieter
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
HP-67 AOS program to debug - Gene - 10-30-2016, 02:11 AM
RE: 4K HP 67 Games rom attached for testing - Dieter - 11-03-2016 07:59 PM



User(s) browsing this thread: 1 Guest(s)