-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmdarview.asm
More file actions
161 lines (154 loc) · 4.48 KB
/
Copy pathmdarview.asm
File metadata and controls
161 lines (154 loc) · 4.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
;---------------------------------------------------------------------
;This program must be resident & it must make russian symbols emulation.
;Options are :
;[/v[XX]]-change to russian view symbols by testing Video-RAM.
;Where XX-[may be absent]-scaning frequency 1-18 times per second.
;So, more XX -> more time of work.
;If it is absent it set on 9 tps.
;/b-catch & change BIOS function for output.
;[/p##]-set pop-up key to programm.
; lust eddition at 11-11-95.
;p.s.: I need write hot-key procedure,becouse it programm conflicted whith telix
;---------------------------------------------------------------------
.8086
MODEL TINY
CODE_ SEGMENT BYTE PUBLIC 'CODE'
ASSUME CS:CODE_,DS:CODE_,ES:CODE_
ORG 100H
BEGIN: ;LABEL!
JMP NEAR PTR INIT ;LABEL!
;-----------------TSR-data_structure-----------------------------------
OLD_09 DD 0
OLD_08 DD 0
ASCII DB 'A','6','B',244,'D','E',15,'3','U','U','K','L','M','H','O',20,'P'
;
DB 'C','T','Y',216,'X',191,3,1,2,39,'"',39,'>',17,184,'a','b'
db 'v','r' ;*
db 'g','e',42,184,'u','u','k','l','m','#','o','n'
ASCII_ DB 'p','c',194,'y',216,'x',191,3,1,2,39,'"',39,'>',17,184,'E','e'
;------------------------------
process proc near
;*************************************
;* INPUT IN AL SYMBOL TO TRUNSLATE *
;* OUTPUT IN AL KVASI-RUSSIAN SYMBOL *
;*************************************
;al-128=offset in eq_data
push bp
push bx
mov bh,ah
push bx
xor ah,ah
cmp al,224
jae p2
sub al,128
mov bp,ax
mov al,cs:[ascii][bp]
jmp short exit_pr
p2:
sub al,224
mov bp,ax
mov al,cs:[ascii_][bp]
EXIT_PR:
pop bx
mov ah,bh
pop bx
pop bp
ret
process endp
;------------------------------
NEW_08: ;LABEL!
; NEW INT 8H (TIMER)
; set to timer functions change-screen function
cli
PUSHF
push ax
push bx
push dx
push cx
push ds
mov bx,0b000h ;MDA (On not MDA vieoRAM entry point at 0b800h)
mov ds,bx
xor bx,bx
mov cx,2000
cicl:
mov ax,ds:[bx]
; sorting symbols
CMP AL,128
JB SHORT skip_cicl ;LABEL!
CMP AL,175
JBE SHORT processing1 ;LABEL!
CMP AL,224
JB SHORT skip_cicl ;LABEL!
CMP AL,241
JA SHORT skip_cicl ;LABEL!
processing1:
call process
mov ds:[bx],ax
skip_cicl:
add bx,2
loop cicl
skip8:
pop ds
pop cx
pop dx
pop bx
pop ax
POPF
sti
JMP cs:[OLD_08] ;LABEL!
;-------------------------------
;#############^^^^^^^!^^^^^INITIALISING PROGRAMM^^^^^!^^^^^^################
INIT: ;LABEL!
; DS=CS (becouse .com programm)
push cs
pop ds
; ! CHANGE BIOS INT 8H (timer) !
;TAKE OLD ADDRESS OF INTERRUPT
CLI
MOV AX,3508H
INT 21H
MOV WORD PTR [OLD_08],BX
MOV WORD PTR [OLD_08+2],ES
;MAKE NEW ADDRESS OF INTERRUPT
LEA DX,NEW_08
MOV AX,2508H
INT 21H
push cs
pop ds
push cs
pop es
STI
;output information about programm
lea dx,info
mov ah,9h
int 21h
;============MAKE_TSR===============================
TSR:
; find size
LEA AX,INIT
PUSHF
MOV CL,4
SAR AX,CL
INC AX
POPF
MOV DX,AX
; make TSR
MOV AX,3100H
INT 21H
int 20h
;===================================================
;---------------------data_structure----------------------------------
info db 'ˆ‚…’!',10,13
db 'This program make russian symbols emulation on Your computer.',10,13
db 'It can be useful if Your video-card is non-russificated ,',10,13
db 'and you have''t graphic''s on your monitor (such as MDA) ',10,13
db 'If it so,this program can solve Your problems',10,13
db 'So with it programm you can reed russian on MDA,',10,13
db 'to write russian use special drivers,such as keyrus.',10,13
db 'Freeware,license is current GNU GPL',10,13
DB 'Copyright by Olli <olli@NOSUCHADDRESS>, 13-11-95',10,13
Call_me db 'Author don''t carry any responsibility for this programm',10,13
db 'Contacts: Olli <olli@NOSUCHADDRESS>',10,13,'$'
;---------------------------------------------------------------------
CODE_ ENDS
END BEGIN