Intel 386 User Manual page 280

Embedded microprocessor
Table of Contents

Advertisement

#define DISABLE
SetUp_ReadBack(DISABLE, DISABLE, ENABLE, ENABLE, ENABLE);
Real/Protected Mode:
No changes required
*****************************************************************************/
void SetUp_ReadBack(
{
BYTE rb_control = 0;
rb_control |= 0xc0; // Set TMRCON to read-back command
if (GetStatus != 0)
rb_control &= 0xef;
if (GetCount != 0)
rb_control &= 0xdf;
if (Timer0 != 0)
rb_control |= 0x02;
if (Timer1 != 0)
rb_control |= 0x04;
if (Timer2 != 0)
rb_control |= 0x08;
_SetEXRegByte(TMRCON, rb_control);
} /* SetUp_ReadBack */
/*****************************************************************************
CounterLatch:
Description:
This function invokes a counter-latch command for the specified
timer and returns the latched counter value.
Parameters:
Timer Unit number of timer whose counter value is to be latched
0
BYTE Timer0, BYTE Timer1, BYTE Timer2, BYTE GetStatus,
BYTE GetCount )
TIMER/COUNTER UNIT
10-37

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Intel386 exIntel386 extbIntel386 extc

Table of Contents