Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
02/07/02 19:32
Read: times


 
#19511 - RE: Tachometer
Hi!
I was currently working on such kind of project and the technique I have used may be good for you also.
First run a timer for interrupt at certain fixed time like 1sec. Then for all the time before the interrupt, sample the pin(for 1 Tachometer reading) or port(for 8 Tachometers) and count changes at pin/port as much as possible. When interrupt happens, just save the number of changes at input pin/port as result. Then reset the variables to start the whole cycle again.
Let me also remaind that in my project signal current from optical sensor was low and if directly connected to MCU, will result no signal at all. I use opamp unity buffers like LM324.
Also It is on you that how big the variables are, for e.g. if you range is 0 to 255 then you can use byte. I use 16 bit variables.

List of 13 messages in thread
TopicAuthorDate
Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      
RE: Tachometer            01/01/70 00:00      

Back to Subject List