Search This Blog

Powered by Blogger.

Translate

[TC] Frequency counter using arduino

Many guys here were asking for a frequency counter and at last I got enough time to make one.  This frequency counter using arduino is based on the UNO version and can count up to 40KHz. A 16×2 LCD display is used for displaying the frequency count. The circuit has minimum external components and directly counts the frequency. Any way the amplitude of the input frequency must not be greater than 5V. If you want to measure signals over than 5V, additional limiting circuits have to be added and i will show it some other time. Now just do it with 5V signals.
The frequency to be counted is connected to digital pin 12 of the arduino. pulseIn() function is used here for counting the frequency connected to pin 12. pulseIn() function counts the number of pulses (HIGH or LOW) coming to a particular pin of the arduino. The general syntax of this function is pulseIn(pin, value, time) where pin is the name of the pin, value is either HIGH or LOW and time is time for which the function to wait for a pulse. The function returns zero if there is no valid pulse with in the specified time. The pulseIn() function can count pulses with time period ranging from 10 μS to 3 minutes. Circuit diagram of the frequency counter using arduino is given below.


Potentimeter R1 is used to adjust the contrast of the LCD screen. Resistor R2 limits the current through the back light LED.
In the program, high time and low time of the input signal is measured using separate pulseIn() functions. Then the high and low times are added together to get the total time period of the signal. Frequency is just 1/time period in seconds. The pulseIn() function returns the time period in microseconds. Total timeperiod in microseconds first divided by 1000. Then 1000 is divided by the result to get the frequency in hertz. The program of the frequency counter using arduino is shown below.

Program.

#include <LiquidCrystal.h>
int input=12;

int high_time;
int low_time;
float time_period;
float frequency;
LiquidCrystal lcd(7, 6, 5, 4, 3, 2);
void setup()
{
pinMode(input,INPUT);
lcd.begin(16, 2);
}
void loop()
{
lcd.clear();
lcd.setCursor(0,0);
lcd.print("Frequency Meter");

high_time=pulseIn(input,HIGH);
low_time=pulseIn(input,LOW);

 
time_period=high_time+low_time;
time_period=time_period/1000;
frequency=1000/time_period;
lcd.setCursor(0,1);
lcd.print(frequency);
lcd.print(" Hz");
delay(500);
}
The circuit can be powered through the 9V external power jack of the arduino. 5V DC required at some parts of the circuit can be tapped from the built in 5V regulator of the arduino itself. This is actually a simple counter circuit using arduino. We can modify this circuit for other applications like tachometer, intrusion counter etc.

Source:


http://www.circuitstoday.com/

Scoring game circuit


Description.
A simple scoring game circuit that can be used for all occasions when a dice is needed.The circuit is based on a NE555 timer,a 74LS192 counter,a74LS247 decoder and a & segment LED display.The timer IC1 will produce the clock for the counter IC(IC2) whose frequency is determined by R1 and C2.When S2 is pressed the IC2 will count in up mode and when S3 is pressed the IC2 will count in down mode.The IC 3 will decode the count to display it on the seven segment LED display .Thats about the working of the circuit.The circuit is designed strictly sticking on to the basics of counters and is a good one for beginners.There is nothing big deal.
Circuit diagram with Parts list.


electronic-game-circuit.jpg
Notes.
  • To play the game switch the power ON and press S1 to reset the counter.
  • Now press S2 or S3 and release .The IC2 will hold the last count .Now press S4 to see the score on display.That’s your score.Now the second person can try.
  • Each time one tries, he should press the S1 to reset the count and then press S2 or S3 and then S4 to see the score.
  • Circuit can be powered from a 9V radio cell or a 9V regulated DC power supply


7 Segment Counter Circuit


Seven Segment Counter Display Circuit

Description

Here is the circuit diagram of a seven segment counter based on the counter IC CD 4033.This circuit can be used in conjunction with various circuits where a counter to display the progress  adds some more attraction.
IC NE 555 is wired as an astable multivibrator for triggering the CD 4033.For each pulse the out put of CD 4033 advances by one count.The output of CD 4033 is displayed by the seven segment LED display LT543.Switch S1 is used to initiate the counting.Diode D1 prevents the risk of accidental polarity reversal.
Seven Segment Circuit Diagram with Parts List.
7 segment counter circuit

UP DOWN counter circuit


Description.
This is the circuit diagram of a very simple up down counter that can be used of a large number of applications. The circuit is based on the IC CD40110BE which is a CMOS decade up/down counter. For ICs are used here. Common cathode seven segment display is connected to the 7-segment output of each IC.Display connected to the IC1 represents the lowest number and display connected to IC4 represents the largest number. Synchronous counting is achieved by connecting BORROW and CARRY pins of the preceding stage IC to the CLK DOWN and CLK UP of the next stage IC. For UP counting trigger pulse must be given to the pin7 of IC1 and for down counting trigger pulse must be given to the pin9 of IC1.The RESET pins of all IC are shorted and they have to be connected to ground during normal operation. Connecting the RESET pins to positive supply using the  switch S1 resets the counter.

Circuit diagram with Parts list.


up-down-counter-circuit
Notes.
  • The circuit can be powered from a 9V PP3 battery.
  • All 7 segment displays must be common cathode type.
  • Resistors R1 to R28 must be 680 Ohm ones.
  • R29 and R30 can be 10K ones.
  • Switch S1 can be  a SPDT switch.

Static 0 to 9 display


Description.
The circuit shown here is of a simple 0 to 9 display that can be employed in a lot of applications. The circuit is based on asynchronous decade counter 7490(IC2), a 7 segment display (D1), and a seven segment decoder/driver IC 7446 (IC1).
The seven segment display consists of 7 LEDs labelled ‘a’ through ‘g’. By forward biasing different LEDs, we can display the digits 0 through 9. Seven segment displays are of two types, common cathode and common anode. In common anode type anodes of all the seven LEDs are tied together, while in common cathode type all cathodes are tied together. The seven segment display used here is a common anode type .Resistor R1 to R7 are current limiting resistors. IC 7446 is a decoder/driver IC used to drive the seven segment display.
Working of this circuit is very simple. For every clock pulse the BCD output of the IC2 (7490) will advance by one bit. The IC1 (7446) will decode this BCD output to corresponding the seven segment form and will drive the display to indicate the corresponding digit.
Circuit diagram.
0 to 9 display

Notes.
  • The circuit can be assembled on a perf board.
  • Use 5V DC for powering the circuit.
  • The clock can be given to the pin 14 of IC2.
  • D1 must be a seven segment common anode display.
  • All ICs must be mounted on holders.

Page Rank

google pagerank

Write For Us

Submit a Guest Post

Find us on Facebook

Categories

555 Timer IC 7 segment Display 8051 Project AC Circuits Adafruit Alarms Amplifier Circuits Analog Circuits android Arduino arm processor Assembly Languange Atmel Atom Size Audio Circuits augmented reality Automotive Circuits avr Battery Circuits Bicycle Gurad bluetooth Cable TV Circuits Cambridge University Camera Technology Circuit Boards Clipping And Clamping Circuits Clocking And Timer Circuits Computing contact lens Contact Us Form Contests Controller Circuit Conversion Circuits Counter Circuits Digital Electronics diy circuits Downloads EFY EFYTimes Electronic Books Electronic Components Electronic Locks And Keys Engineering Fan Circuits Filter Circuits Fire Alarm free Frequency Fun And Game Circuits future Google Hack n Mod Ham Radio Circuits heart rate monitoring High Voltage Circuits Home Circuits IC Guide ieee Industrial Circuits Infrared Instructables Inventions ipad lcd Led Circuits Light Related Lighting Circuits Medical Circuits Meter Clocks Microcontrollers Microprocessors Mini Projects modules Movie maker NatGeo Navigation Notice Optical Fiber PC Circuits PCB Boards Physics pnp transistor Power Supplies Printing Projects Programmer Project Ideas Projectors Protection circuits Proximity Detectors Radar Radio Circuits Radio Transmitters Raspberry Raspberry Pie Remote Circuits Retis Lab RFID Robot Cars Robotics Science Science Alert Security And Safety Sensor Circuits Servo Motors Smallest Smartwatches sms Software solar cell sound application Spectram Switch Technology News Telephone Related Television Related Test And Measurement Circuits Thermal Projects Tone generator circuits Touch Screen Tutorials Wearables Wi-Fi Wireless
Like us on Facebook
Follow us on Twitter
Recommend us on Google Plus
Subscribe me on RSS