home *** CD-ROM | disk | FTP | other *** search
- ;
- ;; SlowDown for self-booting software
- ;;
- ;; BOOTSLOW
- ;;
- ;; Copyright 1991 Alexander R. Pruss
- ;;
- ;; May be freely distributed, modified and used provided that no copyright
- ;; messages are removed, and this sentence together with the next two are
- ;; always included in unmodified form. If you like this program a lot, you are
- ;; invited to show your appreciation by making a tax-deductible donation to
- ;; the Pro-Life or Anti-Abortion movement, but are under no obligation, moral
- ;; or otherwise to do so (especially if you disagree with the goals of this
- ;; movement.) There is no warranty; use at own risk.
- ;
- include macros.inc
- c segment
- org 100h
- BEGIN:
- assume CS:c,DS:c,ES:c
- push ds
- pop es
-
- Puts copyright
-
- Puts drive_q1
- LoopTop:
- Puts drive_q2
- g:
- DOSGetch
- cmp al,01bh
- jz Abort
- cmp al,'a'
- jb Physical
- ;
- ; Whirr a logical drive
- ;
- sub al,'a'
- mov bx,offset bootsec
- mov cx,1
- Clear dx
- int 25h
- jc diskerror
- jmp LoopTop
- ;
- ; Whirr a physical drive
- ;
- Physical:
- sub al,'A'
- mov dl,al
-
- mov ax,0201h
- mov cx,0001h
- Clear dh
- mov bx,offset bootsec
- int 13h
- jnc LoopTop
-
- diskerror:
- Puts i13error
- jmp LoopTop
-
- Abort:
- Puts done
- mov ax,4c00h
- int 21h
-
- _puts proc near
- mov bx,1
- mov dx,si
- mov ah,WriteHandle
- int 21h
- ret
- _puts endp
-
- String copyright, <'Disk Whirr Program.', CR,LF, '(C) Copyright 1991 Alexander Pruss', CR,LF>
- String drive_q1, <'Press an upper case letter to whirr a physical floppy, or a lower case letter', CR,LF, 'to whirr a DOS drive.', CR,LF>
- String drive_q2, <'Press A,B,..., or a,b,c,..., or ESC to abort.', CR,LF>
- String i13error, <'Disk error.',CR,LF>
- String done, <'Done!',CR,LF>
- bootsec:
-
- c ends
- end BEGIN
-