* Module cttimer.h  V010AM01 === 091487
*
*    PROPRIETARY PROGRAM MATERIAL
* REPRODUCTION OR DISCLOSURE IS PROHIBITED WITHOUT WRITTEN AUTHORIZATION
* OF THE PATENT DIVISION OF UNISYS CORPORATION, DETROIT, MICHIGAN 48232, USA.
* COPYRIGHT (C) 1987 BORLAND INTERNATIONAL
* COPYRIGHT (C) 1987 UNISYS CORPORATION
*
if	defined(CTTIME_T)
define	CTTIME_T

if	defined(__TIME_T)
define	__TIME_T

typedef	struct	simpleDate	{
	unsigned	seconds;
	unsigned	dayTimes2;
	}	time_t;
endif

struct	systemDate	{
	unsigned char	ticks;
	unsigned char	hundredMsec;
	unsigned	seconds;
	unsigned	dayTimes2;
	};

struct	expandedDate	{
	unsigned	year;
	unsigned char	month;
	unsigned char	monthDay;
	unsigned char	weekDay;
	unsigned char	hour;
	unsigned char	minute;
	unsigned char	second;
	};

struct	TRB	{
	unsigned	counter;
	unsigned	counterReload;
	unsigned	cEvents;
	unsigned	exchResp;
	unsigned	ercRet;
	unsigned	rqCode;
	};

struct	TPIB	{
	char		__filler[8];
	void	  (*far pIntHandler) interrupt ();
	unsigned	saData;
	unsigned	cIntervals;
	unsigned	pRqBlkRet;
	char		__filler2[12];				  
	};

if	defined(__ERCTYPE)
define	__ERCTYPE;

typedef	unsigned	ErcType;
endif

ErcType	CloseRTClock plm far (struct TRB *far pRqTime);
ErcType	CompactDateTime plm far (struct expandedDate *far pExpDateTime,
			struct simpleDate *far pDateTimeRet);
ErcType	Delay plm far (unsigned n);
ErcType	ExpandDateTime plm far (struct simpleDate dateTime, 
			struct expandedDate *far pExpDateTimeRet);
ErcType	GetDateTime plm far (struct simpleDate *far pDateTimeRet);
ErcType	OpenRTClock plm far (struct TRB *far pRqTime);
ErcType	ResetTimerInt plm far (struct TPIB *far pTPIB);
ErcType	SetDateTime plm far (unsigned seconds, unsigned dayTimes2);
ErcType	SetTimerInt plm far (struct TPIB *far pTPIB);
endif
