RPM Meter Development Using PIC Microcontroller
PIC 16f877 based Rotation Per Minute (RPM) Meter Development:-
In this Project we will develop a RPM meter using PIC microcontroller PIC 16f877. The main components used in this project will be as follows.
Components of RPM meter:
1. The heart of the Project is Microcontroller which does all the necessary calculation and processing, here we use PIC16f877 micro controller manufactured by microchip.
2. Electric motor, whose speed is subject to check, here we use DC 12v motor with FAN blades.
3. Transducers to convert the motion into electrical energy, so that is could be processed, here we used custom self made transducer based on LED ( light emitter part) and Light sensing part (The Photo transistor).
4. Analog voltages processing, for this an operational amplifier is used which is continuously comparing the voltages and generating digital outputs suitable to feed micro-controller.
5. The last and off course more important part is display, here we have freedom to use LED seven segment display or LCD display or just LED to show the speed.
Functional Overview of the Project (RPM Meter Development Using PIC Microcontroller):
The system counted and stored fan motor blade crossing of the emitter/detector during 5ms intervals and stored the data to an internal EEPROM. The data was also displayed on an LED output for instant velocity monitoring.
Objectives of RPM Meter Development Using PIC Microcontroller:
The objective of this project was to build a circuit that could act as either an accelerometer or a speedometer for a DC motor; this data can be related to the position, speed and acceleration of the motor. This kind of data is extremely useful in robotics design, as this will give the user a more fixed control over a system. The circuit was to give counts of fan blades passing a photo-emitter-detector pair at fixed intervals.
Dividing the fan blade crossing on a per second basis by the number of fan blades gives
the fan’s speed.
Explanation of The Project RPM Meter Development Using PIC Microcontroller 16f877 :
The phototransistor circuit is used in this project with an infra-red LED emitter as an emitter-detector pair to identify fan-blade crossing. Results of one of these experiments are presented as background to using a comparator for this project.The programming a PIC microprocessor PIC16F88 and doing digital and analog inputs and outputs with the microcontroller units (MCUs).
The phototransistor is used in a voltage divider. The photo transistor will turn the transistor on as light hits it, decreasing the voltage at Vout.
The PIC 16F877 used has a built in oscillator that can operate at different speed from 137kH to 8Mhz depending on how the OSCCON register is set-up for PIC 16F877. It also has an interrupt counter byte TMR0 that counts from a specified number to 255 and then resets. The TMR0 counts at a ratio of the total oscillator speed that is set by the user with the OPTION_REG register. An interrupt function can be
enabled to execute every time the TMR0 number rolls over from 255 to 0. This interrupt routine can in turn increase other counter variables (i.e. cnt) to achieve help schedule less frequent events.
The LMC 6482 Op-Amp chip is a rail op-amp that was used as a comparator. A comparator on an op-amp works like an op-amp with no feedback; the output of a comparator goes high whenever the positive input is greater than the negative side or goes low if the reverse is true. An adjustable potentiometer (trimpot) is connected to the high and low microprocessor power supply, and the adjustable pin of trimpot is
connected to the negative input of the op-amp/comparator.
A DC fan has two wires, one for power and one for ground. As it is a simple motor, the more voltage put into the motor the more the speed of the fan will increase. The fan’s running voltage is about 3-8 Volts. This experiment tries to measure the fan speed by counting how often the fan blades pass between the photo detector circuit.
The first step in both speedometer and accelerometer processes is to count the number of fan blades per time period coming in.
I WANT TO DOWNLOAD AND STUDY THE PROGRAMMING LANGUAGE OF THE MIKRO-C CODE PROGRAMMING AS I AM ALREADY A ASSEMBLY LANGUAGE USER. AND I AM NOW PROGRAMMING THE pic16f877a MICROCNTROLLER TO MEASURE THE ENGINE RPM TO CONSTRUCTE THE ecu OF A CNG ENGINE.
THANK!
THURAAUNG
TU (MANDALAY)