User guide

String codes
You can ‘embed’ special sequences within strings:
\r Insert an &0D byte (linefeed)
\n Insert an &0A byte (newline)
\" Insert a double quote
\' Insert a single quote
\x## Insert a hex code directly (
i.e. \x07 for TTY bell
)
\d### Insert a decimal code directly (
i.e. \d169 for © symbol
)
\0 Insert a null byte
\\ Insert a backslash
This has been taken from the C method of inserting codes into strings...
My so-called example
We will create a file called “mybios.s65”. It contains a very stripped-down EPROM image, basically to save
cluttering up this document with a lot of trivialities!
; example BIOS code (based upon Amélie)
;
; To be compiled with 6502asm
; http://www.heyrick.co.uk/amelie/
;
ROM ; base & org = &E000, top = &FFFF,
; inserts vector links
; P A G E Z E R O
; =================
;
; Data labels live here, but no tables or code can reside here...
ORG &0020 ; at +32 we have various BIOS locations
; WATCHDOG:
; Application code MUST periodically reset this to zero.
.watchdog
DCB 0
; ******* much stuff omitted *******
6502asm user guide – prerelease version
page 16