home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / assemblr / tools / pcmac / pcmac.asm < prev    next >
Assembly Source File  |  1991-05-22  |  2KB  |  76 lines

  1. #lib    <z80.lib>
  2. ;Screen management program
  3. ;some special things
  4. ;***************************************
  5.           org     32000
  6. ;Minden pont melle jobbra is tesz egyet
  7. duplicate_screen
  8.           ld      c,192
  9.           ld      hl,(buff1)
  10.           ld      hl,4000H
  11. out_loop
  12.           or      a
  13.           ld      b,32
  14. inn_loop
  15.           ld      a,(hl)
  16.           ld      d,a
  17.           rra
  18.           or      (hl)
  19.           ld      (hl),a
  20.           inc     hl
  21.           ld      a,d
  22.           rra
  23.           djnz    inn_loop
  24.           dec     c
  25.           jr      nz,out_loop
  26. ;****************************
  27.           ld      b,192
  28.           ld      c,0
  29. vertical_loop
  30.           push    bc
  31.           ld      a,c
  32.           call    adress_in_screen
  33.           push    hl
  34.           ld      de,buff1
  35.           ld      bc,32
  36.           ldir
  37.           pop     hl
  38.           ld      de,buff2
  39.           ld      b,32
  40. vertic_inn_lop
  41.           ld      a,(de)
  42.           or      (hl)
  43.           ld      (hl),a
  44.           inc     de
  45.           inc     hl
  46.           djnz    vertic_inn_lop
  47.           ld      bc,32
  48.           ld      hl,buff1
  49.           ld      de,buff2
  50.           ldir
  51.           pop     bc
  52.           inc     c
  53.           djnz    vertical_loop
  54.           ret
  55. adress_in_screen
  56.           ld      l,a
  57.           ld      h,0
  58.           add     hl,hl
  59.           ld      de,table
  60.           add     hl,de
  61.           ld      a,(hl)
  62.           inc     hl
  63.           ld      h,(hl)
  64.           ld      l,a
  65.           ret
  66.  
  67. buff1     db     32
  68. buff2     db     32
  69. table
  70.          dw 16384
  71.          dw 16640
  72.          dw 16896
  73.          dw 17152
  74.          dw 22496
  75.          dw    $
  76.