|★ APPLICATIONS ★ DIVERS ★ File Dump ★|
|File Dump|Computing With the Amstrad)||Applications Divers|
NO matter how careful you are, discs always seem to fill up with programs with obscure names like PROG1, PROG, MCODE, GAME, SPCINVDR and so on.
Of course we all try to give files meaningful names but there's a limit to what you can do with eight letters.
The only way to find out what the programs are is to load each one and list them. Of course it's even worse if the files are text files from a word processor as you have to either go into the word processor and load them or use CP/M's TYPE command to discover what's in them.
This can be time consuming and there's also the disadvantage that you lose the program currently in memory as well.
Dump is a short utility designed to get round this by letting you look at a file without actually loading it or disturbing the program in memory. When run, it stores some machine code above HIMEM which is moved down to &9FFF.
To list a text file CALL &A000,1, and to dump any other type of file CALL &A000 and you'll be prompted for the filename.
Don't forget the file extension if it isn't the normal .BAS or .BIN or . followed by a space. It's best in Modes 1 or 2 - Mode 0 is a bit too chunky. The file is dumped in both hexadecimal and Ascii.
You hold down Shift to pause the listing or dump and can end at any time by pressing Ctrl.
You should be able to see exactly what the file is from the output. Most Basic files have a few quite useful REMs at the start with the title of the program. Text files can be read of course.
The dump routine works by opening the file and reading it in a byte at a time. Each byte is printed in hex and, if it lies within the range 32 to 126, Ascii as well.
The Ascii version is similar except that there isn't any need for a hex output so all characters are printed.