Z80 Assembler for CP/M or ZSDOS

199 views
Skip to first unread message

Sergey Kiselev

unread,
May 9, 2024, 5:55:15 PM5/9/24
to retro-comp
I am looking for a Z80 assembler that can be run under CP/M or ZSDOS.
Something similar to ASM.COM... but with Z80 mnemonics and Z80-specific instructions :)

Looks like there is ZSM, with at least a few versions of it around:

Are there any other Z80 assemblers you'd recommend?

Thanks,
Sergey

Bill McMullen

unread,
May 9, 2024, 6:03:41 PM5/9/24
to retro-comp
My preference for Z80 assembler code is to use Microsoft's M80 / L80.  The reason is simply that it is quite commonly available, has a rudimentary macro facility and also the .PHASE / .DEPHASE instructions which are really handy for moving code around such as from ROM to RAM.

For CP/M .COM programs I created an ASM.SUB file with the following:

M80 $1.REL,$1.LST=$1.ASM
L80 $1.REL,$1.COM/N/E

Most of my programs start with:

 .Z80
 ASEG
 ORG 100h

Tadeusz Pycio

unread,
May 9, 2024, 6:32:01 PM5/9/24
to retro-comp
I've been using ZSM4 for a long time and have no complaints, except that I don't know how to build the padding in the relocated code (interrupt table position) - so it generates an error for me during compilation, although the resulting code is correct. This annoys me a bit when building MP/M, but I have not been able to find a solution. Its great advantage is that it supports the Z80,Z180 and Z280.

Wayne Hortensius

unread,
May 9, 2024, 7:00:24 PM5/9/24
to retro...@googlegroups.com
I'll put in a plug for A.E. Hawley's ZMAC. It may be getting up there,
but it does what I need it to.

http://cpmarchives.classiccmp.org//cpm/Software/WalnutCD/cpm/utils/asmutl/zmac17.lbr

It's very expansive in its support of various psuedo op styles.
Combine it with the ZDE editor, which looks in the ZCPR queue registers
for line numbers, and ZMAC putting the line numbers of any errors in
those registers, and edit/assemble/edit cycles are a breeze.

And it doesn't hurt that the identically named but from a completely
different source ZMAC assembler that runs under Linux will assemble the
same source as Hawley's ZMAC running under ZSDOS.

Wayne
Reply all
Reply to author
Forward
0 new messages