Jump to content

UOM "Type Casting" Possible?


Go to solution Solved by Javi,

Recommended Posts

I realize that I still, after years of plugging away on my own and lurking in the forums, have some gaps in my understanding.

As far as Notifications and Variable Substitution:
Recently I just learned for the first time about ${sys.program.#.name} and feel silly for not knowing that one (though it's mentioned here and there, including in Jimbo's Notification NS screenshots, it doesn't seem listed out in the actual Wiki).

So maybe my long-standing complaint about UOM values not being always reliable or passed through in Notifications is simply a case of me not understanding .UOM.id or some other extension / syntax?

Pain point:
My Z-Wave locks (August Pro, 3rd gen) have an ALARM node that shows in Admin Console the last received state change's source (Manually unlocked, RF locked, Keypad unlocked, Auto-lock, Jammed, etc).

image.png.180f01717a990fb6e242cce64b27783c.png
(yes, I took the time to nn my node # in the screenshot above)

I can even use those values in programs as a condition for my IFs:

image.png.f66554f1a33d1f7e689d108c2f941071.png 
=
image.png.e3738f41105db4e2786d7b649876429a.png

But I have never found a variation of any substitution that ever returns anything other than the numeric value of the state (for 'Manual unlock', it'd be '2', as an example above and below) -- I'd like it to return the UOM type 25 string, instead.

${sys.node.ZY0nn_306} = ""

${sys.node.ZY0nn_306.ALARM} = 2
${sys.node.ZY0nn_306.ALARM.RAW} = 2

${sys.node.ZY0nn_306.ALARM.ST} = ""
${sys.node.ZY0nn_306.ALARMSTATE} = "ALARMSTATE"
${sys.node.ZY0nn_306.ALARMSTATE.ST} = "ALARMSTATE.ST"
${sys.node.ZY0nn_306.UOM} = ""
${sys.node.ZY0nn_306.ALARM.UOM} = ""
${sys.node.ZY0nn_306.ALARM.ST.RAW} = ""
${sys.node.ZY0nn_306.ALARM.ST.UOM} = ""


Maybe this is more of a Product Request, if it's not something I'm overlooking?
I can see the benefit of both nodes values and variables being able to be "typecast" into a UOM of choice as specified in a customized Notification.

Edit: here are the node details, if it helps:

image.png.ff9e490a0d943312e9dc7e456e37d18c.png

 

Edited by residualimages
add last screenshot
Link to comment

Based on the the <nodeInfo> it appears IoX does not have the formatted value (formatted="2").  Can you please let me know if UD Mobile shows the formatted value or a numerical value for the same ALARM Status?  

The reason the formatted value is shown in Admin Console is because Admin Console parses values itself it does not use the IoX parser. However when a notification is sent the IoX parser is used.

Link to comment
18 minutes ago, Javi said:

Can you please let me know if UD Mobile shows the formatted value or a numerical value for the same ALARM Status? 

UD Mobile shows only the numeric value, not the UOM string.

18 minutes ago, Javi said:

The reason the formatted value is shown in Admin Console is because Admin Console parses values itself it does not use the IoX parser. However when a notification is sent the IoX parser is used

I know that we say IoX these days, but the original experience / pain point was , and is still, present on my ISY994i too, of course.

Edited by residualimages
IoX comment
Link to comment
21 minutes ago, residualimages said:

I know that we say IoX these days, but the original experience / pain point was , and is still, present on my ISY994i too, of course.

This was a bug in ISY994i.  I thought it was fixed in Polisy/eisy firmware.

Link to comment
  • Solution

Thanks, looks like a similar bug.  If you want this tracked please open a ticket. 

Attach images for <nodeInfo>, <nodeDef>, AC image, and a zipped Backup File for your system (Not a UD Mobile backup).

Include this as the issue:

"Encoded Editor missing formatted values in rest/nodes, and Subscription Event."  This causes missing formatted values in Notifications, Emails, and on UD Mobile."

If you open a ticket send me a Private Message with the ticket number.

Link to comment
Guest
This topic is now closed to further replies.

×
×
  • Create New...