1.31.16.27 TCx_Compare16bitCounterSet Function

C

/* x = TC instance number */
void TCx_Compare16bitCounterSet( uint16_t count );

Summary

Sets new timer counter value.

Description

This function sets new timer counter value.

Precondition

TCx_CompareInitialize() function must have been called first.

Parameters

Param Description
count new counter value to set

Returns

None.

Example

uint16_t count = 0x100;
TC0_CompareInitialize();
TC0_CompareStart();
TC0_Compare16bitCounterSet(count);

Remarks

The caller must know the number of significant bytes of timer. Counter value is right-aligned.