This afternoon, I ported a program I wrote for z80 TI's a few months ago.
It's a zoomIN2x function (magnify the graphical screen twice).

This routine doesn't require any argument, and uses only the 1st buffer (from $d40000 to $d52c00)

Code:
                push    iy
                ld      de,$d40000+19280
                ld      hl,$d40000
                ld      bc,160
                ld      iyl,60
LoopH60:          ld      b,c
LoopW160:       ld      a,(de)
                inc     de
                ld      (hl),a
                inc     hl
                ld      (hl),a
                inc     hl
                djnz    LoopW160
                ex      de,hl
                add     hl,bc
                ex      de,hl
                add     hl,bc
                add     hl,bc
                dec     iyl
                jr      nz,LoopH60
                ld      de,$d40000+57519
                ld      hl,$d40000+76799
                ld      iyl,60
LoopH60_2:        ld      b,c
LoopW160_2:     ld      a,(de)
                dec     de
                ld      (hl),a
                dec     hl
                ld      (hl),a
                dec     hl
                djnz    LoopW160_2
                ex      de,hl
                sbc     hl,bc
                ex      de,hl
                sbc     hl,bc
                sbc     hl,bc
                dec     iyl
                jr      nz,LoopH60_2
                ld      de,$d40000
                ld      hl,$d40000+320
                ld      a,60
                ld      b,h
                ld      c,l
LoopVenetian:   ex      de,hl
                ldir
                inc     b
                ld      c,$40
                add     hl,bc
                add     hl,bc
                dec     a
                jr      nz,LoopVenetian
                ld      a,60
LoopVenetian_2: ldir
                inc     b
                ld      c,$40
                ex      de,hl
                add     hl,bc
                add     hl,bc
                dec     a
                jr      nz,LoopVenetian_2
                pop iy
                ret
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement