TITLE FK203 - ASSEMBLER PROGRAM TO SET FUNCTION KEYS IN DOS 2.0
;
;
;               Version 1.3 03/31/83
;        Version 1.3 moves the DOS 'copy previous' (F3) to the
;              'end' key on the numeric/cursor keypad
;
;
; Assemble with MASM
; Then LINK it with   LINK FK203; (or whatever you want to call it)
; Either include FK20x in an autoexec file or just type FK20x.
;
;**                 Important Note                  **
;  For this routine to work, you must create a file called
;
;                      Config.Sys
;
; with Edlin or from the console and put the statement DEVICE=ANSI in
; it. The DOS 2.0 file ANSI.SYS should be on your boot disk. This will
; cause the file ANSI.SYS to be loaded when the system is booted.
;
SUBTTL DESCRIPTION OF THE STACK SEGMENT
STACK   SEGMENT PARA STACK 'STACK'
        db      'foo'
        stack ends
        PAGE
SUBTTL DESCRIPTION OF THE DATA SEGMENT
;
subttl desciption of dos interfaces
cseg    segment para public 'CODE'
start   proc    far
        assume cs:cseg,ds:cseg,es:nothing
        push    ds                      ;set up starting linkage as per example
        sub     ax,ax                   ;zero this and place on stack
        push    ax                      ;so that when we do a RET we go to
        push    cs                      ;move the workarea address into DS
        pop     ds
; ******           Start screen display           ****
        mov     dx,offset clear
        mov     ah,9
        int     21h
        mov     dx,offset k1
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k2
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k3
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k4
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k5
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k6
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k7
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k8
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k9
        mov     ah,9                    ;funtion 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset k10
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
; ***            Start key assignments                ***
        mov     dx,offset mvf3          ;move F3 to END key
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f1            ;Assign F1 - F10
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f2
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f3
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f4
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f5
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f6
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f7
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f8
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f9
        mov     ah,9                    ;funtion 9 is print string
        int     21h                     ;call dos to do it
        mov     dx,offset f10
        mov     ah,9                    ;function 9 is print string
        int     21h                     ;call dos to do it
; The next section of code set ups the parameters for each function
; key. To make a key 'hot' add the following after the string ending
; quote - ;13p$'  The 13 is decimal for a carrage return.
;
;
exit:   ret
clear   db      27,'[2J                   $'
mvf3    db      27,'[0;79;0;61p           $'
f1      db      27,'[0;59;" A:"p          $'
f2      db      27,'[0;60;" B:"p          $'
f3      db      27,'[0;61;" C:"p          $'
f4      db      27,'[0;62;"CHKDSK "p      $'
f5      db      27,'[0;63;"COPY "p        $'
f6      db      27,'[0;64;"*.* "p         $'
f7      db      27,'[0;65;"DISKCOPY "p    $'
f8      db      27,'[0;66;"BASICA "p      $'
f9      db      27,'[0;67;"DIR "p         $'
f10     db      27,'[0;68;"TYPE "p        $'
k1      db      'F1 = " A:"     $'
k2      db      'F2 = " B:"     $'
k3      db      'F3 = " C:"     $'
k4      db      'F4 = "CHKDSK " $'
k5      db      'F5 = "COPY "   $'
k6      db      'F6 = "*.* "    $'
k7      db      'F7 = "DISKCOPY "$'
k8      db      'F8 = "BASICA " $'
k9      db      'F9 = "DIR "    $'
k10     db      'F10= "TYPE "   $'
start   endp
;
;
cseg    ends
        end     start
