80-Bus News |
November–December 1984 · Volume 3 · Issue 6 |
| Page 45 of 55 |
|---|
present if I include all of my normal Hardware and Software options, so there is not enough room to allow inclusion of the extra code and tables needed to display the day name unless I omit something else or alter MOVCPM so that CP/M leaves room for an even larger CBIOS. Examination of the code listed later will show that this option will only be allowed if NKBD is set FALSE. (This is the most suitable routine for me to omit, since I normally use the Gemini GM827 keyboard.)
In some cases, there may well be enough room for the extra code and data anyway, since some other features such as Virtual Disk may not be incorporated in the CBIOS, and it may not be necessary to omit routines or modify MOVCPM.
The final part of this extract shows the RTC ports added to the relevant section of SYS.
The second set of extracts are the extra code that has been added into
the Workspace/
In order to allow user programs to easily access the Clock, it is necessary to set up some method of allowing the ‘calling’ program to find the clock routines. The simplest way of doing this is to add an extra ‘Jump to Clock Routine’ to the jump table at the start of the CBIOS. Since the offset of this jump from the start of the CBIOS is known, it can be used as the access point. Some details of how to do this are given in App. 1. A look at the code for the clock will show that on ‘RET’urn, HL holds the start address of STRING (or STRNG1), which holds the clock data for subsequent processing.
A marker is also placed after the additional jump in the ‘jump’ table. The calling program can check for this marker before attempting to read the clock, and can thus be made to avoid trying to read a non existent clock. This can sometimes cause the program to lock into a permanent loop from which the only exit is ‘RESET’, unless additional software is used to ‘time out’ any such loop.
Additional space is reserved at the end of the ‘SYS’ workspace for clock
related data and variables. A space of 11 bytes is allocated to ‘REGS’. The
RTC chip registers are stored in this space as they are read. After some
further processing, REGS will hold the ASCII equivalents of the clock register
data. Once the clock has been successfully read, the data is moved to
‘STRING/
The other bit of code added to module 4 will conditionally allow the top
line of the
GM812
IVC
card to be locked, to prevent the time/
| Page 45 of 55 |
|---|