Cumulocity Aggregated Payload Measurement Fragment Limitations for IDE Scripts
Are we able to reference Tag Names with the "/" character in the name in IDE scripts?
To accommodate our requirement to group all Cumulocity Measurement Series in the same Measurement Fragment, we are specifying this grouping by adding the prefix "ewon/" for example to the Tag Name. This works under straight datalogging situations, but the addition of the prefix to the Tag Name prevents us from using that source tag in IDE scripts.
Please consider adding a configuration field for "ParentDeviceAggregatedPayloadType" to specify grouping all tags into a single Cumulocity Measurement Fragment if it is not possible to use Tag Names in IDE scripts with the "/" character in the name.
-
Hi Sean Thomas,
I’m moving this over to a support ticket, as it should help connect you with the right team members who can assist further.
To clarify, could you specify which features come from which source? When you mention “IDE scripts,” are you referring to the Flexy Basic scripts within the Basic IDE interface, or something within Cumulocity?
If you’re referring to Flexy Basic scripts, it would be helpful if you could share a sample of the code for reference and testing.
Additionally, adding screenshots to illustrate the issue or feature request would help the support team address it more effectively. (Pictures say more than a thousand words ;-D)
br
i.A. Franziska Gültig
Thank you!
0 -
Thanks, I am referring to Flexy Basic Scripts. Here is an example of a working script:
TSET 1,60
TSET 2,1
ONTIMER 1, "GOTO upload"
ONTIMER 2, "GOTO counter"
COUNTER:
AI1total@ = AI1@ + AI1total@
//AI2total@ = AI2@ + AI2total@
END
UPLOAD:
AI1total@ = AI1total@ / 60
//AI2total@ = AI2total@ / 60
AI1total60@ = AI1total@
//AI2total60@ = AI2total@
IF (AI1total60@ < 0.1) THEN
AI1total60@ = 0
ELSE
AI1total60@ = AI1total@
ENDIF
GOTO reset
END
RESET:
cokecharLN2_3@ = AI1total60@
AI1total@ = 0
//AI2total@ = 0
ENDAnd the working Tag Set Screenshot:
To ingest the data into Cumulocity in the same measurement fragment, we add "ewon/" as a prefix to the Tag Name. Adding this prefix does not meet the rules of the basic code as a set. The end of the variable does not register the full name as ewon/AItotal60@. Here is a place in the code where that happens:
0 -
Hi Sean,
Thanks for the clarifications!
The team has proposed a solution in the ticket—does that work for you? Are you able to access the ticket to review it?
Best regards,
i.A. Franziska Gültig
instead of accessing tags using the @ suffix in Basic, you can also use the GETIO and SETIO commands to get and set them even if they have slashes in the name. For example
SETIO "ewon/tagname1", 16
PRINT GETIO "ewon/tagname1"The tag name is inside "" whitch makes a "/" just another sign and not programming....
0
Please sign in to leave a comment.
Comments
3 comments