1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
.TH MAKEATR,UNMAKATR "1" "April 2007" "makeatr, unmakatr" "Ken Siders' Atari 8-bit Tools"
.SH NAME
\fBmakeatr\fR \- convert an Atari executable to a "K-file" bootable disk
.br
\fBunmakatr\fR \- extract original executable from a disk made with \fBmakeatr\fR
.SH SYNOPSIS
\fBmakeatr\fR \fIimagefile.atr\fR \fIatari-exe\fR
.br
\fBunmakeatr\fR \fIimagefile.atr\fR \fIatari-exe\fR
.SH DESCRIPTION
For various reasons, it's sometimes useful to make a bootable disk image
of an Atari executable. \fBmakeatr\fR does exactly that.
.PP
If you have a bootable image made with \fBmakeatr\fR, but you've lost the
original executable, you can extract it from the image with \fBunmakatr\fR.
.PP
.SH NOTES
\fBmakeatr\fR is only useful for single\-file games or other programs that
don't need DOS disk access to run: the bootable image won't contain
any DOS at all, or even a DOS file structure (you can't read the directory).
.PP
\fBunmakatr\fR only works for images created by \fBmakeatr\fR. It is not
a general-purpose bootdisk-to-executable utility.
.PP
Disks made with \fBmakeatr\fR are recognizable when booted on the Atari,
because they display GR.0 screen with a lowercase \fIk\fR
(screen is otherwise blank).
.PP
Disk images made with \fBmakeatr\fR are only created with enough sectors
to hold the executable. AtariSIO can handle these images fine, as can
most other ATR utilities, but the smaller-than-regulation size may cause
problems with some utilities.
.PP
There is only one Atari executable format, regardless of filename extension.
All .XEX, .COM, .BIN, .EXE, etc. files for the Atari are the same file type,
regardless of the name, and regardless of what you may have read on some
forum site. Atari DOS doesn't care about the filename; it only exists for
human consumption (and for filetype association with emulators, these
days).
.SH DIAGNOSTICS
\fBmakeatr\fR's error messages are not well documented. They consist only
of an internal error number code, listed here:
.PP
.B 1
\- Unable to open ATR image for writing
.br
.B 2
\- Unable to write image ATR header
.br
.B 6
\- Unable to write boot sectors to ATR image
.br
.B 7
\- Error while padding ATR image to an even sector size
.br
.B 11
\- Unable to stat the input file (not found, permission denied, etc)
.br
.B 12
\- Input file is 0 bytes in length
.br
.B 13
\- Can't open input file
.br
.B 19
\- Error writing to ATR image, \fBor\fR trailing junk in the input image
.br
.B 20
\- Input file is not an Atari executable (missing 0xFF 0xFF signature)
.br
.PP
\fBunmakatr\fR reports "Error #0" for any and all errors it may encounter.
.PP
Both \fBmakeatr\fR and \fBunmakatr\fR return a 0 exit status to the caller
for success, or non-zero status for failure (and print one of the above
error messages, as well). Error messages are printed to standard \fBoutput\fR,
not standard error output.
.SH AUTHOR
Ken Siders <\fBatari8bit@columbus.rr.com\fR>
.PP
Man page by B. Watson <\fBurchlay@urchlay.com\fR>
.SH SEE ALSO
\&\fIatrdir\fR\|(1), \&\fIatrextr\fR\|(1), \&\fIsortatr\fR\|(1).
.PP
Ken Siders Atari 8-bit page:
.br
http://atari.ksiders.tzo.com/a8emulators.html
|