bjorn@dataio.UUCP (Bjorn Benson) (05/25/85)
Question: Are you one of those people who enjoys front panel lights on computers? Question: Do you use a RAM Disk with your IBM-PC? If you answered yes to both those questions, then this patch is for ==> YOU <==. This patch goes into the IBM distributed RAM Disk and causes a rotating action symbol symbol to be displayed in the upper-left corner of the screen (Mono or Color) whenever the RAM Disk is accessed. This distribution consists of two files: PATCH.ASM the assembly language source to this patch PATCH.DO a command file that installs the patch Do NOT (repeat: NOT) assemble the source and try to patch it that way. The source is only supplied for reference. The VDISK.SYS file is already linked into a .COM representation and so the addresses and such are different than the source. Oh, and the commands to install the patch are: (1) COPY VDISK.SYS ADISK.SYS (2) DEBUG ADISK.SYS < PATCH.DO (3) edit CONFIG.SYS and change the reference from VDISK to ADISK (note that the original is VDISK and is saved, the new one is ADISK which stands for Action_symbol_virtual_DISK). Bjorn Benson ..!uw-beaver!entropy!dataio!bjorn ------------------------------PATCH.ASM------------------------------- page ,132 title VDISK Patches - Display an action symbol ; ; Written by Bjorn Benson and Walter Bright ; ..!uw-beaver!entropy!dataio!bjorn -and- ; ..!uw-beaver!entropy!dataio!bright ; ; This file is a set of patches to be made to the VDISK.SYS RAM disk ; program supplied with PC-DOS 3.x. Once the patches are made, an ; action symbol will be displayed in the upper left of the video screen ; when the RAM disk is accessed. Note that this patch uses the same ; code area as the Extended Memory option of the RAM disk, so the ; patched RAM disk will not work with Extended Memory (however, it ; will NOT crash if you try) ; ; Anyone reading this code is assumed to have a listing of the RAM ; disk code as given out by IBM. Otherwise it the code is hard to ; understand. ; cseg segment para public 'code' assume cs:cseg ; ; Patch in the command dispatcher to call the action ; symbol display routine. ; ;___Current Code___ ____New Code____ ; ;IRPT: PUSH DS PUSH DS ; . . ; . . ; PUSH BX PUSH BX ; PUSH CX PUSH CX ; PUSH DX JMP ACTION_SYMBOL ; PUSH DI " ; PUSH SI " ; CLD CLD ; . . ; . . org 00D9H jmp action_symbol after_action: ; ; Patch the extended memory driver routines to always return ; an error. ; ;____New Code____ ;INOUT_EM: ; JMP INOUT_EM_XE org 01CCH jmp inout_em_xe ; ; And now, execute the instructions that written over by the jump ; to this routine. ; action_symbol: push dx push di push si ; ; Finally, the real action symbol displaying routine. This works ; by incrementing a counter and using it to index into a table of ; characters to display. This character is then written to the upper ; left of both the Monochrome and Color display areas. ; push ds ; save DS push cs pop ds ; make DS point to CS segment assume ds:cseg ; mov bl,count ; count = (count + 1) mod 3 inc bx ; and bl,3 ; -in other words- xor bh,bh ; mov count,bl ; count = 0..3 mov al,data[bx] ; ax = character + attribute mov ah,7 ; mov bx,2*79 ; mov cx,0B000H ; display character on monochrome mov ds,cx ; mov [bx],ax ; mov cx,0B800H ; display character on color mov ds,cx ; mov [bx],ax ; pop ds ; restore DS jmp after_action ; and return to normal RAM disk code ; ; And last, but not least, is the data area. ; ; Count -- the counter that goes from 0..3 ; Data -- the table of characters to display ; org 0200H count db 0 data db '|/-\' org 0275H inout_em_xe: ; Extended Memory error return cseg ends end ------------------------------PATCH.DO-------------------------------- e 01d9 e9 f3 00 e 02cc e9 a6 00 52 e 02d0 57 56 1e 0e 1f 8a 1e 00 02 43 80 e3 03 32 ff 88 e 02e0 1e 00 02 8a 87 01 02 b4 07 bb 9e 00 b9 00 b0 8e e 02f0 d9 89 07 b9 00 b8 8e d9 89 07 1f e9 de fe e 0300 00 7c 2f 2d 5c w q