Command (CMD) File Generation
3-4
Generally, the
CMD
file header values are derived directly from the hex file
and
the
parameters shown above need
not
be included.
The
following situations, however,
require the use
of
GENCMD
parameters.
• Use the 8080 keyword whenever ASM-86
is
used
to
convert 8080
programs
that
have code
and
data
intermixed within a single 64K segment, regardless
of
the use
of
the
CSEG
and
DSEG
directives in the source program.
• Use
an
absolute address (A value) for any
group
which must be located
at
an
absolute location. Normally, this value
is
not
specified since
CP/M-86
cannot
generally ensure
that
the required memory region
is
available (in
which case the
CMD
file cannot be loaded). "
• Use the B value when
GENCMD
processes a hex file produced by Intel's
OH86
or
a similar utility
program
that
contains more
than
one group. The
output
from OH86 consists
of
a sequence
of
data
records with no informa-
tion to identify code,
data,
extra, stack,
or
auxiliary groups. The B value
marks the beginning address
of
the
group
named
by the keyword, causing
GENCMD
to
load
data
following this address
to
the
named
group (see the
examples
that
follow).
The
B value is normally used
to
mark
the
boundary
between code
and
data
segments when no segment information
is
included
in the hex file. Files
produced
by ASM -86
do
not
require the B value since
segment information
is
included in the hex file.
• The
minimum
memory value (M value)
is
included only when the hex
records
do
not
define the minimum memory requirements for the
named
group. Generally, the code group size
is
determined precisely by the
data
records loaded into the area.
That
is, the total space required for the
group
is
defined by
the
range between the lowest
and
highest
data
byte addresses.
The
data
group,
however, may contain
un
initialized storage
at
the end
of
the
group
and
thus
no
data
records
are
present in the hex file which define
the highest referenced
data
item. The highest address in the
data
group
should be defined within the source
program
by including "DBO" as the last
data
item. Alternatively, the M value
can
be included
to
allocate the
additional space
at
the end
of
the group. The stack, extra,
and
auxiliary
group sizes must be defined using the M value unless the highest addresses
within the groups are implicitly defined by
data
records in the hex file.