There are examples written for measuring the frequency of TTL signals. If you are using LabVIEW, you can search the data acquisition examples and you will find a separate folder for counters (...Program Files\National Instruments\LabVIEW\examples). There will be a NI-TIO.llb which will contain all examples you can use with the NI 6602. There is a Measure Frequency VI that will work for you. For text-based programming environments, there will be examples installed within the ...\Program Files\National Instruments\NI-DAQ\Examples directory. I hope this helps.
Regards,
Todd D.
Applications Engineer
National Instruments