Motorola M68CPU32BUG Uživatelský manuál Strana 32

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 98
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 31
DEBUG MONITOR COMMANDS
M68CPU32BUG/D REV 1 3-32
LO Load S-Records From Host LO
Other options:
-C Ignore checksum. A checksum for the data contained within an S-record is
calculated as the S-record is read in through the port. Normally this calculated
checksum is compared to the checksum contained within the S-record. If the
compare fails, an error message is sent to the screen on completion of the
download. If this option is selected, then the comparison is not made.
X Echo. As the S-records are read in at the host port, they are echoed to the user’s
terminal. Do not use this option when port 0 is specified.
T TRAP #15 code. This option causes LO to set the target register D4 = ’LO’x, with
x = $0C ($4C4F200C). The ASCII string ’LO’ indicates that this is the LO
command; the code $0C indicates TRAP #15 support with stack parameter/result
passing and TRAP #15 disk support. This code is used by the downloaded
program to select the appropriate calling convention when executing debugger
functions. Since some Motorola debuggers use conventions different from
CPU32Bug, they set a different code in D4.
The S-record format (refer to Appendix A) allows a specified entry point in the address field of
the S-record-block termination record. The contents of the termination-record address field (plus
any offset address) is put into the target PC. Thus after a download the user need only enter G or
GO instead of G <addr> or GO <addr> to execute the downloaded code.
If a non-hex character is encountered within the data field of a data record, then that part of the
record, preceeding the non-hex character, is displayed. This causes the CPU32Bug error handler
to point at the faulty character.
An error condition exists if the embedded-record checksum does not agree with the checksum
calculated by CPU32Bug. An output message displays the address of the record (as obtained
from the address field of the record), the calculated checksum, and the checksum read with the
record. A copy of the record is also output. A checksum error is a fatal error and causes the
command to abort.
When a load is in progress, each data byte is written to memory and then the contents of this
memory location are compared to the data to determine if the data is stored properly. If for some
reason the compare fails, then an output message displays the address where the data was to be
stored, the data written, and the data read back during the compare. This is also a fatal error and
causes the command to abort.
S-records are processed character-by-character. So if the command aborts due to an error, all data
stored previous to the error is still in memory .
DEBUG MONITOR COMMANDS
M68CPU32BUG/D REV 1 3-33
LO Load S-Records From Host LO
EXAMPLES Suppose a host computer was used to create a program that looks like this:
1 * Test Program.
2*
3 65004000 ORG $65004000
4
5 65004000 7001 MOVEQ.L #1,D0
6 65004002 D088 ADD.L A0,D0
7 65004004 4A00 TST.B D0
8 65004006 4E75 RTS
9 END
****** TOTAL ERRORS 0--
****** TOTAL WARNINGS 0--
Then this program was converted into an S-record file named TEST.MX as follows:
S00F00005445535453335337202001015E
S30D650040007001D0884A004E7577
S7056500400055
Load this file into BCC memory for execution at address $4000 as follows:
CPU32Bug>LO -65000000<CR>
Blank line as the BCC waits for an S-record.
Enter the terminal emulator’s escape key to return to the host computer’s operating system (ALT-
F4 for ProComm). A host command is then entered to send the S-record file to the port where the
BCC is connected (for MS-DOS based host computer this would be "type test.mx >com1", where
the BCC was connected to the com1 port).
After the file has been sent, the user then restarts the terminal emulation program (for MS-DOS
based host computers, enter EXIT at the prompt).
Since the port number equals the current terminal, two <CR>’s are required to signal CPU32Bug
that the download is complete and the terminal emulation program is ready to receive any error
messages.
<CR><CR> Signal download completion.
CPU32Bug> No error messages.
Fr
eescale S
emiconduct
or
, I
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
nc...
Zobrazit stránku 31
1 2 ... 27 28 29 30 31 32 33 34 35 36 37 ... 97 98

Komentáře k této Příručce

Žádné komentáře