Renesas RJJ10J1643-0101 Network Card User Manual


 
Rev.1.01 2007.02.16
RJJ10J1643-0101
54
4.2.2 Timer
__CreateTimer
Synopsis
<Set timer mode>
Boolean __CreateTimer(unsigned long data1, unsigned int data2, unsigned int
data3, unsigned int data4, void* func)
data1 Setup data 1 (content differs with MCU type)
data2 Setup data 2 (content differs with MCU type)
data3 Setup data 3 (content differs with MCU type)
data4 Setup data 4 (content differs with MCU type)
func Callback function pointer
(Specify 0 if no callback functions are set.)
Description
Sets a specified timer to timer mode.
[data1]
For data1, the following definition values can be set. To set multiple definition values at
the same time, use the symbol “|” to separate each specified value.
(M16C)
RAPI_TIMER_A0 Uses timer A channel 0.
RAPI_TIMER_A1 Uses timer A channel 1.
RAPI_TIMER_A2 Uses timer A channel 2.
RAPI_TIMER_A3 Uses timer A channel 3.
RAPI_TIMER_A4 Uses timer A channel 4.
RAPI_TIMER_B0 Uses timer B channel 0.
RAPI_TIMER_B1 Uses timer B channel 1.
RAPI_TIMER_B2 Uses timer B channel 2.
RAPI_F1 Selects f
1
for the count source.
RAPI_F2 Selects f
2
for the count source.
RAPI_F8 Selects f
8
for the count source.
RAPI_F32 Selects f
32
for the count source.
RAPI_FC32 Selects f
c32
for the count source.
RAPI_TIMER_ON Sets the timer to start operating in __CreateTimer.
RAPI_TIMER_OFF Sets the timer to stop operating in __CreateTimer.
RAPI_GATE_L Selects a gate facility that counts a period during which input at
TA
iIN
pin remains low.
RAPI_GATE_H Selects a gate facility that counts a period during which input at
TA
iIN
pin remains high.
RAPI_PULSE_ON Selects that pulses are output from TA
iIN
pin.
RAPI_PULSE_OFF Selects that no pulses are output from TA
iIN
pin.
• Specifiable definition values when timer A is used (RAPI_TIMER_A0 to
RAPI_TIMER_A4 specified)
(Count source) Specify one from { RAPI_F1, RAPI_F2, RAPI_F8, RAPI_F32,
RAPI_FC32 }. The default value is RAPI_F2.