|Re: HP67 to HP41 Program conversion|
Message #4 Posted by Marwan Joury on 16 Sept 1999, 9:11 a.m.,
in response to message #3 by Randy Smith
I am not familiar with the routine you are trying to convert. But here are a couple of suggestions:
1 - Make sure that the program does not use Rapid Reverse Branching
2 - Use register 25 as the i register (that's what the card reader does and you will be consistent if you need to convert any other programs over.
3 - Does the program use P S? This command excahnges the primary registers (0-9) with the secondary registers and allows those to be addressed. You can only address registers 0-9 directly. Can't remeber whether indriect address gives you access. At any rate, if this function is being used and you have a card reader then simply use 7P S which is a built in card reader command. If you have a CX or an extended functions module you can fake this command by using REGSWAP. Otherwise you will either have to write a routine to fake it or you will have to go through the process of tracking all registers and manually changing the code to address 10-19 after P S has been executed in the listing.
4 - Remember that the 67 uses DSZ and ISZ not DSE and ISG as with the HP41.
5 - (i) is the same as RCL IND 25 (if you use 25 as the i register.
6 - The 67 uses DSP function that sets the display precision. The 41 uses FIX/SCI/ENG followed by a number.
I believe that for the most part everything else works the same way on both machines. There may be a few gotchas that I am missing, I am sure someone will jump in and help if that is the case.
If you do have the card reader what I would do is simply type it in as listed using the card reader emulation functions which have the same names as the 67 functions except that they are preceeded by a '7' (as in 7P S). The DSP functions are slightly different. There are 10 of these (??) and they are named 7DSP0 - 7DSP9. Once you have the thing working you can slowly convert over to be 100% HP41 compliant.
Hope this helps,