Saving the state of HP41 CL to PC
12-28-2017, 07:23 AM (This post was last modified: 12-28-2017 07:34 AM by Ángel Martin.)
Post: #11
 Ángel Martin Senior Member Posts: 1,160 Joined: Dec 2013
RE: Saving the state of HP41 CL to PC
(12-28-2017 03:46 AM)PeterP Wrote:  Thanks Monte! This is super helpful. [deletedTwo] Four quick questions:
1. Which events/functions clear the RAM page at 0x800?
2. Do I need to save the page 804 as well or does page 800 include all the modules loaded correctly when saved?
3. The XPMM module from Angel provides the functions "YWALL" / "YRALL" to store everything into Flash 0x1FE and 0x1FF. While certainly not as easy to use as it requires Lib#4 and OSX and XPMM, I wanted to know if there are any other risks/objections to using this function?
4. If these functions are not objectionable, would it be possible to add them to the YFNZ module so that one always has the ability to restore to a nice state from a ML condition and batteries out?

Thank you for your kind help!

YWALL and YRALL are also in the PowerCL_Extreme, and except the Library#4, they don't have any additional dependency but the YFNX itself. They are short FOCAL programs BTW, see the listing below:

Code:
1    LBL "YWALL" 2    "1FE000" 3    AVIEW 4    FC? 49 5    YFERASE 6    "800>1FE" 7    AVIEW 8    YFWR 9    FC? 01 10    GTO 02 11    "1FF000" 12    FC? 49 13    YFERASE 14    "804>1FF" 15    YFWR 16    GTO 02 17    LBL "YRALL" 18    "1FE>800" 19    AVIEW 20    YMCPY 21    "1FF>804" 22    AVIEW 23    FS? 01 24    YMCPY 25    LBL 02 26    "DONE" 27    END

They use FLASH blocks at 0x1FE and 0x1FF for a back-up of the bottom RAM pages 0x800 and 0x804 respectively. As far as I know those locations are still available in the "official" CL flash map.

The main restriction is that they assume the top flash sector (from 0x1F8 to 0x1FF) is eraseable by 4k blocks, and not as a complete sector like all others. I understand this has had some variations in the different versions of the CL boards, so you'll need to make sure this is the case in yours. The functions assume versions V3 or V4 by default.

The FLASH? function in the YUPS module tells you which type of CL board you have as to that behavior, see the CL Update Functions manual, pages 15 & 16.

User Flag 01 is used to control whether to include block 804 in the backup: FI Set includes it, F1 Clear excludes it. This is where the MMU "meta-data" and other CL-configuration details are included, I always include it.

As always, make sure your batteries are fresh before you write to flash!

Cheers,
ÁM
 « Next Oldest | Next Newest »

 Messages In This Thread Saving the state of HP41 CL to PC - PeterP - 12-27-2017, 11:30 PM RE: Saving the state of HP41 CL to PC - Monte Dalrymple - 12-28-2017, 12:13 AM RE: Saving the state of HP41 CL to PC - PeterP - 12-28-2017, 03:46 AM RE: Saving the state of HP41 CL to PC - Ángel Martin - 12-28-2017 07:23 AM RE: Saving the state of HP41 CL to PC - PeterP - 12-29-2017, 02:33 AM RE: Saving the state of HP41 CL to PC - rprosperi - 12-29-2017, 03:54 AM RE: Saving the state of HP41 CL to PC - Monte Dalrymple - 12-31-2017, 03:25 AM RE: Saving the state of HP41 CL to PC - hth - 12-28-2017, 03:23 AM RE: Saving the state of HP41 CL to PC - PeterP - 12-28-2017, 03:49 AM RE: Saving the state of HP41 CL to PC - rprosperi - 12-28-2017, 04:14 AM RE: Saving the state of HP41 CL to PC - hth - 12-28-2017, 06:44 AM RE: Saving the state of HP41 CL to PC - mfleming - 12-28-2017, 06:08 PM RE: Saving the state of HP41 CL to PC - hth - 12-28-2017, 04:06 AM RE: Saving the state of HP41 CL to PC - PeterP - 12-28-2017, 04:08 AM RE: Saving the state of HP41 CL to PC - hth - 12-28-2017, 06:39 AM RE: Saving the state of HP41 CL to PC - Ángel Martin - 12-29-2017, 07:07 AM RE: Saving the state of HP41 CL to PC - cdmackay - 03-08-2019, 03:41 AM RE: Saving the state of HP41 CL to PC - Ángel Martin - 03-08-2019, 06:19 AM RE: Saving the state of HP41 CL to PC - cdmackay - 03-08-2019, 08:28 AM RE: Saving the state of HP41 CL to PC - cdmackay - 02-15-2020, 03:42 PM

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