27.4.6 Sync and Triggered Operation

Synchronized (Sync) and Triggered mode operations can be thought of as Complementary modes that affect the operation of the CCPxTMR registers in most of the module’s major operating modes. Both use the SYNC[4:0] bits (CCPxCON1[20:16]) to determine the input signal source. The difference is how that signal affects the timer.

In Sync mode operation, the timer counts freely when enabled by the CCPON bit and is reset to zero when the input, selected by SYNC[4:0], is asserted. The timer immediately begins to count again from zero unless it is held for some other reason. Sync operation is used whenever the TRIGEN bit (CCPxCON1[23]) is cleared.

In Triggered mode operation, the timer is held in Reset until the input selected by SYNC[4:0] is asserted; when this occurs, the timer starts counting and continues to count until the TRCLR bit (CCPxSTAT[5]) is set. Triggered operation is used whenever the TRIGEN bit is set.

Depending on the specific device, the SYNC[4:0] bits allow for the selection of up to 32 internal or external sources. Some implemented sources may be available for triggered operation but not for Sync operation. In addition, ‘11111’ (free-running counter) is not valid for Sync operation.

Sync and trigger operations play a major role in the module’s operation in Timer and Output Compare modes by allowing chained and synchronized operation of multiple modules.

Table 27-20. Synchronization Sources
SYNC[4:0]Synchronization Source
11111None; Timer with Auto-Rollover (FFFFh → 0000h)
11010-11110Reserved
11001Comparator 3 Output
11000Comparator 2 Output
10111Comparator 1 Output
10110Reserved
10101UART3 TX Edge Detect
10100UART3 RX Edge Detect
10011CLC4 Output
10010CLC3 Output
10001CLC2 Output
10000CLC1 Output
01111UART2 TX Edge Detect
01110UART2 RX Edge Detect
01101UART1 TX Edge Detect
01100UART1 RX Edge Detect
01011INT2
01010INT1
01001INT0
00101-01000Reserved
00100Sync Output SCCP4
00011Sync Output SCCP3
00010Sync Output SCCP2
00001Sync Output SCCP1
00000None; Timer with Rollover on CCPxPR Match or FFFFh