Open pkejval opened 1 year ago
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This might be better now that https://github.com/esphome/esphome/pull/4231 has merged. I had a similar problem with high pulse rates so I refactored the pulse_meter to handle them better
The problem
I found out that pulse_meter is unable to read more than 120 Hz of pulses (7500 RPM). With increasing frequency it then shows only these values - 8600 RPM, 10 000 RPM and 20 000 RPM - completely off values. pulse_counter sensor is working fine even with much higher frequencies.
It can be easily tested with YAML posted here. Just connect GPIO2 with GPIO22. I made ledc output where you can set frequency at runtime. RPMs are limited in both cases if set to PULSE or EDGE mode.
Which version of ESPHome has the issue?
2023.4.2
What type of installation are you using?
Home Assistant Add-on
Which version of Home Assistant has the issue?
No response
What platform are you using?
ESP32
Board
wemos_d1_mini32
Component causing the issue
pulse_meter
Example YAML snippet
Anything in the logs that might be useful for us?
Additional information
When I use pulse_counter I can measure RPM for hundreds, thousands of Hz without problem.