mirror of
https://github.com/cc65/cc65.git
synced 2024-12-28 22:30:12 +00:00
document how to return from assembly sim65 test
This commit is contained in:
parent
3419cbd348
commit
7f0baff792
@ -126,9 +126,17 @@ a set of built-in paravirtualization functions (<ref id="paravirt-internal" name
|
|||||||
<sect>Creating a Test in Assembly<p>
|
<sect>Creating a Test in Assembly<p>
|
||||||
|
|
||||||
Assembly tests may similarly be assembled and linked with
|
Assembly tests may similarly be assembled and linked with
|
||||||
<tt/--target sim6502/ or <tt/--target sim65c02/,
|
<tt/--target sim6502/ or <tt/--target sim65c02/.
|
||||||
and the sim65 library provides an <tt/exit/ symbol that the program may <tt/JMP/
|
Define and export <tt/_main/ as an entry point,
|
||||||
to terminate with the current A register value as an exit code.
|
and the sim65 library provides two ways to return an 8-bit exit code:
|
||||||
|
|
||||||
|
<itemize>
|
||||||
|
|
||||||
|
<item>Return from <tt/_main/ with the exit code in <tt/A/.
|
||||||
|
|
||||||
|
<item><tt/jmp exit/ with the code in <tt/A/.
|
||||||
|
|
||||||
|
</itemize>
|
||||||
|
|
||||||
The binary file has a 12 byte header:
|
The binary file has a 12 byte header:
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user