Post Reply 
Another stupid 41C question
10-20-2016, 06:53 PM
Post: #1
Another stupid 41C question
Is the .RAW file format documented anywhere? If I download something to the 41CL I need to know how to massage the data to get everything lined up properly. Or is this even possible?

Monte
Visit this user's website Find all posts by this user
Quote this message in a reply
10-20-2016, 07:17 PM (This post was last modified: 10-20-2016 07:21 PM by JurgenRo.)
Post: #2
RE: Another stupid 41C question
(10-20-2016 06:53 PM)Monte Dalrymple Wrote:  Is the .RAW file format documented anywhere? If I download something to the 41CL I need to know how to massage the data to get everything lined up properly. Or is this even possible?

Monte

Hi Monte,
see the README file in http://www.hpmuseum.org/software/hp41uc.zip . On page 4 you find a section called RAW-Format. The link is from the site http://hp41programs.yolasite.com/. Don't know if this is what you are looking for ...
Juergen
Find all posts by this user
Quote this message in a reply
10-20-2016, 08:11 PM
Post: #3
RE: Another stupid 41C question
I believe the RAW format comes from dumping the actual bytes stored in memory.
Thus, you may find extra NULLs, and the last instruction may be either an END or the special .END.

A .RAW file need massaging to get it right if loaded back to memory. The main problem is the global chain that has to be built properly. You can study GETP in Extended functions module. That code works on the assumption that if the checksum is correct, the saved link chain is intact so it can be used to find the global LBLs. It updates the global link chain when loading the program.

Håkan
Find all posts by this user
Quote this message in a reply
10-20-2016, 09:01 PM
Post: #4
RE: Another stupid 41C question
Monte,
the direct link seems not to function. So, I've copied the respective text excerpt for your convenience:

Quote:RAW Format: Page 4
==========

[compiled code] + [1-byte checksum] + [trailer]
[1-byte checksum] - sum of all [compiled code] bytes
[trailer] - filler bytes, so that filesize = multiple 256-byte blocks

Usage: optional parameters are surrounded by <>

RAW file(s) to LIF file ( LIF name = <name> or [infile] )
/r=infile<.raw> /l<=outfile.lif> <name>

If output file is specified, [infile] can be a directory of RAW files.
For example: hp41uc /r=\rawdir\*.raw /l=hpil.lif

RAW file to P41 file ( P41 name = <name> or [infile] )
/r=infile<.raw> /p<=outfile.p41> <name>

RAW file to BIN file
/r=infile<.raw> /b<=outfile.bin>

RAW file to DAT file ( hex digits in ASCII form )
/r=infile<.raw> /d<=outfile.dat>

RAW file to TXT file ( de-compile )
/r=infile<.raw> /t<=outfile.txt> </a> </n> </x>

De-compiler Options:
/a - append text using: [ "Ãtext" ], instead of: [ >"text" ]
/n - generate line numbers
/x - use [ XROM mm,ff ] for all XROM Functions
/x23 - use [ XROM 23,ff ]: [ XROM 23,1 ], instead of [ COPYFL ]
/x25 - use [ XROM 25,ff ]: [ XROM 25,46 ], instead of [ X<>F ]
/x26 - use [ XROM 26,ff ]: [ XROM 26,10 ], instead of [ CLOCK ]
/x28 - use [ XROM 28,ff ]: [ XROM 28,27 ], instead of [ AUTOIO ]
Hope, this is of any use for you.
Juergen
Find all posts by this user
Quote this message in a reply
10-20-2016, 09:27 PM
Post: #5
RE: Another stupid 41C question
Thank you, Juergen and Hakan.
Now I can fire up my hex editor and figure out what I need to do.
Visit this user's website Find all posts by this user
Quote this message in a reply
10-22-2016, 06:10 PM (This post was last modified: 10-22-2016 09:40 PM by aurelio.)
Post: #6
RE: Another stupid 41C question
(10-20-2016 09:01 PM)JurgenRo Wrote:  Monte,
the direct link seems not to function.
Juergen

with the right button of the mouse you can download it, thank-you Juergen
EDIT: you download the zip but cannot open it.....
Find all posts by this user
Quote this message in a reply
10-23-2016, 07:52 PM
Post: #7
RE: Another stupid 41C question
(10-22-2016 06:10 PM)aurelio Wrote:  
(10-20-2016 09:01 PM)JurgenRo Wrote:  Monte,
the direct link seems not to function.
Juergen

with the right button of the mouse you can download it, thank-you Juergen
EDIT: you download the zip but cannot open it.....

Hi Aurelio,
yes, you're right! Thank you for the hint!
Juergen
Find all posts by this user
Quote this message in a reply
Post Reply 




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