GT_OSD  - Identifies Operating system and Date/time protocol
RDCLK   - Read the system clock, return packed BCD YYMMDDhhmmss
TIME    - Read the system clock, return ASCII date/time string
ASCIDT  - Convert BCD standard date/time to formatted ASCII
:
GT_OSD Identifies Operating system and Date/time protocol

Returns a pointer to a data structure which contains
DOS identity, CPM compatibility, DOS version, and
data for system clock access. A separate entry (RDCLK)
provides for reading the clock.

CALL WITH:	(no calling parameters)

RETURN WITH:
	CY set = unknown operating system
	Cy clear = CP/M, CPM+, ZRDOS, ZSDOS, or ZDDOS
		and System Clock set up for date/time access.
	HL -> OS data structure

	public	gt_osd

SEE NEXT SCREEN for data structure

The data structure to which HL points is:

offset	size	description
   0      1       CP/M version with which the DOS is compatible
   1      1       DateStamper Flag, 'D' for DS, else 0
   2      1       Version number of the current DOS
   3      1       Byte value identifying current DOS

   4      1       Value passed in C for DOS clock calls
   5      2       Address of the Clock read routine (may be BDOS)
   7      2       Address of the local Date/Time buffer.

DOS identifying values (offset 3, above), all are ASCII
	0 (binary null) = Unidentified DOS
	C = CP/M	M = MP/M	O = ZOS
	R = ZRDOS	S = ZSDOS	D = ZDDOS
	3 = CP/M+ (=CP/M 3.0)


:
RDCLK  - routine to read the system clock

Reads system clock if present. Calls GT_OSD if necessary
to identify the Clock calling parameters. Compatible with
ZS/ZDDOS, DATESTAMPER, and CP/M+. Implementer can install
other clock access routines after a call to GT_OSD.

CALL WITH:	(no parameters)
RETURN WITH:
	NC = NO CLOCK
	CY set = clock has been read
	HL -> date/time buffer, 6 bytes
For CPM+, the first byte is undefined. Bytes 1,2 contain
the number of days since 1 Jan 1978. Bytes 3 - 5 contain
bcd hours, min, sec. (same as ZSDOS). For ZSDOS, ZDDOS,
and DATESTAMPER, the first three bytes are Year, Month,
and Day. All are in BCD. Year is last two digits.

	public	rdclk

:
TIME - Read the system clock, return ASCII date/time

Uses the general purpose RDCLK routine to get the clock data,
then converts it to an ASCII string in y/m/d h:m:s format.

CALL WITH:  (no calling parameters)

RETURN WITH:
	HL -> the ASCII date/time string
	FLAGS: C = valid null terminated D/T string
	      NC = no clock, string starts with null

	entry	time

:
ASCIDT - Convert BCD standard date/time to formatted ASCII

Standard packed BCD input string is yy mm dd hh mm ss format.

Produces an ASCII string like yy/mm/dd hh:mm:ss which is null
terminated. The formatted string is in the more familar form:
		mm/dd/yy hh:mm:ss

CALL WITH:
	HL -> BCD date/time in standard form
RETURN WITH:
	HL -> Formatted ASCII Date/Time string
the string is null terminated

	entry	ascidt
	ext	ma2hc

