V41: saving of files in X-Memory; HowTo? (test; no HW use)

V41: saving of files in X-Memory; HowTo? (test; no HW use)

Postby floppy_stuttgart » Fri Jul 08, 2022 4:48 pm

I have the setup of V41 with a CX which show

first
EMDIR
DIR EMPTY

T= 54.00000000
Z= 0.000000000
Y= 600.0000000
X= 600.0000000


then
CAT 1
LBL`SLRQA
LBL`BPER4
LBL`ALQR
LBL`CQRL
LBL`CQP
LBL`CQRC
LBL`CQRZ
LBL`RQ
LBL`SQIY
LBL`SQJY
LBL`SQKY
LBL`AQIY
LBL`AQJY
LBL`AQKY
LBL`RQIX
LBL`RQJX
LBL`RQKX
LBL`Q*
LBL`CQ
LBL`TQR
END 1256 BYTES
LBL`SXQA
END 153 BYTES
.END. 05 BYTES


However XEQ SXQA
of the program (should store the files in X memory)
Code: Select all
LBL "SXQA"
"SLRQA"
XROM 25,38   = SAVEP
"TQR"
XROM 25,38
"CQ"
XROM 25,38
"Q*"
XROM 25,38
"RQIX"
XROM 25,38
"RQJX"
XROM 25,38
"RQKX"
XROM 25,38
"RQVX"
XROM 25,38
"SQIY"
XROM 25,38
"SQJY"
XROM 25,38
"SQKY"
XROM 25,38
"AQIY"
XROM 25,38
"AQJY"
XROM 25,38
"AQKY"
XROM 25,38
"RQ"
XROM 25,38
"CQRZ"
XROM 25,38
"CQRC"
XROM 25,38
"CQP"
XROM 25,38
"BPER4"
XROM 25,38
"ALQR"
XROM 25,38
"CQRL"
XROM 25,38
RTN
END


trace in ILPER printer area:
Code: Select all
XEQ "SXQA"
 01*LBL "SXQA"
"SLRQA"
SAVEP
"TQR"
SAVEP
"CQ"
SAVEP
"Q*"
SAVEP
NO ROOM     
EMDIR
SLRQA   P180
TQR     P180
CQ      P180

T=  0.000000000
Z=  600.0000000
Y=  600.0000000
X=  54.00000000


Thats weird. Why 180 for each program?
How programs which are stored in an HP41CX of 319 register cannot be stored in X-Memory with 600 registers?
Just for me to understand (its only V41; not a HW X-memory; still to be tested there).
floppy_stuttgart
.........
.........
 
Posts: 112
Joined: Mon Mar 29, 2021 2:36 pm

Re: V41: saving of files in X-Memory; HowTo? (test; no HW us

Postby rprosperi » Fri Jul 08, 2022 9:05 pm

The way you have your 41 program memory set up, all of the programs from

LBL`SLRQA to

LBL`TQR
END 1256 BYTES

are saved within the same program space. Though you possibly use them as separate programs, since they have no separate END statements to terminate each program, they are all contained within a single program space. This is not a problem per se, but what is confusing you is that when you save a program by name (using "XYZ" [XEQ] "SAVEP", it saves the entire program space that contains the global LBL "ZYZ", from the initial instructions at step 001 all the way to the final END statement. So there is no need to save all the individual programs by name, using SAVEP with the name of any global label within that single program space saves the entire space. So what you are doing is saving about 18 copies of the entire set of programs. You only need to save it once, OR you can break this up into many smaller program spaces by adding and END at the end of each logical program.
rprosperi
.........
.........
 
Posts: 75
Joined: Sat Apr 11, 2015 1:03 pm

Re: V41: saving of files in X-Memory; HowTo? (test; no HW us

Postby jeffcalc » Sat Jul 09, 2022 2:30 pm

The interesting point about this question is that the X-Function manual does not explicitly explain what is a "program" in the context of program saving, it just indicates to supply the "program name" to the SAVEP function. It doesn't explain that all steps from step 01 to the END will be saved.

Actually, the card reader manual (for writing program to card) and the HP-IL manual (for the WRTP command) also don't clarify what is a "program".
And none of these manuals indicate that any global label can be used to designate the program area to be saved.

We have to refer back to the HP-41C user manual to find a description of what is a program (in the sense of the 41C): a memory area started with GTO.. to make sure the previous program is terminated, and ended with END (or GTO..).

J-F
User avatar
jeffcalc
......
......
 
Posts: 27
Joined: Fri Aug 28, 2009 8:57 pm


Return to Programming

Who is online

Users browsing this forum: No registered users and 1 guest

cron