I'm trying to move my last few things from WebCore, but I can't seem to get the %device% or %value% to work correctly. Below is my Rule. It sends either Null or last time Triggered. example: "Yo, Triggered has a low battery. It's at percent." (Triggered was odd and nothing between at and percent.)
here is another response: "Yo, null has a low battery. It's at 0 percent."
Does anyone know what I'm doing wrong?
BTW I know it will only send one at a time. I'm ok with that. My percentage is high for testing. I will have other rules like this for motion and leak sensing.
%device% and %value% are derived from the "trigger event" of the rule. In order to achieve what your after you will need to use the "battery level" as the trigger and then your announcement. You could also add a "wait for event - certain time" if you only want the alert at that time.
Unfortunately, this will not create a "list of devices/values" only the one that triggered it.
I was typing something exactly like the above, so I don't have anything to add except that, as you've discovered now, RM doesn't have anything built in quite like webCoRE's "save matching devices to this variable" feature (or even devices as variables at all; %device% gives you a string representation of the name, though that is sufficient for your case--if if were populated). You can probably re-create something with a lot of conditionals (not fun with that many devices), but I like the idea suggested above as a workaround!
Alternatively, there are some community apps that can monitor battery level for you and send notifications like this. Device Watchdog is one I know of off the top of my head.
Finally, you should know that many people find battery reporting unreliable and just use an app like the above (or one of a couple other community solutions) to monitor device activity instead, which can be more helpful to know, assuming you're trying to tell when something may have stopped working. Battery is a bit more proactive and can be if you find the right values to test for, but with how unreliable it can be, you might never.