我想使用 OPC UA 服务器将我的应用程序生成的数据发送到 OPC UA 客户端。我已经完成了 Eclipse Milo Project,这是一个很好的资源。但我不知道如何将它集成到我们的应用程序中。应用程序以 JSON 格式生成输出。使用 JSON 格式存储、处理和发送多个节点的数据,如下所示。
{"deviceId":"36860","timestamp":"2019-03-07 10:37:20+05:30","1":"228.6","2":"237.65","3":"237.21","4":"0.13","5":"0.0","6":"0.11","7":"-2.95","8":"0.0","9":"4.03","10":"22.2","11":"0.0","12":"16.43","13":"-21.83","14":"0.0","15":"-15.72","16":"-0.13","17":"1.0","18":"0.25","19":"262.35","20":"0.0","21":"284.18","22":"234.49","23":"703.47","24":"0.08","25":"0.24","26":"0.36","27":"1.08","28":"12.87","29":"38.62","30":"-12.52"}
其中 36860 是 nodeId/deviceId,timestamp 是从节点捕获数据的时间 rest 是参数 Id 和它们在键值对中的节点的实际读取值。如何使用 ExampleServer 发送此数据以及客户端如何接收它?如果可能的话,任何人都可以提供一个例子吗?