alberthdev / spasm-ng

SPASM-ng is a z80 assembler with extra features to support development for TI calculators.
GNU General Public License v2.0
97 stars 23 forks source link

24 bit jump? #59

Closed s5bug closed 4 years ago

s5bug commented 4 years ago

The 3rd instruction after disassembling my CE rom with zdis is jp.lil $000e4f which spasm doesn't recognize. What's the replacement? Doing .ASSUME ADL=1 and then just jp throws the same error.

jacobly0 commented 4 years ago

If you want to assemble ez80 code you have to pass the -E = Assemble eZ80 code flag.

s5bug commented 4 years ago

I am passing -E: image

s5bug commented 4 years ago

Here's cehead.asm:

.ASSUME ADL=1
di
rsmix
jp.lil $000e4f
di
rsmix
jp.lil $0015f5
di
rsmix
jp.lil $020110
di
rsmix
jp.lil $020114
di
rsmix
jp.lil $020118
di
rsmix
jp.lil $02011c
di
rsmix
jp.lil $020120
ex af, af'
exx
push ix
push iy
jacobly0 commented 4 years ago

Spasm requires every line containing an instruction to start with whitespace, for which one tab is usually used. For a modern, more powerful, ez80 assembler with fewer bugs, more features, and that doesn't have this restriction, there's also fasmg as an alternative.

s5bug commented 4 years ago

Sounds good, I think I'll use fasm then.

jacobly0 commented 4 years ago

If you have more general fasmg and/or ez80 questions I would suggest asking on the EFNet IRC #ez80-dev channel.