Home » Eclipse Projects » 4DIAC - Framework for Distributed Industrial Automation and Control » 4Diac-Arrowhead framework (Arrowhead Function Blocks)
|
Re: 4Diac-Arrowhead framework [message #1820743 is a reply to message #1820740] |
Tue, 28 January 2020 09:48 |
Jose Maria Jesus Cabral Lassalle Messages: 199 Registered: February 2016 |
Senior Member |
|
|
Hi,
When using Arrowhead, the best practice is not to query the service yourself, but ask the orchestrator for the service. But for testing, of course you could query yourself.
The main documentation is here: https://www.eclipse.org/4diac/en_help.php?helppage=html/communication/arrowhead.html
At the end of the page, you have a link to examples: https://git.eclipse.org/c/4diac/org.eclipse.4diac.examples.git
The easiest way I'd say is to use "QueryServiceHTTPSubFull" which has all the fields to be defined by you. You should take care of the types of the data input/ouput. CHeck the type and the description of the inputs and outputs. The output for example is an array of ServiceRegistryEntry. You could get the specific position of an array using the FB called GET_AT_INDEX and then like you did, use GetEndpointFromServiceRegistryEntry to get the endpoint (IP:PORT/URI). How you use this endpoint, depends on your application. If this is for example an HTTP endpoint, then you should check the HTTP layer for forte, and build the ID string for the CLIENT FB.
|
|
|
Re: 4Diac-Arrowhead framework [message #1820813 is a reply to message #1820743] |
Wed, 29 January 2020 13:50 |
Ahsan Zia Messages: 36 Registered: July 2018 |
Member |
|
|
Hi,
Thank you. Looks like I am going in the right direction.
What should be the entries of the fields?
Using (IP:PORT/serviceregistry/mgmt/id) as address. The id is 22. primarily, using POSTMAN to register the services.
Registering the end point URL address of OPC UA for Client and publish blocks.
I am using this procedure to first test the application and if it works twill implement the orchestrator for the service (as you mentioned).
BR,
Ahsan
......................................................................................................................................
{
"id": 22,
"serviceDefinition": {
"id": 23,
"serviceDefinition": "valve102",
"createdAt": "2020-01-27 13:15:40",
"updatedAt": "2020-01-27 13:15:40"
},
"provider": {
"id": 14,
"systemName": "NAME",
"address": "iec61499",
"port": 0,
"authenticationInfo": "string",
"createdAt": "2020-01-27 12:35:27",
"updatedAt": "2020-01-27 12:35:27"
},
"serviceUri": "opc_ua[opc.tcp://localhost:IP#/Objects/2:PLC1/2:eq_states/2:EQ_V102]",
"secure": "NOT_SECURE",
"metadata": {},
"version": 0,
"interfaces": [
{
"id": 3,
"interfaceName": "HTTPS-SECURE-JSON",
"createdAt": "2019-12-27 06:45:42",
"updatedAt": "2019-12-27 06:45:42"
}
],
"createdAt": "2020-01-27 13:15:40",
"updatedAt": "2020-01-27 13:15:40"
}
................................................................................................................................
|
|
| | | | |
Goto Forum:
Current Time: Wed Sep 25 18:47:47 GMT 2024
Powered by FUDForum. Page generated in 0.06265 seconds
|