PDA

View Full Version : need help on comparator



bertus
- 20th October 2003, 10:43
HI,
i am struggling to count the high's of the input frequency in my frequency counter. im using pic16F628. i also heard that u can use the built-in comparator. any help would be appreciated!!

Melanie
- 21st October 2003, 10:25
The comparator can only be used to vary the threshold level at which your input signal registers a ‘1’ or a ‘0’ to be counted by the PIC. Therefore if the level of your input is too low to successfully be counted by the PIC (eg your input is going 0-1v rather than 0-5v), the Comparator can be used to condition the input and bring it up to a full 0-5v swing for the PIC’s logic to process. None of this will have any effect on the PIC’s top-end frequency response though, so if previously you could only count up to say 1MHz, then that will not have magically improved any.

Melanie