;:sys36864 ;.opt oo *= 49152 temp = 2 reg = 181 fremevl = $ad9e komma = $aefd frestr = $b6a3 stradr = $22 strich = "-" punkt = "." fehler = $a445 chrout = $ffd2 rvs = 199 sid = 54272 reg2 = 182 space = $ab3f return = $aad7 wave = 33 long = 180 short = 60 reg3 = 4 temp2 = 5 latch = 51200 reg4 = 255 jmp exec text .byte "csavpdkrbtflwo" adre .word clear,show,alfab,veloc,play,uncode,cursor,reset .word farben,titel,function,return,wbuffer,code table .byte "\x01\x02\x03" .byte "\x02\x01\x01\x01\x03" .byte "\x02\x01\x02\x01\x03" .byte "\x02\x01\x01\x03" .byte "\x01\x03" .byte "\x01\x01\x02\x01\x03" .byte "\x02\x02\x01\x03" .byte "\x01\x01\x01\x01\x03" .byte "\x01\x01\x03" .byte "\x01\x02\x02\x02\x03" .byte "\x02\x01\x02\x03" .byte "\x01\x02\x01\x01\x03" .byte "\x02\x02\x03" .byte "\x02\x01\x03" .byte "\x02\x02\x02\x03" .byte "\x01\x02\x02\x01\x03" .byte "\x02\x02\x01\x02\x03" .byte "\x01\x02\x01\x03" .byte "\x01\x01\x01\x03" .byte "\x02\x03" .byte "\x01\x01\x02\x03" .byte "\x01\x01\x01\x02\x03" .byte "\x01\x02\x02\x03" .byte "\x02\x01\x01\x02\x03" .byte "\x02\x01\x02\x02\x03" .byte "\x02\x02\x01\x01\x03" .byte "\x02\x02\x02\x02\x02\x03" .byte "\x01\x02\x02\x02\x02\x03" .byte "\x01\x01\x02\x02\x02\x03" .byte "\x01\x01\x01\x02\x02\x03" .byte "\x01\x01\x01\x01\x02\x03" .byte "\x01\x01\x01\x01\x01\x03" .byte "\x02\x01\x01\x01\x01\x03" .byte "\x02\x02\x01\x01\x01\x03" .byte "\x02\x02\x02\x01\x01\x03" .byte "\x02\x02\x02\x02\x01\x03" .byte "\x01\x02\x01\x02\x01\x02\x03" .byte "\x02\x02\x01\x01\x02\x02\x03" .byte "\x01\x02\x02\x02\x02\x01\x03" .byte "\x02\x02\x02\x01\x01\x01\x03" .byte "\x02\x01\x01\x01\x01\x02\x03" .byte "\x02\x01\x02\x02\x01\x02\x03" .byte "\x01\x01\x02\x02\x01\x01\x03" .byte "\x02\x01\x01\x01\x02\x03" err .byte "missing spacE" undef = $a8e3 und .byte "invalid morsecodE" zeile = 214 spalte = 211 setcr = 58732 maxs = 40 maxz = 25 illqu .byte "illegal koordinatS" reset = 64738 error .byte "string too shorT" cint = $ff81 vic = $d000 frame = vic+32 screen = vic+33 ink = 646 strout = $ab1e title .byte "\x93\x08\x9a **** nig software service nss ****" .byt 13 .byte "\x11 \x96 morsesystem v3" .byt 13 .byte "\x11\x1e - written by\x9e nicki heusler\x1e nov. 1985 -\x9f\x11" .byt 13,0 fu .byte "funktion:" .byt 0 chrgot = 121 toolong = $a571 buffer = 631 maxl = 649 moml = 198 len = 254 codes .byte "abcdefghijklmnopqrstuv" .byte "wxyz0123456789.,':-(?=" getnr ldy #getnr-codes-1 comp cmp codes,y beq found dey bpl comp clc rts found sec rts getadr tya tax lda #< table sta temp lda #> table sta temp+1 go cpx #0 beq found ldy #0 go2 lda (temp),y cmp #3 beq next iny jmp go2 next dex iny sty reg lda temp clc adc reg bcc noinc inc temp+1 noinc sta temp jmp go out jsr getnr bcc rt jsr getadr ldy #0 l1 lda (temp),y cmp #3 bne norts sec rt rts norts cmp #2 bne pu dotset lda #strich prin jsr chrout iny jmp l1 pu lda #punkt jmp prin getstr jsr komma jsr fremevl jsr frestr sta len cmp #0 bne rt tooshort lda #< error sta stradr lda #> error jmp fehler exec jsr getstr ldy #0 lda (stradr),y ldy #adre-text-1 cm cmp text,y beq gefunden dey bpl cm jmp undef gefunden tya asl tax lda adre,x sta temp lda adre+1,x sta temp+1 jmp state clear ldx #24 lda #0 clp sta sid,x dex bpl clp rts show jsr check ldy #1 slp lda (stradr),y sty reg2 jsr out php jsr space ldy reg2 plp bcs noerr lda #"?" sta (stradr),y noerr iny cpy len bcc slp rts alfab ldy #0 alp sty reg2 lda codes,y jsr chrout jsr space ldy reg2 lda codes,y jsr out jsr return ldy reg2 iny cpy #getnr-codes bcc alp rts veloc jsr check ldy #1 lda (stradr),y sta vel+1 rts wait pha tya pha vel ldy #100 dy lda #3 da sec sbc #1 bne da dey bne dy dex bne vel pla tay pla rts wait1 ldx #short .byt $2c wait2 ldx #long jmp wait on lda #200 sta sid+1 lda #240 sta sid+6 lda #9 sta sid+5 lda #wave sta sid+4 rts off lda #0 ldx #7 sss sta sid,x dex bpl sss rts laut lda #15 sta sid+24 rts leise lda #0 sta sid+24 gut rts point jsr on jsr wait1 jmp off dot jsr on jsr wait2 jmp off check lda len cmp #1 bne gut jmp tooshort playout jsr getnr bcc gut jsr getadr ldy #0 l9 lda (temp),y sty reg3 cmp #3 bne weiter sec rts weiter cmp #2 bne pkt jsr dot all ldy reg3 iny jsr wait1 jmp l9 pkt jsr point jmp all play jsr check ldy #1 jsr laut plo lda (stradr),y sty reg2 jsr playout php jsr wait1 ldy reg2 plp bcs kerr lda #"?" sta (stradr),y kerr iny cpy len bcc plo jmp leise decode ldy #0 hms lda latch,y beq end cmp #32 bne pustri lda #3 jmp mhs pustri cmp #punkt bne stri lda #1 mhs sta latch,y iny jmp hms stri lda #2 jmp mhs end ldx #0 stx reg stx reg3 qwe ldy #0 sty reg4 lda #< table sta temp lda #> table sta temp+1 rty ldx reg lda latch,x beq totalend nextone lda (temp),y cmp latch,x bne other cmp #3 beq faund iny inx jmp nextone other lda (temp),y iny cmp #3 bne other sty reg2 lda temp clc adc reg2 bcc noinc2 inc temp+1 noinc2 sta temp ldx reg4 inx stx reg4 ldy #0 cpx #getnr-codes bcc rty lda #< und sta stradr lda #> und jmp fehler faund inx stx reg ldx reg4 lda codes,x ldx reg3 inc reg3 sta latch,x jmp qwe totalend ldx reg3 lda #0 sta latch,x spac rts uncode jsr getspac ldx #0 ldy #1 copy1 lda (stradr),y sta latch,x inx iny cpy len bcc copy1 lda #0 sta latch,x jsr decode jmp write getspac jsr check ldy len dey lda (stradr),y cmp #" " beq spac lda #< err sta stradr lda #> err jmp fehler write ldy #0 wri lda latch,y beq wr2 sta (stradr),y iny bne wri wr2 lda #" " wr3 cpy len beq spac sta (stradr),y iny jmp wr3 cursor jsr check ldy #1 lda (stradr),y cmp #maxz bcs illq sta zeile iny lda (stradr),y cmp #maxs bcs illq sta spalte jmp setcr illq lda #< illqu sta stradr lda #> illqu jmp fehler farben jsr check jsr cint ldy #1 lda (stradr),y sta frame iny lda (stradr),y sta screen iny lda (stradr),y sta ink fende rts titel jsr cint lda #0 sta frame sta screen lda #