Hello,
I’m using Attribute Links configuration option to populate asset attributes from another JSON attribute linked with MQTTLink Agent and it works fine. My Attribute Links JSON:
[
{
"ref": {
"id": "5mEPbDgAIcTae1eI14DqGP",
"name": "temperatura_akt"
},
"filters": [
{
"type": "jsonPath",
"path": "$.object.TempC_SHT31",
"returnFirst": true,
"returnLast": false
}
]
}
]
Currently I want to populate this attribute (“temperatura_akt”) with value returned from MQTTLink but additionaly I want to sum it with a another attribute value (“delta_callib_temp”). “delta_callib_temp” attribute is defined within the same asset as “temperatura_akt”.
So finally (in pseudocode)
asset.temperatura_akt.value=$.object.TempC_SHT31+asset.delta_callib_temp.value
Is it possible?
I’ve tried to use Flow Rule, rule works but since “temperatura_akt” is “date point” attribute it creates new value for it instead of just update and on “History” chart for “temperatura_akt” we have 2 values for one MQTTLink action (value passed from AgentLink and few secs later new value generated by rule). So I think we need to somehow modify value in “Attribute Links” option