home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / KAYPRO / TROMPAT1.LBR / RIPATCH.AQM / RIPATCH.ASM
Assembly Source File  |  2000-06-30  |  1KB  |  74 lines

  1. ; RIPATCH.ASM 6-5-86 gsd
  2. ; Simple patch to RINSTALL for Kaypro Keyboard Arrow Keys
  3. ; Assembles with DRI MAC.COM
  4. ; These patches are intended to work with The Advent TurboROM.
  5. ; The patches simply swap the CP/M level arrow key definitions
  6. ; for MicroPRO type arrow key usage on start up of the program.
  7. ; On exit from the program the CP/M level definitiions are restored.
  8. ;
  9. ; All of the following files must be patched:
  10. ;
  11. ;    DATASTAR.COM
  12. ;    FORMGEN.COM
  13. ;    REDIT.COM
  14. ;    REPORT.COM
  15. ;    RINSTALL.COM
  16. ;
  17. ;
  18. ; USE DDT TO PATCH RINSTALL.COM:
  19. ;
  20. ; A>DDT RINSTALL.COM
  21. ; DDT VERS 2.2
  22. ; NEXT PC
  23. ; 7900 0100
  24. ; -IDSPATCH.HEX
  25. ; -R
  26. ; NEXT PC
  27. ; 7900 0100
  28. ; -G0
  29. ;
  30. ; Warm Boot 
  31. ; A>SAVE 120 RINSTALL.COM
  32. ;
  33.  
  34. djnz    macro addr
  35.     db 10h
  36.     db low addr-($+1)
  37.     endm
  38.  
  39.     org 0167h    ; id string RINSTALL.COM 1.03
  40.     db    '1.03'
  41.     org 2A7h
  42. ;
  43. inisub:    jmp    morpat
  44. ;
  45. unisub: jmp    morpat
  46.  
  47.     org 2deh
  48. ;
  49. morpat:    lhld    0001        ; GET WARM BOOT JMP ADDR
  50.     lxi    d,32h        ; offset to xlate table
  51.     dad    d        ; hl --> xlate table (bios) 
  52.     lxi    d,table        ; de --> xlate table (local)
  53.     mvi    b,4        ; count 
  54. ;
  55. loop:                ; repeat
  56.     mov    c,m        ;   swap *hl,*de
  57.     ldax    d
  58.     mov    m,a
  59.     mov    a,c
  60.     stax    d
  61.     inx    h        ;   hl++, de++
  62.     inx    d
  63.     djnz    loop        ; unitl bytes swaped
  64.         ret
  65. ;
  66. table:    db    'E'-40h        ; up arrow
  67.     db    'X'-40h        ; down arrow
  68.     db    'S'-40h        ; left arrow
  69.     db    'D'-40H        ; right arrow
  70.  
  71.     end
  72.  
  73.