Instructions

372Libraries
© 2013 Conrad Electronic
Description
These function initializes Counter1. Counter1 gets incremented at every positive signal edge at input
Mega32: PortB.1 (PIN2) Mega128: PortD.6 (X2_15).
Parameter
None
5.26.1.17 Timer_T1CNT_Int
Timer Functions
Syntax
void Timer_T1CNT_Int(word limit);
Sub Timer_T1CNT_Int(limit As Word)
Description
These function initializes Counter1. Counter1 gets incremented at every positive signal edge at input
Mega32: PortB.1 (PIN2) Mega128: PortD.6 (X2_15). After the limit is reached an interrupt ("Timer1 Com-
pareA" - define: INT_TIM1CMPA ) is triggered. An appropriate Interrupt Service Routine must be specified.
Parameter
limit
5.26.1.18 Timer_T1FRQ
Timer Functions
Syntax
void Timer_T1FRQ(word period, byte PS);
Sub Timer_T1FRQ(period As Word, PS As Byte)
Description
This function initializes Timer1 for frequency generation. Parameters are period duration and prescaler,
see table. The output signal is generated at Mega32: PortD.5 (PIN19). Mega128: PortB.5 (X1_3). The fre-
quency generation is started automatically. There is an extended prescaler definition for the Mega128, see
table.
Parameter