Hi,
To enable the counter you TRISA.3=1 (pin is input). To gate the count signal OFF you set TRISA.3=0 (pin is output) and pull the pin low (or high for that matter. The resistor in series with the input will protect the DUT from the "shorted" input.
Pulse the RA3 output in a loop until TMR0 again overflows. The pulses will override the input signal, there will be no conflicts because of the series resistor. As long as the RA3 output is LOW the input signal isn't seen by TMR0, when RA3 is high the input signal can't pull it low due to the series resistor. It'll work.
/Henrik.
Bookmarks