Scor­pio News

  

January–March 1987 – Volume 1. Issue 1.

Page 55 of 63

Enough of the complaining – If Gemini BIOS 3.x is what you have it is still a lot better than most CP/M BIOS’s. If you are fortunate enough to have SYS18 then you will have everything that you need except possibly Winchester support The MAP CP/M BIOS is very good and easily adaptable to different disk types and formats, including Winchesters, but lacks a few features like screen dump, screen paging and VBOOT, which can be added anyway.

If you do have the source code of your BIOS you may like to modify it to include some simple but extremely useful keyboard activated hardware support. The rest of this article will describe the sort of thing that I have added to the BIOS.

I first had the idea of providing keyboard support to hardware in order to cause the printer to advance to top of the next page.

In order to permit a direct keyboard command it is necessary to trap and process the relevant keystrokes instead of passing them to CP/M. This means that it is necessary to modify the lowest level BIOS routine reading the keyboard. The ‘special’ keys must be intercepted and processed and then control returned smoothly to CP/M.

The first problem was to find a suitable key for the purpose. After a long perusal of key allocations I decided to use ^T This choice was based on the fact that a few programs used ^T and it could be dispensed with, and also that ^T was a synonymous with printer T)hrow. The keyboard (pkbd: in SYS and BLINK: in MAP) was accordingly modified so that if ^T was typed, the printer advanced to top of next page, and the BIOS lines per page counter was reset.

It did not take long to realize that I could utilize the method to provide a number of other simple features that could avoid me loosing what little hair I have left. Due to this shortage of key allocations, I decided to make ^T the lead-in key, and to program the software to expect a second control key depending on the desired function. This had the advantage of allowing a key to be chosen, that related to the function to be achieved in addition, it allowed the option of sending on a ^T to CP/M if desired.

As an aid to the user, a message is displayed on the locked top line of the screen whilst the system is waiting for the second character, reminding the user of the options available. After the second character has been typed, this message is erased. After the routine has been processed, a CR character is returned to CP/M. This also happens if an erroneous second character is typed. Keyboard software is not noticeably affected since only the first ^T is searched for. Any other character is returned normally to CP/M.

A problem became apparent a while after I added a Real Time Clock to my BIOS. (I have described this in some detail – see App. 2 Ref 5) Since the article was published I discovered that if the clock updated during screen EDIT, or operation of screen oriented software, (eg: Cursor Addressing), the Clock could interfere with the ‘ESC’ sequences and corrupt the screen. At first I solved this problem by disabling the clock or running a BIOS without the clock. Since this resulted in incompatibilities in the various CP/M systems, I later decided to make the clock ‘passive’ and provide three ways of updating it.

The display now updates on Warm/​Cold Boot. On CALL from an external program. By user initiated demand from the Keyboard as described below.

This has eliminated the screen corruption problems referred to above. The number of functions supported is optional. It is currently limited in my case by the BIOS size equalling the 4k of BIOS space available on the system track. I have at present added seven functions as direct keyboard commands. They are –

a) ^T,^D –Call clock routines and Update Date and Time display on Locked top line at Left hand side of the screen.

Page 55 of 63