Post Reply 
why don't emulators such as the DM41X and V41 display the synthetic geese?
03-27-2024, 11:07 PM (This post was last modified: 03-28-2024 06:07 AM by dmh.)
Post: #16
RE: why don't emulators such as the DM41X and V41 display the synthetic geese?
Wow! Excellent work Thomas!

Out of interest, what did you use to write and run your test case?

Hopefully the emulators can be easily updated to test and fix this.

(03-27-2024 07:07 PM)ThomasF Wrote:  
(03-27-2024 03:32 PM)ThomasF Wrote:  One thing is that DEC mode is active, so A=A-1 MS should be executed in decimal mode, could that be the problem?

Helping myself out of this ...

I wrote a small test-code that tried this, and yes, my assumption was correct!

Code:
   4F79>009C|00E0080E1B80B8 *d E1B8           2A0 - SETDEC
   4F7A>009C|00E0080E1B80B8 *d E1B9           130 - LDI S&X
   4F7B>009C|00E0080E1B80B8  d E1BA           20F - CON: 20F (1017)
   4F7C>009D|00E0080E1B80B8 *d E1BB           33C - RCR 1
   4F7D>009D|0000000000000F *d E1BC           10E - A=C      ALL
   4F7E>009D|F00E0080E1B820 *d E1BD           1BE - A=A-1    MS
   4F7F>009D|F00E0080E1B820 *d E1BE           017 - JC       +02 [E1C0]

   4F80>009D|F00E0080E1B820 *d E1C0           0AE - A<>C     ALL
   4F81>009C|F00E0080E1B820 *d E1C1           10E - A=C      ALL
   4F82>009C|800E0080E1B820 *d E1C2           1BE - A=A-1    MS

When A[MS] = F and we execute A=A-1 [MS], the carry is set and A[MS] is changed to 8.

If my assumption is correct, I thinbk this answers the original question ...

(03-27-2024 01:08 AM)dmh Wrote:  So which emulators handle this correctly and what is required to fix the others (ie what is the case not being handled so others can fix their emulators)?

Could someone verify this? Does the emulators set the carry when decrementing "F" in decimal mode?
IMHO I think not, this is a special corner case, triggered by the FIX 10, and unclear documentation regarding the instruction.

Is there any emulator or simulator that handles this case? Or is it easy to fix?

Cheers, and happy Easter!
Thomas

Calculator Clique on YouTube
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: why don't emulators such as the DM41X and V41 display the synthetic geese? - dmh - 03-27-2024 11:07 PM



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