Post Reply 
Bug in v41 and 41X emulation ?
04-24-2021, 04:25 PM (This post was last modified: 04-24-2021 04:36 PM by Ángel Martin.)
Post: #6
RE: Bug in v41 and 41X emulation ?
Hi J-F, I'm still trying to find an easy combination showing this issue because the only examples I have are using "esoteric" modules as you say.

I agree it's very unlikely that there was a bug in the FN display driver, but then: why the MCODE only fails in HN machines? It's quite a mystery...

Here's the best example I have. This routine is taken from the NFR ROM and it shows a "splash" screen where each character is scrolled from the right to its final position, until the whole message is completed (in this case the text reads "-LIB#4 R58*", the last char being hex 0x1E2. It's quite a nice effect and surely a brainy code. It works flawlessly on the CL and standard FN machines, but it hangs the machine up on HN models. You may want to test how it fares on your emulators.

Code:
1E2    "**"      
038    "8"    
035    "5"    
012    "R"    Revision Name
020    " "    function name is shown
034    "4"    in the Page_Catalog
023    "#"    
002    "B"    
009    "I"    
00C    "L"    
35D    ?NC XQ         
000    ->00D7    [PCTOC]
27A    C=C-1   M    to beginning of string
0EE    B<>C   ALL    save it in B[M]
3C1    ?NC XQ        Enable and Clear Display
0B0    ->2CF0    [CLLCDE]
130    LDI S&X    
107    "t"    little "T"
31C    PT=  1    
3A8    WRIT 14(d)    Places Long LEFT: rotates right
3B8    READ 14(d)    Fetch Right Long: rotates right
0CE    C=B  ALL    
27A    C=C-1  M    previous address
0EE    B<>C  ALL    update repository
0CE    C=B ALL    keep it in C
330    FETCH S&X    read byte value
358    ST=C  XP    place it in ST
28C    ?FSET 7    is it > "0FF"?
023    JNC  +04           no, skip to A0A8
284    CLRF  7    clear it
398    C=ST  XP    restore byte to C[S&X]
288    SETF 7    flag this fact
3E8    WRIT 15(e)    write it to RIGHT and rotate left
28C    ?FSET 7    was it last one?
10F    JC   +33 d        yes, we're done -> A0CB
130    LDI S&X    
100    CON:    
266    C=C-1  S&X    count until 100(hex)
3FB    JNC  -01           A0AD
130    LDI S&X    
020    " "    blank space
106    A=C  S&X    store in A[S&X]
3B8    READ  14(d)    read right chr and move it to left
366    ?A#C  S&X    is it a space?
3F3    JNC  -02        yes, read next chr.  -> A0B2
158    M=C  ALL    no, save chr1 in M
3B8    READ 14(d)    read next cand move to left
366    ?A#C  S&X    is it a space?
05F    JC   +11       no, jump over to A0C3
198    C=M ALL    yes, recall chr1
3E8    WRIT 15(e)    write it to RIGHT end
130    LDI S&X    
020    " "    blank space
3E8    WRIT 15(e)    write it to RIGHT end
3F8    READ 15(e)    Fetch Left Long, rotate Left
2E2    ?C#0 @PT    ???? WTF, PT= 1 ~~
3F7    JC   -02          no, keep at it -> A0BE
3A8    WRIT 14(d)    yes, write cntl chr to LEFT, rotate right
34B    JNC  -23 d     [SCROLL]
3E8    WRIT 15(e)    write it to RIGHT end
198    C=M  ALL    recall chr1 for real
3E8    WRIT 15(e)    write it to RIGHT end
3F8    READ 15(e)    Fetch Left Long
366    ?A#C  S&X    is it space?
3F3    JNC  -02          no, get next chr -> A0C6
3A8    WRIT 14(d)    write cntl$ to LEFT, rotate right
29B    JNC  -45d    next character, A09D
149    ?NC XQ    Enables Chip0
024    ->0952    [ENCP00]
1F9    ?NC GO    Set MSG Flag
00E    ->-037E    [STMSGF]


For your testing convenience, see the example module attached. It accesses the code above when you execute the SPLASH function. Make sure both the XROM and LIBRARY4 are plugged-in.


Attached File(s)
.zip  XROM.zip (Size: 19.76 KB / Downloads: 10)

"To live or die by your own sword one must first learn to wield it aptly."
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Bug in v41 and 41X emulation ? - Ángel Martin - 04-24-2021 04:25 PM



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