home *** CD-ROM | disk | FTP | other *** search
-
- cseg segment
- assume cs:cseg,ds:cseg
- zero:
- org 100h
- entry:
- jmp start
- trtab equ $
- ;THE SYMBOLS LOOK MEANINGLESS UNLESS YOU HAVE LOADED THE ega FONT
- ;RUSSIAN.EGA
- db 001h,01Eh,'≥' ;Umlaut A
- db 000h,01Eh,'≤' ;umlaut a
- db 00Fh,018h,'⌠' ;umlaut O
- db 000h,018h,'⌡' ;umlaut o
- db 015h,016h,'÷' ;umlaut U
- db 000h,016h,'≈' ;umlaut u
- db 01Ah,02Ch,'°' ;Cap Eszet
- db 000h,02Ch,'∙' ;eszet
- db 02Dh,00Ch,'φ' ;-
- db 05Fh,00Ch,'¥' ;_
- db 03Dh,00Dh,'⌐' ;=
- db 02Bh,00Dh,'ë' ;+
- db 07Ah,02Ch,'º' ;z
- db 05Ah,02Ch,'ç' ;Z
- db 078h,02Dh,'σ' ;x
- db 058h,02Dh,'ò' ;X
- db 063h,02Eh,'µ' ;c
- db 043h,02Eh,'û' ;C
- db 076h,02Fh,'ó' ;v
- db 056h,02Fh,'é' ;V
- db 062h,030h,'í' ;b
- db 042h,030h,'ü' ;B
- db 06Eh,031h,'¡' ;n
- db 04Eh,031h,'ì' ;N
- db 06Dh,032h,'¼' ;m
- db 04Dh,032h,'î' ;M
- db 060h,029h,'Ω' ;`
- db 07Eh,029h,'Ü' ;~
- db 071h,010h,'Θ' ;q
- db 051h,010h,'Ö' ;Q
- db 077h,011h,'Φ' ;w
- db 057h,011h,'ÿ' ;W
- db 065h,012h,'Ñ' ;e
- db 045h,012h,'à' ;E
- db 072h,013h,'α' ;r
- db 052h,013h,'É' ;R
- db 074h,014h,'Γ' ;t
- db 054h,014h,'Æ' ;T
- db 079h,015h,'δ' ;y
- db 059h,015h,'¢' ;Y
- db 075h,016h,'π' ;u
- db 055h,016h,'ô' ;U
- db 069h,017h,'¿' ;i
- db 049h,017h,'ê' ;I
- db 06Fh,018h,'«' ;o
- db 04Fh,018h,'Ä' ;O
- db 070h,019h,'»' ;p
- db 050h,019h,'Å' ;P
- db 05Bh,01Ah,'∩' ;[
- db 07Bh,01Ah,'ƒ' ;{
- db 05Dh,01Bh,'ε' ;]
- db 07Dh,01Bh,'₧' ;}
- db 05Ch,02Bh,'±' ;\
- db 07Ch,02Bh,'≡' ;|
- db 061h,01Eh,'á' ;a
- db 041h,01Eh,'Ç' ;A
- db 073h,01Fh,'ß' ;s
- db 053h,01Fh,'æ' ;S
- db 064h,020h,'ñ' ;d
- db 044h,020h,'ä' ;D
- db 066h,021h,'Σ' ;f
- db 046h,021h,'ö' ;F
- db 067h,022h,'ú' ;g
- db 047h,022h,'â' ;G
- db 068h,023h,'ª' ;h
- db 048h,023h,'å' ;H
- db 06Ah,024h,'τ' ;j
- db 04Ah,024h,'ù' ;J
- db 06Bh,025h,'¬' ;k
- db 04Bh,025h,'è' ;K
- db 06Ch,026h,'½' ;l
- db 04Ch,026h,'ï' ;L
- db 03Bh,027h,'∞' ;;
- db 03Ah,027h,'£' ;:
- trtabl equ ($-trtab)/3
-
- inah db ? ;ah we called with
-
- newi16:
- mov cs:inah,ah
- pushf
- db 09ah ;far call
- oldi16 dw 0,0
- pushf
- push bx
- mov bl,cs:inah
- cmp bl,2
- jb yes
- cmp bl,10h
- jb no
- cmp bl,12h
- jae no
- yes:
- push ds
- xor bx,bx
- mov ds,bx
- test byte ptr ds:[417h],10h
- pop ds
- jz no ;only when scroll lock is lit
- push cx
- push ds
- push cs
- pop ds
- mov bx,offset trtab
- mov cx,trtabl
- scan: cmp ax,ds:[bx]
- jnz scann
- mov al,ds:[bx+2]
- jmp short scanx
- scann: add bx,3
- loop scan
- scanx:
- pop ds
- pop cx
- no:
- pop bx
- popf
- db 0cah ;retf 2
- dw 2
- start: xor ax,ax
- mov ds,ax
- mov ax,offset newi16
- xchg ax,ds:[16h*4]
- mov cs:oldi16,ax
- mov ax,cs
- xchg ax,ds:[16h*4+2]
- mov cs:oldi16+2,ax
- push cs
- pop ds
- mov dx,offset msg
- mov ah,9
- int 21h
- mov dx,(start-zero+15)/16
- mov ax,3100h
- int 21h
- msg db 'Russian keyboard driver loaded. Hot key is Scroll Lock'
- db 13,10,'$'
- cseg ends
- end entry