home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Simtel MSDOS 1992 September
/
Simtel20_Sept92.cdr
/
msdos
/
microcrn
/
issue_43.arc
/
KAYPRO43.ARC
/
KAYPRO.3
next >
Wrap
Text File
|
1988-07-21
|
2KB
|
65 lines
; Micro Cornucopia issue #43
; Kaypro Column - Figure 3 MAP.ASM
;***********************************************
;* *
;*THIS SMALL PROGRAM GENERATES A CHARACTER *
;*TRANSLATION TABLE FOR THE KAYPRO CURSOR *
;*KEYS AND THE NUMERIC KEYPAD. IT INSTALLS THE *
;*TABLE INTO THE CP/M BIOS. THE TRANSLATION *
;*WILL REMAIN IN FORCE UNTIL THE NEXT COLD *
;*(NOT WARM) BOOT, OR UNTIL THE COMPLEMENTARY *
;*PROGRAM 'UNMAP' IS RUN. *
;* *
;***********************************************
; *** CHANGE THIS TO MATCH THE CP/M SIZE ***
SIZE EQU 63 ;CPM SIZE IN K
CBASE EQU SIZE*1024-1C00H;BEGINNING OF CCP
FBASE EQU CBASE + 800H ;BEGINNING OF BDOS
; *** OR CHANGE THIS TO MATCH YOUR BIOS ***
BIOS EQU CBASE + 1600H ;BEGINNING OF BIOS
VTAB EQU BIOS+35H;BEGINNING OF PARAMETERS
ORG 100H
MAPKEY: LXI H, MAP;ADDRESS TRANSLATION TABLE
LXI D, VTAB ;ADDRESS CP/M BIOS TABLE
MVI B, 18 ;SET BYTE COUNT
LOOP: MOV A, M ;COPY TABLE INTO BIOS
STAX D
INX H
INX D
DCR B
JNZ LOOP
RET ;RETURN TO CCP
;
; TRANSLATION TABLE TO BE LOADED
;
MAP: DB 'E'-'@' ;UP ARROW( ^E )
DB 'X'-'@' ;DOWN ARROW( ^X )
DB 'S'-'@' ;LEFT ARROW( ^S )
DB 'D'-'@' ;RIGHT ARROW( ^D )
DB 'Q'-'@' ;NUM KEY '0'( ^Q )
DB 'Z'-'@' ;NUM KEY '1'( ^Z )
DB 'C'-'@' ;NUM KEY '2'( ^C )
DB 'B'-'@' ;NUM KEY '3'( ^B )
DB 'A'-'@' ;NUM KEY '4'( ^A )
DB 'L'-'@' ;NUM KEY '5'( ^L )
DB 'F'-'@' ;NUM KEY '6'( ^F )
DB 'W'-'@' ;NUM KEY '7'( ^W )
DB 'R'-'@' ;NUM KEY '8'( ^R )
DB 'T'-'@' ;NUM KEY '9'( ^T )
DB 'Y'-'@' ;NUM KEY '-'( ^Y )
DB 'G'-'@' ;NUM KEY ','( ^G )
DB 'K'-'@' ;NUM KEY 'ENTER'( ^K )
DB 'V'-'@' ;NUM KEY '.'( ^V )
END