23.4.2.4 Compare Operations

By default, the Compare/Capture channel is configured for compare operations. To perform capture operations, it must be reconfigured.

When using the TCC with the Compare/Capture Channel n registers (CCn) for compare operations, the counter value is continuously compared to the values in the CCn registers. This can be used for timer or waveform operations.

The Compare/Capture Buffer Channel x registers (CCBUFx) provide double buffering capability. Double buffering synchronizes the update of the CCn register with the buffer value at the UPDATE condition, or if a force update command is issued by writing the UPDATE command value to the TCC Command bit field in the Control B Set register (CTRLBSET.CMD). For further details, refer to the Double Buffering section. This synchronization prevents the occurrence of odd-length, non-symmetrical pulses and ensures glitch-free output.