Menu
JAQForum Ver 19.10.27

Forum Index : Microcontroller and PC projects : Micromite IR TACHOMETER

Posted: 05:47am
01 Feb 2026
Copy link to clipboard
OA47
Guru


Just going through some of the unfinished projects and came across a handheld IR TACHO that I built many years ago. I have very simple code to run this unit but I feel it can be made much more accurate and reliable. Here is the code currently:

' IR TACHOMETER PROGRAM FOR MICROMITE
' IR LED POWERED ON
' IR RECEIVER CONNECTED TO PIN 16

' INITIALISE PINS FOR 2 LINE LCD
LCD INIT 2,3,4,5,23,24

SetPin 16,FIN            'IR RECEIVER
Dim Spin,I

LCD 1,3,"IR TACHOMETER"
LCD 2,10,"  RPM"
Do
 Spin=0
 For I = 1 To 10
   Spin = Spin + Pin(16)
 Next I

 Print Spin/10;" Hz"

 LCD 2,1,Str$(Spin*6)
 Pause 500
 LCD 2,1,"      "
Loop


Has anyone any suggestions to improve this program?

OA47
 
Posted: 06:44am
01 Feb 2026
Copy link to clipboard
ville56
Guru

Tbh, I don't get the program logic at all...
 
Posted: 07:06am
01 Feb 2026
Copy link to clipboard
phil99
Guru


  MM 5.05.05 manual said  Counting Inputs
The pins marked as COUNT can be configured as counting inputs to measure frequency, period or just count
pulses on the input.
For example, the following will print the frequency of the signal on pin 15:
> SETPIN 15, FIN
> PRINT PIN(15)
110374
>
In this case the frequency is 110.374 kHz.
Multiply by 60 for RPM.

The one I built uses an IR remote control receiver and the IR LED is fed with a 38kHz 50% PWM output.
This gives it a much better tolerance for high ambient light and works at a greater distance due to the narrow bandwidth, high gain and excellent AGC of the IR receiver.
Tested to 30,000 RPM.
Edited 2026-02-01 17:08 by phil99
 
Posted: 11:18am
01 Feb 2026
Copy link to clipboard
Volhout
Guru

Hi OA47,

remember...

https://www.thebackshed.com/forum/ViewTopic.php?TID=16669&P=2#217359

Volhout
 
Posted: 11:33pm
01 Feb 2026
Copy link to clipboard
OA47
Guru


Volhout, thankyou for bringing that to my attention. Obviously my static brain ram backup battery has faded and I have been down this road before.


OA47
 
Posted: 08:05am
02 Feb 2026
Copy link to clipboard
Volhout
Guru

Hi OA,

You simply picked up again where you left of last time.

Volhout
 


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2026