Dec 122017
TSR configurable clock. With ASM source code. By Tom Hanlin.
File VCLOCK14.ZIP from The Programmer’s Corner in
Category Display Utilities
TSR configurable clock. With ASM source code. By Tom Hanlin.
File Name File Size Zip Size Zip Type
VCLOCK.ASM 25426 5061 deflated
VCLOCK.COM 1946 1416 deflated
VIDCLOCK.ASM 25199 4936 deflated
VIDCLOCK.COM 1917 1413 deflated
VIDCLOCK.DOC 7464 3161 deflated
VIDCLOCK.NEW 950 540 deflated

Download File VCLOCK14.ZIP Here

Contents of the VIDCLOCK.DOC file

Copyright (c) 1988-1991 Thomas G. Hanlin III
A configurable background-operating time display utility

VIDCLOCK keeps a constant time display on the screen. You can select the
location the time will be displayed, what color it will be, whether it will
be normal or military (24-hour) format, whether the seconds should be
displayed, whether flicker-free video is required, and how often to update
the display. You can also remove VIDCLOCK entirely from memory if you so
desire. For help, just type VIDCLOCK without any parameters.

VIDCLOCK.COM works with any computer.

VCLOCK.COM does not work with 8088 or 8086 systems. It is for computers
which use NEC V20, 80186, 80286, 80386, or 80486 processors. In return for
this limitation, it is more efficient in operation and requires slightly less
memory (although the file is slightly larger, due to additional installation
code which is discarded when installation is complete).

This utility may be freely distributed according to these rules:

VIDCLOCK.NEW must all be distributed together, in unmodified form.

2) Advertising files MAY NOT be included with the above files. This applies
to BBS ads in specific.

3) No fee may be charged, other than a disk duplication / handling fee
which may not exceed $6.00.


/I Install the clock (turns on the clock)

/R Remove the clock (turns off the clock)

/F Flicker-free (slow) video, for cheap CGAs

/M Military time format (24-hour clock)

/S Seconds off (don't display seconds)

/C=f,b Color settings for clock. Foreground and background colors are
selectable, using numbers as follows:

Number Color system
0 Black
1 Blue
2 Green
3 Cyan
4 Red
5 Magenta
6 Brown
7 White

Add eight to foreground for intense or bright colors.
Add eight to background for blinking colors (not recommended).

For a Monochrome display, use the following pairs:
Numbers Mono System
7,0 Normal
1,0 Underlined
0,7 Inverse video

/L=r,c Location of clock. Row and Column should be specified. The
upper left corner of the screen is 1,1. The default is around
1,71 (depending on screen mode and /F, /S options). It is
recommended that the clock go on the top line of the screen, or
past the 25th line (for EGA/VGA in the proper modes), since
normal scrolling will otherwise tend to messily duplicate the
time value on the screen.

/U=t Update frequency: how often to update the clock display, in
18ths of seconds. This may range from 1-255, with the default
at 9 (update every half-second).

General Information:

VIDCLOCK is designed to work with any text-mode screen. It will work on
Monochrome, CGA, EGA, VGA, and Hercules displays. Any text mode can be used:
40x25, 80x25, 80x43, 80x50. Only IBM and compatible machines are supported--
if it doesn't work, your computer isn't compatible enough. You may be able
to fix this by making sure you have the latest version of your BIOS ROM and a
recent version of DOS (3.0 or later).

VIDCLOCK is a TSR (Terminate and Stay Resident) program. It takes up a tiny
656 bytes of memory until you remove it or reboot the computer.

The /F option should only be used if VIDCLOCK causes flickering on your
screen (which will only happen on some low-quality CGAs). It will stop the
flickering, at the cost of some speed. It may also tend to cause
interference with any serial communications being done.

The /U option controls how frequently the clock display is updated, in 18ths
of seconds. Smaller values make the clock update more frequent and larger
values make the clock update less frequent. There probably isn't any reason
to change this from the default value. If your application erases the clock
frequently, however, you may wish to have the clock updated more frequently.
Note that small values may tend to cause interference with communications.
Large values may result in an unevenly-updated clock display, so you will
probably want to turn off the seconds display (see /S option) if you choose a
value of 18 or above.

Technical Notes:

VIDCLOCK was designed for minimum size and maximum speed. For this reason,
it uses a number of techniques which might otherwise be shunned, such as
self-modifying code. Since a clock display like this has the potential of
slowing down the entire computer system, I felt it desirable to avoid the
usual niceties in favor of a more practical approach.

VIDCLOCK correctly handles any normal text screen mode. It does so on a
static basis, going by what was in effect when it was installed. Any display
may be used, with any display page (if applicable), in 40x25, 80x25, 80x43,
and 80x50 text modes on MDA, Hercules, CGA, EGA, and VGA systems. It is
assumed that screen flicker or "snow" is not a problem, since that's true in
most cases, and it makes for much faster displays. Flicker-free display
techniques can be selected manually if required. If the screen is placed in
graphics mode, VIDCLOCK will cease updating the display until text mode is

VIDCLOCK's copy of the environment space is discarded before installation, to
keep the size to a minimum. VIDCLOCK can detect whether it has been
installed in a manner resistant to disruption by other TSRs. When VIDCLOCK
is turned off, it restores the original interrupt vectors and removes itself
from memory. In operation, VIDCLOCK uses direct machine access for speed and
to avoid the reentrancy problem with BIOS and DOS.

The timer interrupt, INT 8, is used to tell when to update the clock. This
reduces likelihood of conflict with other TSRs, which tend to use INT 1Ch
for timing purposes. The actual time is calculated from the BIOS time
data area.

The video interrupt, INT 10h, is hooked to allow VIDCLOCK to update the
screen after any action which may erase the clock. It isn't foolproof, as
many applications bypass INT 10h, but on the whole it allows for a much
steadier clock display.

Interrupt INT 2Fh, the "multiplex" interrupt, is also hooked in, for use in
determining whether the clock is installed and in removing the clock. The
VIDCLOCK device identifier is 0DAh. You can use the following method to see
if VIDCLOCK is installed (assembly language):

MOV AX,0DA00h ; query status for I.D. 0DAh
INT 2Fh ; use multiplex interrupt
; Returns:
; AL=0 not installed
; AL=0FFh installed

Note that INT 2Fh is not always available. Old computers (say, before 1985
or so) and systems running old DOS versions (before DOS 3.0) may not properly
initialize this interrupt. In that case, trying to use it will most probably
cause a system crash. A more robust test would get the vector for INT 2Fh
and test it for 0000:0000, which would be the most likely value if the
interrupt was not initialized.

 December 12, 2017  Add comments

Leave a Reply