Analog and Digital Rf Detector and Frequency Counter