Custom Attributes in Conditions - RM interface bug

I am attempting to use a custom attribute in a condition in a rule. The interface allows me to specify the device and then to select the attribute I want to use. However, the interface doesn't give me the option to specify what I want to compare the attribute value to. In my specific case, the attribute is boolean. The interface does not give me a chance to save the condition. The only option it gives me is to cancel.

This is most likely a driver bug. What driver and what attribute?

2 Likes

It is my own device driver code. I can't rule out a bug. The attribute shows up correctly on dashboards. What does my driver need in order for attributes to be available in rule machine? I have reproduced what I expect are relevant parts below:

metadata {
definition (name: "HVAC Zone Status", namespace: "rbaldwi3", author: "Reid Baldwin", cstHandler: true) {
capability "Actuator"
capability "Refresh"
}
attribute "offline", "boolean"
command "set_offline", ["boolean"]
}

Boolean is not a valid attribute type.

That would explain it. I guess I should use string and set it to either true or false.

But is BOOL? :slight_smile: The docs suggest that it is: https://docs.hubitat.com/index.php?title=Attribute_Object. If not, I could submit an edit for that page if that is somehow less work than someone just changing it themselves.

Niether is. My guess is that our driver implementation is wrong, and that it should support BOOL. But the current situation is that it does not, so there are no defined possible values for the attribute, so RM can't find anything to compare to.

Work-arounds involve using some other bistate capability.

I'm going to look into what's up with this.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.