Hi
I installed nymea and have my resol solar water system sending values via mqtt . The generic temperature sensors are hooked up with magic , but I can’t find a suitable sensor to use for the pumps. Ideally a gauge sensor that shows the pump speed as say 30% , any suggestions on how to handle pump speed and history ?
I also hooked up the generic power consumer to mqtt , is there a way to turn off the total value feature and to also graph consumption over time ?
Lastly is there a pattern for making sensors show an error if they haven’t received an update in N seconds ?
Thanks for any help or hints
Hmm, there’s no generic water pump yet… Sounds like something that could be added though.
In the meantime you may use the generic ventilation with flow control… That will use the wrong icon in the ui, but provide the features you’d need.
Do you feel like creating a pull request to duplicate the generic ventilation with flow control thing class but renaming it to water pump with flow control on https//github.com/nymea/nymea-plugins-genericthings?
Currently it is specified that energy related things are required to have both, a currentPower and a totalEnergyConsumed state. There are various parts in the system relying on the fact that both states will be present. However, if you don’t need that, you may just leave the totalEnergyConsumption state always set to 0. That should work just fine.
The generic things don’t use the “connectable” interface. That has been done to not require users to always set the connected state in generic things as most of the times it’s not needed. I agree that sometimes it would be nice or even important to have that. For now, can probably still detect that in your MQTT script (by re-starting a Timer on every received data packet) and dunno, use some other thing class, or send out notifications or something when it drops out.
I can take a look at using the generic ventilation, I tried it and it kinda worked, as it wasn’t a sensor there was no history graph, and as it allowed you to change the speed which makes no sense in my case as a sensor. i’m new to nymea so will have to read the dev docs
my energy sensor doesn’t hold a total, it’s a pi hooked by gpio into a S0 output, and is currently stateless. I could modify it to keep state/totals
I’ll look at the Timer idea, I haven’t looked at timers yet, hopefully that will give me a path to set the values to 0 or -1 when the timer fires, and reset the timer when there are legit values via mqtt, thanks for that idea
Oh, sorry, I misread. You want a sensor, not a control… In that case we’ll need to see. There was also another request for a flow rate sensor. It definitely would make sense to have that…
The timer idea worked out, thanks for suggesting that. now when an mqtt message arrives the timer starts, and if it reaches the end , it sets all values to zero. any mqtt message resets the timer.
I’m using a generic temperature sensor for pump speed right now, works fine with the obvious wrong graphic and scale units. I might take a look at whats involved in forking that to something more suitable ?
yeah, totally. So I think in order to make it really good we’d first need a interface (libnymea/interfaces/) in the nymea main repository which defines how such flow rate measurement should look like. would a “flowrate” interface with a unit of m³/s make sense here?
The next step would be to go to the nymea-plugins-genericthings repository and add a new thingclass for it, following the interface that was defined in the previous step.
And lastly, nymea:app would need to get support for that interface, including a fitting icon and stuff…
For my controller to the pump a percentage only makes sense, the solar controller speeds it up and down based on temperature differences , so a generic percentage sensor would work well, which can reuse the unit types and images already in nymea I think ?
Percent doesn’t always correlate to speed , and flow rate is a calculation of speed and displacement afaik
My controller (resol) gives percent readings on its serial output which is what I’m using