Regular readers will know I have been working on a replacement CRT unit
particularly for T/BP7 that would at least cure the RTE200 bug and offer
support for extended keyboards if available.
Following testing, I have uploaded a replacement CRT for public download.
Full information and a download link at http://www.pedt.demon.co.uk/crt/
File has been offered to Garbo, Simtel and the FTP server of my ISP for
consideration. List of download links will be placed in the Mini-FAQ.
Franz: you are very welcome to place a copy on your TP site.
During testing, it was noticed that the same interface worked for V5, V5.5
and V6.0 as well. Test units compiled using the original CRT did not need
recompilation when a program using the test unit. The new CRT is therefore
available for these versions as well.
Main Changes:
a) Split into separate sections (16 *.OBJ files) to maximise the amount
of smart linking that can be done. This means that programs will be
smaller if not using all the procedures and functions in CRT.
b) Supports F11,F12 etc. if extended keyboard available. Uses Int$16
$00/$01 otherwise as per the original CRT unit. Already written code
should be perfectly OK with the extension to ReadKey to read extended
codes as they should come up as unrecognised in older code. Gray cursor
keys and KeyPad give the KeyPad codes on extended keyboards. If you need
to distinguish between the cursor keys and the keypad keys you should
already have your own unit to do this.
c) CheckSnow is set false on EGA, VGA or better graphics by default on
both initialisation and TextMode changes. CheckSnow still sets true on
CGA cards. The assembly code used is at least as fast as explicitly setting
CheckSnow to false on EGA/VGA/SVGA cards after using TextMode and saves the
programmer forgetting to do so to speed up output.
d) Writing via DirectVideo or BIOS writes: checking conditions changed so
that non-CGA Text Output works a little faster on most machines. As most
computers now in use have EGA, VGA or SVGA graphics, the coding is set to
maximise the speed of writing to these cards at the expense of making CGA
writes slightly slower.
e) Modes above $7 checked and, if Text Mode rather than Graphics Mode, no
force into 80x25 Text Mode on program startup. The original CRT unit set
80x25 colour text mode (Mode 3) if the video mode was above Mode 3 and
not Monochrome Adaptor. If you use 132x25 text mode then this will stay
when running programs compiled with the new CRT unit. If you explicitly
need 80x25 then use TextMode to change the mode at program startup whilst
using the LastMode variable to store the original screen mode to restore
this on program termination.
f) Delay fixed to longint/dword status to prevent RTE200. This occurred
on computers above 200MHz using T/BP7.0x and has been the subject of many
questions in comp.lang.pascal.borland and borland.public.turbopascal. The
version of CRT for TP6.00 resolves the incorrect delay of the original
CRT unit for fast computers.
g) Instructions, as far as possible, allow pipelining on P5+ and
compatible CPU to maximise the speed of the unit.
Not changed:
a) In BW40/80 modes, colour EGA/VGA cards will allow changing the colour
of Text or Background to non-BW colours.
b) Interface part of the unit - to remain compatible.
Thanks to everyone who responded to the thoughts I posted here and those
who were able to test the replacement. In particular thanks to Osmo for the
routine to check for non standard text modes and his check for extended
keyboards.
--
Pedt
'Moon Starer' is a perfect anagram of 'Astronomer'