diff options
author | Christian A. Weber <chris@gna.ch> | 2020-06-27 02:24:42 +0200 |
---|---|---|
committer | Christian A. Weber <chris@gna.ch> | 2020-06-27 02:24:42 +0200 |
commit | f28d5fbd8071822a10f79452d756a11b90046aa5 (patch) | |
tree | 87edf9de6709665b5a15ca9d190abfa6c9590610 | |
parent | 027fa37a9297dd6bae37d347585ec2750706e010 (diff) | |
download | gameexec-f28d5fbd8071822a10f79452d756a11b90046aa5.tar.gz gameexec-f28d5fbd8071822a10f79452d756a11b90046aa5.tar.bz2 gameexec-f28d5fbd8071822a10f79452d756a11b90046aa5.zip |
SMSG-Macro kann jetzt bis 9 printf-Style-Parameter (thanks CHH!)
-rw-r--r-- | MyExec.i | 41 |
1 files changed, 35 insertions, 6 deletions
@@ -122,21 +122,50 @@ MSG MACRO ENDM ************************************************************************** -* SMSG "Text" gibt "Text" auf serial port aus +* SMSG <"Hello, %s!",a0> gibt Text mit printf-Argumenten auf serial port aus SMSG MACRO + IFND DEBUG + MEXIT + ENDC XREF _MyExecBase - bra.s .smsg1\@ -.smsg2\@: dc.b \1,0 + movem.l d0/d1/a0/a1/a6,-(SP) + bra.b .smsg1\@ +.smsg2\@: dc.b \1,13,10,0 EVEN -.smsg1\@: move.l a6,-(SP) +.smsg1\@: + IFGE NARG-9 + move.l \9,-(SP) + ENDC + IFGE NARG-8 + move.l \8,-(SP) + ENDC + IFGE NARG-7 + move.l \7,-(SP) + ENDC + IFGE NARG-6 + move.l \6,-(SP) + ENDC + IFGE NARG-5 + move.l \5,-(SP) + ENDC + IFGE NARG-4 + move.l \4,-(SP) + ENDC + IFGE NARG-3 + move.l \3,-(SP) + ENDC + IFGE NARG-2 + move.l \2,-(SP) + ENDC movea.l _MyExecBase,a6 pea .smsg2\@(PC) jsr meb_RawPrintf(a6) - addq.w #4,SP - move.l (SP)+,a6 + add.w #(NARG<<2),SP + movem.l (SP)+,d0/d1/a0/a1/a6 ENDM + ************************************************************************** * BTSTW: Testet ein Bit in einem WORD |