Allen Posted November 21 Posted November 21 Sorry in advance for the long post, but I tried to provide as much information as possible and also provide the answer to the most common questions. I am trying to use the pulse counter feature of the Shelly Uni Plus and the number is significantly higher than the actual number of pulses. For example, if you touch the pulse wires together 1 time, it counts as 5, if you touch the wires together 2 times, it counts as 12, etc. I've done an a lot of research on this and even hired a mechanical engineer to figure out the cause and in the end found out that it is actually normal and caused by mechanical bounce. This is when the pulse is made, the wires don't instantly connect and disconnect, they literally bounce for a few microseconds, which technically makes more connections. This is not visible by the naked eye, but through testing, it is seen and proven on an oscilloscope. I attached a simplified illustration of what I am talking about. I have the real oscilloscope results if anyone wants to see them too. A pull up resistor can clean it up a bit but still does not resolve it. On the Raspberry you can filter out these bounces with the "pigs fg" command, which makes it ignore connections lasting less than X "microseconds", eliminating bounces counting as pulses. Does anyone know if this is possible with the Shelly Uni Plus? Without being able to correct the count, the pulse counter function is not useful. There aren't many videos that exist yet of people using the new Shelly Uni Plus pulse counter function, but in them people just take these significantly higher pulse count numbers and just reverse calculate what a pulse equals. For example, if each real pulse sent registers as 100 on shelly, they just divide the number by 100 to get the "real" pulse count. This seems logical to do, however, over time wires/contacts will wear out and therefore will not consistently register the same multiple of pulses per real pulse. Even if the margin of error is small, over time and with high volumes, it will really change the accuracy of the results. Furthermore, you would have to test every new device you add to see how much a real pulse really registers as on shelly. Even 2 of the same devices (ie, water flow meter) manufactured at different times can have different results. Pulse counters like this are mostly used for metering usage (water/gas/etc), for home/personal use it may not matter, but for anyone using it to bill based on the numbers reported, it can not be used since it is not accurate. Meters themselves go through rigorous testing to make sure that each pulse it sends is calibrated to equal X volume, so it is important that any pulse counter receiving them counts them exactly as they are sent. I absolutely love all of the Shelly devices, I really hope this issue can be addressed. Thanks! Quote Translate Revert translation? English (American) Finnish French German Italian Portuguese (European) Spanish
Members thgoebel Posted November 21 Members Posted November 21 Debouncing of the COUNT input may be done with two alternative approaches: (a) Hardware Debouncing b) Digital Input for debouncing Method (a) deploys a low pass in front of the COUNT input (as it is internally done with IN-1/IN-2). Method (b) utilises the internal debouncing of the digital input (e.g. IN-2) and counts the clean output signal. 1 Quote Translate Revert translation? English (American) Finnish French German Italian Portuguese (European) Spanish
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.