Abstract
This technote talks about the method to use MQTT from VT Scada down to a Crimson 3.2 based device
Products:
FlexEdge DA50 & DA70
Use Case: Getting Data from VT Scada with MQTT
Problem:
Crimson based devices can easily write up to a VT Scada Server using our Generic MQTT driver. But writing down it difficult.
Cause:
VT Scada does not come with a JSON model for writing down to a Crimson based device using our Generic MQTT driver
Solution:
Customers must get with their support at VT Scada and get help with and or write the JSON package handling in VT Scada. After doing this the problem will be resolved.
Solution:
(Given Courtesy of Brandon Hanson)
{===========================MyJSONEncoder1=================}
{ Computes a Payload in a JSON format to Publish via MQTT for Redlion }
{=======================================================
(
Data { A value to be written out. };
MemAddr { "Indexing trail" from the Write address of the IO };
)
[
X;
JsonDict;
]
Only [
If Watch(1);
[
JsonDict = Dictionary();
JsonDict["connected"] = "true";
JsonDict[MemAddr] = Data;
JsonDict["timestamp"] = CurrentTime(1); { Now }
X = JSonEncode(JsonDict);
Return(X);
]
]
Disclaimer
It is the customer's responsibility to review the advice provided herein and its applicability to the system. Red Lion makes no representation about specific knowledge of the customer's system or the specific performance of the system. Red Lion is not responsible for any damage to equipment or connected systems. The use of this document is at your own risk. Red Lion standard product warranty applies.
Red Lion Technical Support
If you have any questions or trouble contact Red Lion Technical Support by clicking here or calling 1-877-432-9908.
For more information: http://www.redlion.net/support/policies-statements/warranty-statement