This works with devpac and vasm
http://sun.hasenbraten.de/vasm/Code:
list
** Ram and Rom size definitions
RAM_SIZE equ 16 18 bits of address - 2x 128K x 8 SRAMs
ROM_SIZE equ 18 18 bits of address - 2x 128K x 8 Flashroms
** Define memory segment size
MEMB_SIZE equ ROM_SIZE 18 bits = set to size of rom
** Define macros
MSTART MACRO ;size of block, start block
MSTEP set \1
MOFFSET set \2
ENDM
MBLOCK MACRO ;label
\1 equ MOFFSET<<MSTEP 0<<18, 1<<18, 2<<18, 3<<18 etc...
MOFFSET set MOFFSET+1
ENDM
** Memory map - 8 decoded segments
MSTART MEMB_SIZE,0
MBLOCK ROM_BLK
MBLOCK NULL1_BLK
MBLOCK RAM_BLK
MBLOCK NULL3_BLK
MBLOCK DUART_BLK
MBLOCK NULL5_BLK
MBLOCK NULL6_BLK
MBLOCK NULL7_BLK
ORG $1000
START: ; first instruction of program
lea ROM_BLK,a0
lea RAM_BLK,a1
MOVE.B #9,D0
TRAP #15 ; halt simulator
* Variables and Strings
END START ; last line of source