Sadly there is a small mistake in the video. The IR photo diode is positioned the wrong way around. Just imagine the cathode and anode being flipped. Sorry. (Edit: Ok, there is a second mistake. I used the roller adapter in contact mode incorrectly. I just did another measurement the correct way and measured an RPM of 270 while the correct one would have been 230. So this way it was a bit better but still not good enough for me.)
But who knows that? I tried searching for information on that but not even the official manual of the product bothers to mention those details. I think most people would use it like I did.
@@greatscottlab Please make videos for the same project but with a new feature to turn ON a led when the speed reached 40 kmph. Awaiting...thanks in advance.
@@greatscottlab Please make videos for the same project but with a new feature to turn ON a led when the speed reached 40 kmph. Awaiting...thanks in advance.
Great video, especially the DIY aspect of it. For small engine work, it's nice to be able to have full control over period measurement, careful averaging for fast response. And it's always gratifying to bring a small controller, display and interfaces together.
Great video, very informative and practical. Just a thing I noticed, because I stumbled over it not too long ago myself: The two pixel white strip to the right of the OLED (10:03) is most probably caused by a wrong display type. If you have a SSD1306 but initialize it as a SH1106, or the other way around, you get those strips.
Yup, in contact mode, the tacho will be accurately measuring how fast the tacho's shaft was turning. To measure the speed of the shaft, push the contact rubber onto the ene of the shaft, not rolling around its side. The user manual would have made this clear, but it was probably in impenetrable chinglish. Edit: someone else picked up the reason why it failed with the optical - insulation tape's optic properties are horrible. It is designed to be used on the bare shaft of the motor. If you need to add anything to make a mark, try painters masking tape.
What you're saying is correct, But in this case laser tachometer reading incorrect RPM value, Diameter comes into account when we measure travel distance of shaft m/min. DIY wins
That's again is a wonderfull video. I like the DIY or BUY series. Over the past few years, I more often to go DIY. Not just because it's cheaper and I learn while building, but also because I can repair easily and recycle parts if I don't need the device any longer. Thank you for all the fresh ideas. My actual project is a weather station that saves the weather data to an NAS. So I have the complete history available and have at the same time a better accuarcy for temperature, humidity and rain quantity than I got from standard weather station. As a side effect I can easily display abolute air humidity or dew point, which is not available at normal weather stations. I also plan to display a recommendation for room ventilation based on comparing temperature and (absolute) humidity. The internal (display) part might be upgrated by an air quality sensor in the near future, which will improve the ventilation recommendation.
A tip for expansion later: Add a graph of the rpm over time on the lovely Oled display! Would be nice to see if rpm oscillates on things as well! Very few meters can do that.
I bought a similar RPM counter 10 years ago. It came without any of the accessories. ("Digital Laser Tachometer with Pouch (2.5~99999.9RPM"). When I measured a 5400 RPM hard drive platter, the display read 5399 - 5400.
ganz ehrlich, jedes mal wenn ich dir bei schreiben zu gucke bin ich wieder aufs neue fasziniert wie du jedes aber auch jedesmal den selben strich triffst, eins wird sicher sein, du hast kein parkinson :D
Thanks for this , I built it but was getting twice the rpm my scope said ! I have changed 120 in the code to 60 and now it works perfectly. Thanks for a great project. I am going to run it off of an 18650 a fuse instead of the charging board . On the occasions I want to use it I will put in a battery. This keeps costs down for something it will use now and again.
I hope you read this. Please consider making a 3D printed 8th order bandpass speaker with a (hidden) 4.5 inch driver to 250-300Hz with port on same side as a 2.5 inch driver for the rest of frequency range and design a proper crossover for that design. We all learn about crossover eventually and now you can be authority and overcome previous mistake. We love your videos and your excellent efforts.
Nice video. When RPM is low switch from time per pulse to pulses per time. I once harvested IR LED pig-snout pairs (may have been just me that called them that) from VCR's for this. VCR's used them to monitor reel speed and designed more so the LEDs were hidden from each other. They seem rare these days.
@GreatScott. Thank you for including the Entire Creative Process, including misadventures and commenters input. Makes for a more interesting and interactive experience for me. I use DC motors and motor controllers in the Mobility Industry and am drawn to invasive videos such as this. Thank you and your excellent commenters. Too bad I caught this one so late. I blame RUclips for poor notification.
A year ago I had a similar project. I had quite the Problem with the accurate counting, because the Arduino was too fast and produced overcounting because the interrupt was triggered several times at the edge of the tape. I had to use a delay of some us to avoid double counting of rotations. I am rather surprised that your setup worked so well for you.
Hi, i'm currently working on the same kind of tachometer (using mega8 uC, LCD, and the same IR sensor). By inaccurate counting i assume its external interrupt triggers several times while the object passes only 1 time? while testing the IR sensor, i realized after i tried to wave my hand 1 time in front of the sensor, the interrupt count suddenly increments by 4! (and sometimes even 6 lol) this led me to assume that the output of the IR sensor itself is bouncing. (and i dont have oscilloscope to check this since i'm still a student) this issue is solved after adding some RC network to debounce it, and the IR sensor triggers the ext interrupt now correctly (for example i waved my hand 5 times in a fast manner, and the count increments exactly 5 counts) Hope this helps and I'm happy to accept any advice too, thanks~
@@yeyee2418 Hi Yeyee_Gabriel_S_,, seems your solutions can work with me too,, but I'm lack of information about how to connect the RC network to the IR Sensor output,, any reference or some wiring diagrams that I can accessed? Thanks in advance,,
Even for the laser measuring part, you still messed up, you are supposed to attach a wheel to the end of the shaft and use the flat side for color differentiation (like this ◐). Doing so will give an instantaneous signal change instead of a gradual one when you tape on the round shaft. For some reason, your tachometer didn't come with some reflective tapes, these are like the ones on the trucks and provide better contrast.
For contact RPM counter, it's preferable to use IR encoder for accurate measurement. In non contact Measurements many factors affect the accuracy: angle, light, stability of both (the tachometer and the rotor).
Back in my model airplane days some 20 years ago I used a Tower Hobbies optical tachometer to measure the prop speed of my glow engines. It could be set to read the speed of two or three-bladed props. Some of my engines could go as high as 25,000 RPM. I used to check its calibration by pointing it at a fluorescent light to read the line frequency. Seemed to be quite accurate so I never questioned the readings. The only mod I made was to fit a small flat-black painted tube made of cardboard over the sensor port to keep side-light from swamping the sensor, which only used reflected light - no laser. Oh, and I don't think I paid more than $20 for it back then.
Hi Great Scott, I have the feeling that you missed something in the measurement of the rpm by contact. Indeed, your tachometer measures the rpm of its own head, and thus you must introduce a correction coefficient as the rate between the rotor head diameter and the tachometer head. The tachometer cannot know what is the diameter of your shaft!
Exactly! The "by contact" probe should be touching the motor axis in such a way that both rotate at the same angular speed: they mustn't touch side-by-side, but tip-to-tip.
I see it. Says that it's been there for a week. He doesn't go into detail but he said that he figured out he was doing something wrong and retested, and that it was closer but still had some error in the measurements.
So basically you're using a digital counter in front of a shift register - pretty ingenious! The output display can be stabilized more by using a rolling average of the previous three measurements.
I wonder why didn't he choose a veroboard rather than an ordinary perfboard. I think veroboards are better for semi-prototype stuff since their traces resemble solderless breadboards...
You guys right, but it makes the code more readable for people, anyway the characters you put here is way more that you would have spared by skipping “==1”
Thanks for reverse engineering the circuit of the module! I used your schematics to figure out how to add hysteresis (Schmitt trigger) to the circuit: You can easily add positive feedback to the comparator by adding a resistor between the output and the non-inverting input. I just soldered a 20k resistor between the OUT terminal and the anode of the Photodiode on the backside of the PCB. I did this because I had problems with false interrupt triggering on an ESP32 using this module. Apparently the ESP32 external interrupts need a quite fast rise time to trigger reliably. It would have been interesting to see how noisy the rising and falling edges of the signal in your setup are by zooming in on the DSO. The 20k might not work for all sensitivity settings of the trimmer pot. To change the hysteresis it might be a good idea to replace the resistor with another trimmer pot.
Hey GreatScott!, Congratulations on the project, it looks really neat and outperforms commercial equivalents! However, there is a small, 2px wide band of noise on the right side of your display. Its probably due to the display controller being a SH1106 - a "SSD1306-compatible" driver which has 132 px wide display RAM (contrary to SSD1306's 128 px). Most of the libraries and tutorials out there focus on the SSD1306. To fix it, either switch to SH1106 in the graphics library or just find the function which transmits the cursor address and add a permanent +2 term to the x coordinate. I had the same thing literally yesterday so I noticed it immediately. MfG :)
I am from China and I like your video very much and I like it for you. I have also encountered the display problem on the right side of the OLED display because the library is not set up properly.
Using the mechanical tach wrong... The diameter of the shaft will affect the reading using it like that! It has to be directly coupled to the shaft inline and not offset unless the shaft diameter is equal to the tach head you are using.
@GreatScott! Amazing video as always :). I just have one doubt though. In your explanation, you are saying 60 / (rpmtime / 31250), whereas in the code, you are using 120 / (rpmtime / 31250).
Thank you! I’ve been needing a better tachometer for a while but I just don’t want to spend the money on one. I already have the components you used so I can make it right now.
The contact messasure with the outside of the wheel works only with the same diameter of the motor axis . If you want to messaure right you have to conact the middle points of the wheels.
When I used to use some of these cheap optical tachometers I had trouble with 60Hz fluorescent lights in the room. Dark was best. Could that have been any part of the problems your devices were having? Also the flat and the edges of the flat can give spurious reflections that may not be easily ignored by the device.
The central problem is that there is no modulation on the IR LED. Television remote controls would have the exact same problem, except they use a ~38KHz carrier. The fluorescent lights could be easily factored out if the IR LED pulsed on and off, rather than just being nailed on. The “carrier” frequency wouldn’t even need to be particularly high, as even the fastest motor shaft will likely turn
@@a1nelson I wouldn't even use much math on a MCU to check carrier frequency, rather go old school style like IR headphones. Those use FM on 2 frequencies, one channel about 2.8MHz, the other 2.3MHz I think, then it's all analog FM radio tech, basically do the same but keep the frequency constant.
Thank you for the author's release, very practical test device, very suitable for professional technicians: electrician/car repairman/industrial...etc, I like this project, I will create and assemble a 3D shell (There is no need for any circuit board PCB, as long as the distribution line is enough), it will not be long before I will post a comment on the shell 3D printing to stl to share with everyone
Buiz That’s a really good idea. I have a rural property and I’ve long wanted to be able to visualize changing winds and turbulence across a large area. The 3€ comparator part should it a lot easier to fabricate the ~25 anemometers that I’ve been hoping to set up. Wish me luck ;). PS: I wonder how high they should be mounted in order to reject most of the surface effects from the ground...
@@a1nelson I was planning to make mine a project for a government agency here where I have to dot a huge area with weather beacons and all of them will transmit back to the nearest office here via VHF Morse Code
WOW, what a hugely impressive project! I continue to me amazed by your talent, and top of portraying everything in a really great and digestible way. =]
@Saksham Jain The way he used the device is totally wrong. The diameter of the measuring tip is different from that of the shaft of the motor, so for each rotation of the motor the measuring tip only rotates like 0.7 rotation. They basically act as two gears with different rotational speed. The correct way is to push the measuring tip against the center of the rotating shaft so that they rotate at the same speed. This is a very basic mechanical concept (I actually learned it in high school).
It was a distraction mistake. It doesn't require a mechanical engineer to understand what kind of error is produced by measuring in that way, it's something like 1st year high school physics.
Thanks for the video and the tachometer project. I was doing experiments with PC-fans. And i wanted to know how to measure RPM correctly. And see if these sensors from AliExpress could do the job. So I bought a few of them, put one sticker on one of the blades of my 12 cm fan. The result was very dissapointing, the cheap sensor could not read this signal quick enough. Even not below a few hundred RPM (checked on scope via 3rd sensor wire). So these sensors are surely way to slow for this kind of RPM measurements. I bought a proper one (Voltcraft DT-10L laser tachometer, for about 62 euro's). This tachometer can measure up to 99999 RPM and works fine and precisely.
I'm making a similar rev. counter, but I'm finding that the edges produced by the IR sensor are very noisy; it looks like it will need an additional Schmitt trigger to work reliably - the ESP32 board that I'm using never sees less than two interrupts per transition. [edit: I seem to have cleaned up the edges very substantially by putting a 680 pF cap. between the IR o/p and ground - it slows the rise time from about 10 us to 20 us, but the ESP32 seems perfectly happy with that - so maybe there is no need for a Schmitt trigger after all]
An easy-to-implement software upgrade idea: You can measure slow speeds also by not counting the impulses per second (minute), but by measuring the elapsed time between impulses.
Used one of these sensors with my oscilloscope. The problem I had was as soon as I went outside the IR from the sun messed up the sensitivity range. Currently trying with a 38khz tv remote receiver and ir led transmitter.
Wouldn't it be better to computer a moving average rather than the time between each sample? It seems as though a longer sample would give more precise results.
Great!! Would you make a video on electronics basics(not the series) But a single video on the true basics also about purfboard soldering n stuff... Or even a sequel to the arduino 101s series!
Coudln't agree more, long ago i made my own tachometer the same way you did, but instead of checking time between interrupts, i counted how many revolutions i get in 1 second, and then calculate how many in a minute, and display it using a simple 16x2 LCD display... less acurate, but it is what i could do myself back then...
Replace the offset adjust pot with an RC low pass filter. C to gnd, and R to +Vcc. The common between R and C connects to the anode of the IR photo diode. Through a small signal diode like a 1N4148, with the cathode connected to the common RC connection. Set the time constant of the RC to something like 15 Hz, say 10K and 1 uF. Add a resistor in parallel with the C to let the cap discharge slowly. 30 to 100K should be fine. Now the unit will set the offset automatically!!
The problem is do you want to measure pulses pr time unit, and if so what time unit! Or do you want to measure time between pulses, and if so the triggering of the pulse/edge becomes a source of noise due to potential 50/60Hz flicker of ambient lights. It is always a debate. I think many meters use pulses pr time unit and thus have very coarse measurement steps at low end of range.
A few years back I built one for a record player to convince myself that I wasn't hearing things. Naturally I went about it in a far more convoluted way than this. In my defence I think most of the hard arduino code was phase 2, trying to regulate the motor PWM speed.
Question on the contact mode: isn't RPM shaft diameter relative? Strictly, inversely proportional to gear ratio... Buy option still might be good, but it beats the purpose of being "on the field" tool for the additional computation.
Thanks for this project - works great for me. Even at high RPM values. One weird thing i had was that i've to use the analog output of the TRS5000 sensor module - had too much noise on the digital out with this code so I would get random numbers in the 5 digits even when i was testing with a 200rpm motor. With the analog output it works great though. At the end i've used the analog output with an additional schmitt trigger. So if anybody else should have a problem with the digital out of the sensor ....try the analog out.
Inspector gadget awesomeness! Neat what can be measured with the audio and/or video editing software. Those methods alone might even be worth video? Excellent detail as always. Thanks for sharing!
I enjoy watching your videos and I don't argue with your project being more accurate than the HoldPeak, but I have to comment that the *title* is a bit misleading since you are comparing a single 3€ component, which requires a bunch of other parts adding up to about 20€, to a finished 29€ product ready to use.
Sadly there is a small mistake in the video. The IR photo diode is positioned the wrong way around. Just imagine the cathode and anode being flipped. Sorry. (Edit: Ok, there is a second mistake. I used the roller adapter in contact mode incorrectly. I just did another measurement the correct way and measured an RPM of 270 while the correct one would have been 230. So this way it was a bit better but still not good enough for me.)
But who knows that? I tried searching for information on that but not even the official manual of the product bothers to mention those details. I think most people would use it like I did.
Ok. I just tried it this way and the result was better. I got 270RPM with the DC Motor which actually rotates at 230RPM. So still not good enough.
@@greatscottlab Great job, love your vids man, keep it up!
@@greatscottlab Please make videos for the same project but with a new feature to turn ON a led when the speed reached 40 kmph. Awaiting...thanks in advance.
@@greatscottlab Please make videos for the same project but with a new feature to turn ON a led when the speed reached 40 kmph. Awaiting...thanks in advance.
One of my favorite parts of your videos is watching you write. Your handwriting is impressive!
Great video, especially the DIY aspect of it. For small engine work, it's nice to be able to have full control over period measurement, careful averaging for fast response. And it's always gratifying to bring a small controller, display and interfaces together.
Now you‘re just missing a 3d printed case for it and then it would be perfect 👍
Agreed but I would change the layout some to be a bit more compact.
You mean"compact"?
@@111genti yes ty new phone and it puts what it wants LoL 😂.
I thought about it but decided against it in the end to keep it simple.
@@greatscottlab Good decision to make it simple.
Great video, very informative and practical.
Just a thing I noticed, because I stumbled over it not too long ago myself: The two pixel white strip to the right of the OLED (10:03) is most probably caused by a wrong display type. If you have a SSD1306 but initialize it as a SH1106, or the other way around, you get those strips.
Men the diameter of the rolling thing is affecting the values , smaller more turns bigger less turns, you got to used aligned, not in besides
Yup, in contact mode, the tacho will be accurately measuring how fast the tacho's shaft was turning. To measure the speed of the shaft, push the contact rubber onto the ene of the shaft, not rolling around its side.
The user manual would have made this clear, but it was probably in impenetrable chinglish.
Edit: someone else picked up the reason why it failed with the optical - insulation tape's optic properties are horrible. It is designed to be used on the bare shaft of the motor. If you need to add anything to make a mark, try painters masking tape.
To use contact mode you must put the probe coaxial with the motor shaft not side by side like a spur gear arrangement. Great video tho!
He tried that too, wasn't accurate either. 4:12
I was looking for this comment.
What you're saying is correct, But in this case laser tachometer reading incorrect RPM value, Diameter comes into account when we measure travel distance of shaft m/min.
DIY wins
Once, I made a tachometer using a hall sensor effect and a magnet, but this way with the IR sensor, looks much better. Great job!
I really like the way how great scott explain electronics without straining the time limits of his videos.
You've got the best left hand writing skill I've ever seen. You're a phenomenon !
That's again is a wonderfull video. I like the DIY or BUY series. Over the past few years, I more often to go DIY. Not just because it's cheaper and I learn while building, but also because I can repair easily and recycle parts if I don't need the device any longer.
Thank you for all the fresh ideas.
My actual project is a weather station that saves the weather data to an NAS. So I have the complete history available and have at the same time a better accuarcy for temperature, humidity and rain quantity than I got from standard weather station. As a side effect I can easily display abolute air humidity or dew point, which is not available at normal weather stations.
I also plan to display a recommendation for room ventilation based on comparing temperature and (absolute) humidity.
The internal (display) part might be upgrated by an air quality sensor in the near future, which will improve the ventilation recommendation.
0:52 it's kind of cheap for tachometer in comparison to others
The $16 tachometer down there:
Delievery charges ... 100$
A tip for expansion later: Add a graph of the rpm over time on the lovely Oled display! Would be nice to see if rpm oscillates on things as well! Very few meters can do that.
I laughed when see you're sponsored by JLCPCB but build just using perfboard.
For prototyping, why not? Want to make a batch of faulty boards? He use them often.
LMFAOOOOO
@@bryanst.martin7134 they seem fine to me, ive ordered some pretty sketchy looking boards and they still worked fine
I bought a similar RPM counter 10 years ago. It came without any of the accessories. ("Digital Laser Tachometer with Pouch (2.5~99999.9RPM"). When I measured a 5400 RPM hard drive platter, the display read 5399 - 5400.
old stuff what prolly much higher quality
did it cost more?
When you building meter, you have to dealing with non-linearity, error rate, accuracy, precision, and more. It's a whole study case
ganz ehrlich, jedes mal wenn ich dir bei schreiben zu gucke bin ich wieder aufs neue fasziniert wie du jedes aber auch jedesmal den selben strich triffst, eins wird sicher sein, du hast kein parkinson :D
Thanks for this , I built it but was getting twice the rpm my scope said ! I have changed 120 in the code to 60 and now it works perfectly.
Thanks for a great project.
I am going to run it off of an 18650 a fuse instead of the charging board . On the occasions I want to use it I will put in a battery. This keeps costs down for something it will use now and again.
Yes! DIY wins!!
I always wanted to do this project and find out how accurate these IR sensors can measure RPM. Thanks for doing it for me!
Who else starts their Sunday morning with a cup of coffee and a slogan of " let's get started"?
Normally but I'm cranky today!! I forgot to buy coffee yesterday.
@@PerKroon coffeeless mornings is never a good thing 😭
Sorry not the age to drink coffee but soon I can taste it😁
More like coffee evenings in Germany
@@yxcvbnmmnbvcxy544realistically, it's a 24/7 affair 🤩
Gets me going at 8:00 a.m. keeps me up until 3:00 a.m. coffee coffee coffee!!!
I hope you read this. Please consider making a 3D printed 8th order bandpass speaker with a (hidden) 4.5 inch driver to 250-300Hz with port on same side as a 2.5 inch driver for the rest of frequency range and design a proper crossover for that design. We all learn about crossover eventually and now you can be authority and overcome previous mistake. We love your videos and your excellent efforts.
I'm so going watch all your videos today.
Forget about Marvel or Disney....thanks for great entertainment.
Nice video. When RPM is low switch from time per pulse to pulses per time. I once harvested IR LED pig-snout pairs (may have been just me that called them that) from VCR's for this. VCR's used them to monitor reel speed and designed more so the LEDs were hidden from each other. They seem rare these days.
I can't find the code
@GreatScott. Thank you for including the Entire Creative Process, including misadventures and commenters input. Makes for a more interesting and interactive experience for me. I use DC motors and motor controllers in the Mobility Industry and am drawn to invasive videos such as this. Thank you and your excellent commenters. Too bad I caught this one so late. I blame RUclips for poor notification.
i love to see diy win . it so happy our own made product work so fine . i give joy and emotions own hand made things
We need more diy winners very nice video keep up the good work
A year ago I had a similar project. I had quite the Problem with the accurate counting, because the Arduino was too fast and produced overcounting because the interrupt was triggered several times at the edge of the tape. I had to use a delay of some us to avoid double counting of rotations. I am rather surprised that your setup worked so well for you.
Hi, i'm currently working on the same kind of tachometer (using mega8 uC, LCD, and the same IR sensor). By inaccurate counting i assume its external interrupt triggers several times while the object passes only 1 time?
while testing the IR sensor, i realized after i tried to wave my hand 1 time in front of the sensor, the interrupt count suddenly increments by 4! (and sometimes even 6 lol) this led me to assume that the output of the IR sensor itself is bouncing. (and i dont have oscilloscope to check this since i'm still a student)
this issue is solved after adding some RC network to debounce it, and the IR sensor triggers the ext interrupt now correctly (for example i waved my hand 5 times in a fast manner, and the count increments exactly 5 counts)
Hope this helps and I'm happy to accept any advice too, thanks~
@@yeyee2418 Hi Yeyee_Gabriel_S_,, seems your solutions can work with me too,, but I'm lack of information about how to connect the RC network to the IR Sensor output,, any reference or some wiring diagrams that I can accessed?
Thanks in advance,,
Even for the laser measuring part, you still messed up, you are supposed to attach a wheel to the end of the shaft and use the flat side for color differentiation (like this ◐). Doing so will give an instantaneous signal change instead of a gradual one when you tape on the round shaft.
For some reason, your tachometer didn't come with some reflective tapes, these are like the ones on the trucks and provide better contrast.
I have always loved your constructive approach to electronics and making things in general. you inspire me alot. keep up the great work Mr. Scott
For contact RPM counter, it's preferable to use IR encoder for accurate measurement. In non contact Measurements many factors affect the accuracy: angle, light, stability of both (the tachometer and the rotor).
Putting a load on the motor with the physical tachometer will slow it down and reduce the reading...
Back in my model airplane days some 20 years ago I used a Tower Hobbies optical tachometer to measure the prop speed of my glow engines. It could be set to read the speed of two or three-bladed props. Some of my engines could go as high as 25,000 RPM. I used to check its calibration by pointing it at a fluorescent light to read the line frequency. Seemed to be quite accurate so I never questioned the readings. The only mod I made was to fit a small flat-black painted tube made of cardboard over the sensor port to keep side-light from swamping the sensor, which only used reflected light - no laser. Oh, and I don't think I paid more than $20 for it back then.
Just talk about the pens you use sometime.😂 hand writing is soooo smooth!!
Lookup stabilo pointer.
@@tokk3 Stabilo Point 88 :-)
@@greatscottlab I guessed so. Wasn't completely sure.
Quality German pens.
I use them too.
Hi Great Scott, I have the feeling that you missed something in the measurement of the rpm by contact. Indeed, your tachometer measures the rpm of its own head, and thus you must introduce a correction coefficient as the rate between the rotor head diameter and the tachometer head. The tachometer cannot know what is the diameter of your shaft!
Read my pinned comment.
But then the IR Sensor is the better solution anyway. No need to calculate something...
@@greatscottlab There is no pinned comment :(
Exactly! The "by contact" probe should be touching the motor axis in such a way that both rotate at the same angular speed: they mustn't touch side-by-side, but tip-to-tip.
I see it. Says that it's been there for a week.
He doesn't go into detail but he said that he figured out he was doing something wrong and retested, and that it was closer but still had some error in the measurements.
So basically you're using a digital counter in front of a shift register - pretty ingenious! The output display can be stabilized more by using a rolling average of the previous three measurements.
I miss the good old days when great scott used to make prefboards with clean satisfying soldering
I wonder why didn't he choose a veroboard rather than an ordinary perfboard. I think veroboards are better for semi-prototype stuff since their traces resemble solderless breadboards...
@@rizalardiansyah4486 Nevertheless you can still get decent solder traces with prefboard too
if (tooslow == 1)
> Quality code
@Bence Bujdosó only if
int boolean tooslow;
@@Ev-wj3lm Pretty sure Arduino wouldn't mind, since it's basically C/++ and these languages let you do that
@@Multibe150 thanks :) i'm kinda new to arduino...
You guys right, but it makes the code more readable for people, anyway the characters you put here is way more that you would have spared by skipping “==1”
Well, it works.
One of the best videos of 2020
I AM WATCHING YOUR VIDEO FOR MORE THEN A YEAR.... BUT STILL DONT understand ELECTRONICS..... BUT i DONT MISS YOUR VIDEO
I love it when DIY wins , great work scott !
Thanks for reverse engineering the circuit of the module! I used your schematics to figure out how to add hysteresis (Schmitt trigger) to the circuit: You can easily add positive feedback to the comparator by adding a resistor between the output and the non-inverting input.
I just soldered a 20k resistor between the OUT terminal and the anode of the Photodiode on the backside of the PCB.
I did this because I had problems with false interrupt triggering on an ESP32 using this module. Apparently the ESP32 external interrupts need a quite fast rise time to trigger reliably. It would have been interesting to see how noisy the rising and falling edges of the signal in your setup are by zooming in on the DSO.
The 20k might not work for all sensitivity settings of the trimmer pot. To change the hysteresis it might be a good idea to replace the resistor with another trimmer pot.
Im using the same sensor for al kinds of counting stuff, quite accurate if you do you coding well, well worth the effords thumbs up for the video !
I think your video is great! I can tinker with Arduino. I draw with the elek. CAD and then I can order JLCPCB. Perfect! 👍😉😊
At 4:51-5:35 your photodiode is backwards. In this orientation it will conduct whether absorbing IR or not. (In fact, it will emit IR.)
Homemade products are the best, greetings from Mexico
Hey GreatScott!,
Congratulations on the project, it looks really neat and outperforms commercial equivalents! However, there is a small, 2px wide band of noise on the right side of your display. Its probably due to the display controller being a SH1106 - a "SSD1306-compatible" driver which has 132 px wide display RAM (contrary to SSD1306's 128 px). Most of the libraries and tutorials out there focus on the SSD1306. To fix it, either switch to SH1106 in the graphics library or just find the function which transmits the cursor address and add a permanent +2 term to the x coordinate. I had the same thing literally yesterday so I noticed it immediately.
MfG :)
sometimes I wish RUclips has a like button in full screen mode on my laptop. Nice video!
I am from China and I like your video very much and I like it for you. I have also encountered the display problem on the right side of the OLED display because the library is not set up properly.
Using the mechanical tach wrong... The diameter of the shaft will affect the reading using it like that! It has to be directly coupled to the shaft inline and not offset unless the shaft diameter is equal to the tach head you are using.
@GreatScott! Amazing video as always :). I just have one doubt though. In your explanation, you are saying 60 / (rpmtime / 31250), whereas in the code, you are using 120 / (rpmtime / 31250).
We use an adjustable stroboskope light. If the shaft seems like standing still you can calculate the rpm.
Thank you! I’ve been needing a better tachometer for a while but I just don’t want to spend the money on one. I already have the components you used so I can make it right now.
The contact messasure with the outside of the wheel works only with the same diameter of the motor axis . If you want to messaure right you have to conact the middle points of the wheels.
Next on DIY or Buy: The differential probe
Would be nice to see GreatScott attempt to build one :)
I like ur writing and explanation
When I used to use some of these cheap optical tachometers I had trouble with 60Hz fluorescent lights in the room. Dark was best. Could that have been any part of the problems your devices were having? Also the flat and the edges of the flat can give spurious reflections that may not be easily ignored by the device.
Even so, thats a problem that the company should have already know, -1 point for that
@@vermillionreaper Agreed! I don't think it's a defense of the device, but it might explain some things.
The central problem is that there is no modulation on the IR LED. Television remote controls would have the exact same problem, except they use a ~38KHz carrier. The fluorescent lights could be easily factored out if the IR LED pulsed on and off, rather than just being nailed on. The “carrier” frequency wouldn’t even need to be particularly high, as even the fastest motor shaft will likely turn
@@a1nelson I wouldn't even use much math on a MCU to check carrier frequency, rather go old school style like IR headphones. Those use FM on 2 frequencies, one channel about 2.8MHz, the other 2.3MHz I think, then it's all analog FM radio tech, basically do the same but keep the frequency constant.
@@a1nelson Really great explanation. Sounds like we need DIY or Buy - Episode 2!
Amazing. Going to try to build one following your video. Maybe I dont have to buy one again. Thanks for the video
Yes. We can customize our own tacho now
Of course, you can build your own, but it is really time consuming
@@snc1292 maybe. But Im curious in how tacho works.
Looks complicated
@@protustanuhandaru561 of course it is. This is not the typical arduino project we usually do
Really you did hard work, worthy to watch complete video . Excellent 👌
No way scott i was making one
This will be very helpfull!!!!!!!!
Tysm
Thank you for the author's release, very practical test device, very suitable for professional technicians: electrician/car repairman/industrial...etc, I like this project, I will create and assemble a 3D shell (There is no need for any circuit board PCB, as long as the distribution line is enough), it will not be long before I will post a comment on the shell 3D printing to stl to share with everyone
Thank goodness for this vid I can finally understand how to make a DIY anemometer
are you using a propeller for wind and this tachometer method to build it??
@@sayantanmaiti2513 either a prop or the three cup style
@@sayantanmaiti2513 and yes but I might still consider hall effect though
Buiz That’s a really good idea. I have a rural property and I’ve long wanted to be able to visualize changing winds and turbulence across a large area. The 3€ comparator part should it a lot easier to fabricate the ~25 anemometers that I’ve been hoping to set up. Wish me luck ;). PS: I wonder how high they should be mounted in order to reject most of the surface effects from the ground...
@@a1nelson I was planning to make mine a project for a government agency here where I have to dot a huge area with weather beacons and all of them will transmit back to the nearest office here via VHF Morse Code
WOW, what a hugely impressive project! I continue to me amazed by your talent, and top of portraying everything in a really great and digestible way. =]
Your Intro is awesome 😍
3:17 This is how you know that you're dealing with an electrical engineer and not a mechanical engineer.
I was surprised by that too 🤣
@Saksham Jain
The way he used the device is totally wrong. The diameter of the measuring tip is different from that of the shaft of the motor, so for each rotation of the motor the measuring tip only rotates like 0.7 rotation. They basically act as two gears with different rotational speed.
The correct way is to push the measuring tip against the center of the rotating shaft so that they rotate at the same speed. This is a very basic mechanical concept (I actually learned it in high school).
Look at the top comment
@@Willeexd1337 He edited his comment after I posted this.
It was a distraction mistake.
It doesn't require a mechanical engineer to understand what kind of error is produced by measuring in that way, it's something like 1st year high school physics.
Your content is about very useful tools and stuff we can diy
Keep it up:)
Timer capture peripherals are awesome. I use them extensively.
Thanks for the video and the tachometer project.
I was doing experiments with PC-fans. And i wanted to know how to measure RPM correctly. And see if these sensors from AliExpress could do the job. So I bought a few of them, put one sticker on one of the blades of my 12 cm fan. The result was very dissapointing, the cheap sensor could not read this signal quick enough. Even not below a few hundred RPM (checked on scope via 3rd sensor wire). So these sensors are surely way to slow for this kind of RPM measurements.
I bought a proper one (Voltcraft DT-10L laser tachometer, for about 62 euro's). This tachometer can measure up to 99999 RPM and works fine and precisely.
I'm making a similar rev. counter, but I'm finding that the edges produced by the IR sensor are very noisy; it looks like it will need an additional Schmitt trigger to work reliably - the ESP32 board that I'm using never sees less than two interrupts per transition.
[edit: I seem to have cleaned up the edges very substantially by putting a 680 pF cap. between the IR o/p and ground - it slows the rise time from about 10 us to 20 us, but the ESP32 seems perfectly happy with that - so maybe there is no need for a Schmitt trigger after all]
I found using old IDE cables make running traces so much easier. You can make a ribbon as wide as you need. Bend it wherever you want. Lays flat.
I had once made RPM counter with telly counter & Reed switch
Clearly a WIN for DIY !
thanks Scott.. Video very clear, complete, complex and so on... See you next video...
Another mistake that you made is that the optical reading of the laser tachometer needs retroreflecting tape..usually it's included in the box
An easy-to-implement software upgrade idea: You can measure slow speeds also by not counting the impulses per second (minute), but by measuring the elapsed time between impulses.
Thank you. This will come in useful: I'm building a shaking water bath and needed a way to calibrate the shaking.
If you use a bigger prescaler value in your timer or also count overflows between measurements you could get a lower minimum RPM.
Just got mine to work : = )) Had to change the resistance pot some to get to start reading.
Yeeeeeeeees next awesome video!
Used one of these sensors with my oscilloscope. The problem I had was as soon as I went outside the IR from the sun messed up the sensitivity range.
Currently trying with a 38khz tv remote receiver and ir led transmitter.
Wouldn't it be better to computer a moving average rather than the time between each sample? It seems as though a longer sample would give more precise results.
Great!!
Would you make a video on electronics basics(not the series)
But a single video on the true basics also about purfboard soldering n stuff... Or even a sequel to the arduino 101s series!
Tbh, the arduino 101s sequel would be great!!
there already is a video about soldering
@@ianthehunter3532 yea... But the arduino one tho... : )
ruclips.net/video/1R3fqSFCAjM/видео.html here is everything you need to know about arduino
ruclips.net/video/dany7ae_0ks/видео.html and use this for programming. It's A LOT better
Nice!!! I will make it!!!!! I love this projects. Good job mate 😉
Coudln't agree more, long ago i made my own tachometer the same way you did, but instead of checking time between interrupts, i counted how many revolutions i get in 1 second, and then calculate how many in a minute, and display it using a simple 16x2 LCD display... less acurate, but it is what i could do myself back then...
DIY winner 😍😍😍
sincerely I got excited about this idea cause I think is the only one y can make without getting any extra parts.
Replace the offset adjust pot with an RC low pass filter. C to gnd, and R to +Vcc. The common between R and C connects to the anode of the IR photo diode. Through a small signal diode like a 1N4148, with the cathode connected to the common RC connection. Set the time constant of the RC to something like 15 Hz, say 10K and 1 uF. Add a resistor in parallel with the C to let the cap discharge slowly. 30 to 100K should be fine. Now the unit will set the offset automatically!!
the two small cups are for putting on the end of a shaft, center to center.
The problem is do you want to measure pulses pr time unit, and if so what time unit! Or do you want to measure time between pulses, and if so the triggering of the pulse/edge becomes a source of noise due to potential 50/60Hz flicker of ambient lights.
It is always a debate. I think many meters use pulses pr time unit and thus have very coarse measurement steps at low end of range.
A few years back I built one for a record player to convince myself that I wasn't hearing things. Naturally I went about it in a far more convoluted way than this.
In my defence I think most of the hard arduino code was phase 2, trying to regulate the motor PWM speed.
Nice how did it work out in the end, been thinking of a stepper motor record player with one of these to be self correcting
I used a Hall sensor to make my RPM counter it also works flawlessly
Question on the contact mode: isn't RPM shaft diameter relative? Strictly, inversely proportional to gear ratio... Buy option still might be good, but it beats the purpose of being "on the field" tool for the additional computation.
Learned a lot more in new video
Thanks for this project - works great for me. Even at high RPM values. One weird thing i had was that i've to use the analog output of the TRS5000 sensor module - had too much noise on the digital out with this code so I would get random numbers in the 5 digits even when i was testing with a 200rpm motor. With the analog output it works great though. At the end i've used the analog output with an additional schmitt trigger. So if anybody else should have a problem with the digital out of the sensor ....try the analog out.
How to get analog out of this sensor?
@@ikarib There are 2 versions of this board. They've the identical setup, but one has 4 pins instead of 3 so you also have an analog output.
☆Awesome☆ You are a real pro!
9:36 -- Of course you know, but just for the pedantic record, 2^16 = 65536, not 65535. :-)
"And a theoretical never practically reachable maximum"
I'm dying 🤣🤣🤣
Inspector gadget awesomeness! Neat what can be measured with the audio and/or video editing software. Those methods alone might even be worth video? Excellent detail as always. Thanks for sharing!
I enjoy watching your videos and I don't argue with your project being more accurate than the HoldPeak, but I have to comment that the *title* is a bit misleading since you are comparing a single 3€ component, which requires a bunch of other parts adding up to about 20€, to a finished 29€ product ready to use.
Brilliant idea. Good lateral thinking!
Great project with really good explanation.
Wow Sir, Great project 👍🔥🔥