I don’t want this to sound like an accusation or anything, but is Cayenne still in the early stages or something? Maybe I am just not the target market, but it seems very simple-minded to me, even with the REST API. I’m sure those simple things are useful for a lot of things, but they are still pretty limited.
For example, I can set a threshold alert for a sensor. Yay. But I want to send an alert/notification only after my data is above a certain value for at least N minutes. I want to send another alert/notification when it gets back down below some threshold … after having been above the threshold for a while.
For example, if my temperature sensor goes below 32F for more than 15 minutes and the trend has been generally downward, then send me an alert. On the other hand, if I am 10 minutes into my long drive to a remote site and the temperature goes back up above 34F, send me another alert so I can go back home and have some eggnog.
Maybe I’m just not good enough at finding out about Cayenne features, but the only way I can figure out to do those things is to keep track of it on my device and then send some kind of fake sensor data to Cayenne when I want things to happen. If I have to do that, all I’m getting from Cayenne is an inconvenient SMS or email notification service. There are about a zillion ways to do that these days.
Again, I’m not accusing Cayenne of being useless or saying that you should cater to my special needs. I’m really just asking if I’m in the wrong place for what I am looking for.
A quick answer for your post: Yes, the platform is still growing (a work in progress). There was recently some more devs added to the Cayenne team and they have been very active fixing bugs that have been lingering. Once most of the bugs are fixed I’m sure they will begin working on the road map items such as the triggers you posted about.
These triggers have been discussed in the past and it is on the road map to implement.
Unfortunately that’s the only workaround for now.
Tagging @bestes and @rsiegel to see if they have anything to add.
These are the use cases that are extremely helpful for us as we design new features! Please please continue to let us know what you want to see from us
OK, here’s the scenario I was actually trying to implement when I asked the question.
I am monitoring the power on my washer and dryer so that I know when they are started and (more importantly) when they stop. The dryer has a pretty steady current draw over the entire cycle because it’s gas-powered. So it’s only the spinning of the drum that is electrical. But the washing machine goes through all kinds of ups and downs during the cycle, and there are lots of cycle types. In fact there are periods when it seems to be thinking about something and not actually doing anything. That would be a false positive for stopping.
My solution is to implement the threshold logic in my microprocessor code, including a delay of 1 minutes for start-up and a delay of 6 minutes before I conclude the washing machine has really stopped. I also keep track of the on-off state of both machines. I periodically update the power draw values, but I also use a pair of fake channels to have a value of -2 for off, 2 for on, and 0 for indeterminate. Then it’s easy for me to use Cayenne triggers based on the fake channels to notify on start-up and stop.
That’s all fine and works as expected, but I’m really just using Cayenne as a notification service. The graphs and gauges are just pretty stuff for my own amusement.
For some, it might not be so obvious why having all of that logic on the server is better than having it in the microprocessor code. So, here it is:
If I need to tweak one of the parameters for an appliance, I need to connect the microprocessor to a laptop and download tweaked firmware. For example, right now I am experimenting with my thresholds for on and off for the washing machine. It’s tedious. If it were on the server, I could just be fiddling with the values in my triggers.