19.6.1 Input Capture Trigger Source
The main trigger source for the input capture unit is the Input Capture pin (ICPn). Timer/Countern can alternatively use the analog comparator output as trigger source for the input capture unit. The analog comparator is selected as a trigger source by setting the Analog Comparator Input Capture (ACIC) bit in the Analog Comparator Control and Status Register (ACSR). Be aware that changing trigger source can trigger a capture. The input capture flag must, therefore, be cleared after the change.
Both the Input Capture Pin (ICPn) and the Analog Comparator Output (ACO) inputs are sampled using the same technique as for the Tn pin. The edge detector is identical. However, when the noise canceler is enabled, additional logic is inserted before the edge detector, which increases the delay by four system clock cycles. The input of the noise canceler and edge detector is always enabled unless the Timer/Counter is set in a Waveform Generation mode that uses ICRn to define TOP.
An input capture can be triggered by software by controlling the port of the ICPn pin.