| Posted: 05:47am 01 Feb 2026 |
Copy link to clipboard |
 Print this post |
|
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 |