Home - Search - Members
Full Version: plz help me.....
tayyab
Jun 23 2008, 8:51 AM
i want to make a speed and distence meter for a boat by using microcontroller.
a speed signal is generated by a sensor which has the frequency equals to the 10 times of engine shaft ratation. eg if engine shaft is rotating 60 times in a second then sesor gives the signal of 600 Hz. sensor also generate a refresh pulse in a second with pulse width of 0.33 sec.
the question is that how to programme the microcontroller for counts these pulses. thanks
pdi33
Jun 23 2008, 10:49 AM
use the internal counter of the 89c51. here u have to just input the pulses from the speed sensor (assuming they are at +5V level) to the T0 pin of the uC. Check the TMOD and TCON registers of the 89c51 in its datasheet for the description of how to use the internal timers of 8051 in counter mode.
If the refresh pulse u mentioned is another output of the sensor, then connect that input to the external interrupt of the 89c51 so that it can be processed in the respective interrupt service routine.
grace
Jun 24 2008, 3:57 PM
hello can anybody help me find a book regarding mobile robotics..
pdi33
Jun 24 2008, 8:53 PM
hi grace,
please stick to the subject of the thread. Post ur doubt on a new thread in the appropriate section of the forum.
here is a link to the appropriate place for ur doubt:(e-books & tutorials section)
http://www.8051projects.net/forum18.html
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Rickey's World © 2003 - 2007