home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Crawly Crypt Collection 2
/
crawlyvol2.bin
/
utility
/
disk
/
diskedit
/
diskedit.doc
next >
Wrap
Text File
|
1985-11-17
|
15KB
|
597 lines
DiskEdit Version 1.0
DiskEdit is a disk editor for the Atari 520 ST. DiskEdit
allows you to peek and poke around your disks in file mode or BIOS
sector mode . The ability to view and modify the disk using XBIOS
(hardware) parameters is also supported. DiskEdit may also work on
the 1040 ST however since I only own a 520 ST, I wouldn't know.
DiskEdit was developed rather cheaply from a development
tools perspective. It was written in 68000 assemblers using the A-
Seka assembler from Kuma. The documentation was prepared using
1st Word and the header screen was created using doodle.prg both
of which were included with the purchase of the 520 ST. The Seka
assembler was purchased for approximatly $35.00 through Antic.
The reason I put DiskEdit in the public domain was so I
could have a clear conscience the next time I download a public
domain utility.
Version 1.0 of DiskEdit is a bare-bones version supporting
only the BIOS sector mode of operation. I have tested it by using
it, however as with most programs, it may still be hiding a bug or
two. If you should uncover any bugs please inform me so I may fix
them and save others the trouble, but please, no threatening or
obscene phone calls as I get turned-on rather easily.
I may usually be reached evenings at 305-488-0721 or through
BIX mail as 'kks'. Good luck.
Ken Smith
DiskEdit
========
A Public Domain Disk Editor for the Atari 520 ST
By
Ken Smith (kks)
2/21/87
Table of Contents
=================
Section Page
----------------------------------------------------------------
1.0 Introduction ........................ 1
2.0 Operation ........................ 1
3.0 Screen Layout ........................ 1
3.1 Hex Data Area ........................ 1
3.2 ASCII Data Area ........................ 2
3.3 Sector Number Area ........................ 2
3.4 Error Line ........................ 2
3.5 25th Line ........................ 2
4.0 General Usage ........................ 2
5.0 Function Key Usage ........................ 3
5.1 Help (F1) ........................ 3
5.2 File Mode (F2) ........................ 3
5.3 BIOS Sector Mode (F3) ........................ 3
5.4 XBIOS Mode (F4) ........................ 3
5.5 Directory Mode (F5) ........................ 3
5.6 Write Sector to Disk (F6) ........................ 3
5.7 Display Next Sector (F7) ........................ 4
5.8 Display Previous Sector (F8) ........................ 4
5.9 Extra Options Menu (F9) ........................ 4
5.10 Return to Desktop (F10) ........................ 4
6.0 Direct Sector Access ........................ 4
6.1 Error Handling ........................ 5
Figure 1 ........................ 6
1.0 Introduction
DiskEdit is a diskette editor for the Atari 520 ST. Though it
was developed on and for the Atari ST line of computers, it uses
no GEM specific functions and may be ported rather easily to other
68000 based machines.
Three files are supplied, DiskEdit.tos the executable file,
DiskEdit.doo the header file and DiskEdit.doc the user manual. The
header file and user manual are not necessary and may be removed
if disk space is scarce. Monochrome owners may have to remove
DiskEdit.doo in order to avoid screen RAM problems.
To run DiskEdit simply double-click DiskEdit.tos from the
desktop or enter DiskEdit.tos from the command shell, etc. etc..
DiskEdit takes no parameters and should run in medium resolution
however monochrome may also work.
2.0 Operation
When DiskEdit is first loaded it attempts to read the
DiskEdit.doo header file from the default drive into screen RAM
(which is assumed to be located at address $78000 hex). If
DiskEdit can't find the file DiskEdit.doo on the default drive in
the current directory or if a read error occurs while accessing
this file, DiskEdit displays a warning message. The user is then
prompted to press any key to continue. Once a key is pressed the
CRT is cleared and the BIOS sector mode screen is displayed.
DiskEdit then attempts to read (BIOS) sector 0 from the default
drive. If the read is successfull then the first half of the
sector is dislayed. If an error occurs the user is informed and
the contents of the memory buffer is displayed instead. This is
the worst problem that could happen as far as DiskEdit is
concerned because the sector buffer is in an unknown state. A
successfull write at this time will almost certainly trash your
disk. It is recommended that you first find a good sector before
proceeding. This may be accomplished by repeatedly pressing the F7
key until a valid sector read occurs.
3.0 Screen Layout
The basic screen design consists of five areas as depicted in
figure 1. Please note only half of the sector is displayed at any
given time.
3.1 Hex Data Area
The hex data area (figure 1, section A) is where the current
sector data is dislayed and modified in hexadecimal format. This
area is divided into 128 word (16 bit) fileds. These 128 fields
are organized 8 fields per line by 16 lines. Entering any valid
hex nibble while in this area will modify the sector memory
buffer.
1
3.2 ASCII Data Area
The ASCII data area (figure 1, section B) is where the
current sector data is displayed as ASCII characters. Hex values
greater than 7F (128 decimal) or less than 21 (decimal 33) are
displayed as periods ("."). As might be expected, the 16
characters to the right are the ASCII representation of the 16
bytes displayed to the left in the hex data area. Modifying data
in the ASCII area is currently not supported. The ASCII data area
is organized as 16 characters by 16 lines.
3.3 Sector Number Area
The sector number area (figure 1, section C) is where the
current sector number is displayed and modified. The sector number
is always displayed as four hex nibbles and represents the sector
number of the data currently in the buffer. Direct access to any
sector is achieved by modifying this field.
3.4 Error Line
The error line (figure 1, section D) is located below the
23rd line (the sector number line). Any time an error occurs the
error code and a prompt message is displayed on this line. The
user must then press any key to clear off the error line and
continue.
3.5 25th Line
The 25th line always displays the abbreviated names of the
operations associated with the various function keys. The current
operating mode is displayed in reverese video on this line also.
4.0 General Usage
DiskEdit is a function key based system. This means that most
operations are initiated using the function keys. The 25th line
shows the relationship between the function keys and their
corresponding operations. Some function keys do nothing when
pressed. This indicates a (dead) function key which is not yet
implemented.
The cursor may be located in one of two basic areas as
described above, either the hex data area or the sector number
area.
When the cursor is located in the sector number area the left
and right arrow keys may be used to move the cursor. Entering a
valid hexadecimal nibble while in the sector number field will
cause a new sector to be read into the sector buffer and
displayed. Note that sectors read in this fashion will always have
the first half of the sector buffer displayed after the read.
2
When the cursor is located in the hex data area the four
arrow keys are available for re-positioning the cursor. Entering a
valid hexadecimal nibble will modify the data currently in the
sector buffer. The modified data will not be written to the disk
however until the F6 key (write current sector to disk) is
pressed. If you read a new sector into the sector buffer before
writing it out to disk, the modifications will be lost.
The escape key is used to toggle the cursor between these two
areas.
5.0 Function Key Usage
5.1 Help (F1)
Pressing the F1 key will cause the help screen to be
displayed. The current environment will be retained. Pressing any
key will cause the help screen to be cleared and the previous
contents of the CRT will be restored to its previous state.
5.2 File Mode (F2)
This function is currently not available.
5.3 BIOS Sector Mode (F3)
Pressing the F3 key will cause DiskEdit to enter the BIOS
sector mode of operation. While in BIOS sector mode DiskEdit
treats the disk as a collection of BIOS organized sectors.
Currently, this is the only sector mode supported.
5.4 XBIOS Mode (F4)
This mode is currently not available.
5.5 Directory Mode (F5)
This mode is currently not supported
5.6 Write Sector to Disk (F6)
Pressing the F6 key will cause the current contents of the
sector buffer to be written to disk at the sector number displayed
in the sector number field.
3
5.7 Display Next Sector (F7)
Pressing the F7 key will cause the next sequential half
sector to be displayed. If the second half of the current sector
is already on the screen then the next sequential sector will be
read into the sector buffer and the first half of the new sector
will be displayed. If the first half of the current sector is
displayed on the CRT then pressing the F7 key will cause the
second half of the sector to be displayed and no read will occur.
5.8 Display Previous Sector (F8)
F8 represents the inverse of F7. Pressing the F8 key will
cause the previous half sector to be displayed. If the first half
of the current sector is already on the screen the the previous
sector will be read into the sector buffer and the second half of
the new sector will be displayed. If the second half of the
current sector is displayed on the CRT then pressing the F8 key
will cause the first half of the sector to be displayed and no
read will occur.
5.9 Dislay Extra Options Menu (F9)
This function is currently not supported
5.10 Exit Back to TOS (F10)
Pressing this key will cause DiskEdit to return to the
desktop or wherever it was called from. The color registers will
be restored before exiting from the program.
6.0 Direct Sector Access
Direct sector access occurs whenever a valid hex nibble is
entered while in the sector number field (figure 1, section C).
Each different nibble entered causes a new sector to be read into
the buffer. Unfortunatly due to the method of implementation in
order to read sector 25 (hex) from sector 0 (for example) two disk
reads will occur. Either sector five will be read first followed
by sector 25, or sector 20 (hex, 32 decimal) will be read first
followed by sector 25. Anytime a new sector is read into the
memory buffer using this method the first half of the sector will
be dislayed.
4
6.1 Error Handling
Currently all errors cause an error code and associated
prompt message to appear on the error line (figure 1, section D).
The user must then press any key to clear the error line and
continue. The previous sector number and buffer contents are
retained when an error occurs. The error codes displayed are the
GEMDOS, BIOS and XBIOS codes returned from the interrupt request.
You will have to refer to the appropriate documentation for
details regarding the meaning of these numbers. I don't own the
developers kit so I can't be of much assistance in this area. This
much I can tell you ....
1) When in BIOS sector mode, trap #13, function #4 is used to
read/write BIOS sectors.
2) When in XBIOS mode, trap #14, functions #8 and 9 are used.
3) When in file mode, trap #1, functions #$3D, $3E, $3F, $40
and $42 are used. File mode treats each file as a
collection of 256 byte blocks.
5
Figure 1
========
DiskEdit
--------
+00 +02 +04 +06 +08 +0A +0C +0E ASCII
---------------------------------------------------------------
(A) (B)
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
xxxx xxxx xxxx xxxx xxxx xxxx xxxx xxxx ................
---------------------------------------------------------------
(C)
Sector Number Currently Is: 0000
(D)
Error #FFFF occured, press any key to continue --->
(E)
F1=Help F2=File F3=BIOS F4=XBIOS F5=Dir F6=Write F7=Next F8=Prev
6