Skip to content

Commit

Permalink
fix config
Browse files Browse the repository at this point in the history
  • Loading branch information
MattiaMarzano-Eng committed Sep 2, 2022
1 parent c6603a0 commit 0e04b21
Show file tree
Hide file tree
Showing 3 changed files with 142 additions and 12 deletions.
13 changes: 2 additions & 11 deletions AGECONF/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
"contextBroker": {
"host": "orion",
"port": 1026,
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"service": "opcua_car",
"subservice": "/demo"
},
Expand All @@ -29,9 +27,6 @@
"service": "opcua_car",
"subservice": "/demo",
"active": [{
"name": "EngineBrake",
"type": "Number"
}, {
"name": "Acceleration",
"type": "Number"
}, {
Expand Down Expand Up @@ -69,10 +64,8 @@
"deviceRegistrationDuration": "P1M",
"defaultType": null,
"contexts": [{
"id": "urn:ngsi-ld:Device:age01_Car",
"id": "age01_Car",
"type": "Device",
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"service": "opcua_car",
"subservice": "/demo",
"polling": false,
Expand Down Expand Up @@ -104,10 +97,8 @@
}]
}],
"contextSubscriptions": [{
"id": "urn:ngsi-ld:Device:age01_Car",
"id": "age01_Car",
"type": "Device",
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"mappings": [{
"ocb_id": "Error",
"opcua_id": "ns=3;s=Error",
Expand Down
139 changes: 139 additions & 0 deletions AGECONF/config.json.LD
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
{
"logLevel": "INFO",
"multiCore": false,
"relaxTemplateValidation": true,
"contextBroker": {
"host": "orion",
"port": 1026,
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"service": "opcua_car",
"subservice": "/demo"
},
"server": {
"port": 4001,
"baseRoot": "/"
},
"deviceRegistry": {
"type": "memory"
},
"mongodb": {
"host": "iot_mongo",
"port": "27017",
"db": "iotagent",
"retries": 5,
"retryTime": 5
},
"types": {
"Device": {
"service": "opcua_car",
"subservice": "/demo",
"active": [{
"name": "EngineBrake",
"type": "Number"
}, {
"name": "Acceleration",
"type": "Number"
}, {
"name": "EngineStopped",
"type": "Boolean"
}, {
"name": "Engine_Temperature",
"type": "Number"
}, {
"name": "Engine_Oxigen",
"type": "Number"
}],
"lazy": [{
"name": "Speed",
"type": "Number"
}],
"commands": [{
"name": "Error",
"type": "command"
}, {
"name": "Stop",
"type": "command"
}, {
"name": "Accelerate",
"type": "command"
}]
}
},
"browseServerOptions": null,
"service": "opcua_car",
"subservice": "/demo",
"providerUrl": "http://iotage:4001",
"pollingExpiration": "200000",
"pollingDaemonFrequency": "20000",
"deviceRegistrationDuration": "P1M",
"defaultType": null,
"contexts": [{
"id": "urn:ngsi-ld:Device:age01_Car",
"type": "Device",
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"service": "opcua_car",
"subservice": "/demo",
"polling": false,
"mappings": [{
"ocb_id": "Error",
"opcua_id": "ns=3;s=Error",
"object_id": null,
"inputArguments": []
}, {
"ocb_id": "Acceleration",
"opcua_id": "ns=3;s=Acceleration",
"object_id": null,
"inputArguments": []
}, {
"ocb_id": "EngineStopped",
"opcua_id": "ns=3;s=EngineStopped",
"object_id": null,
"inputArguments": []
}, {
"ocb_id": "Engine_Temperature",
"opcua_id": "ns=3;s=Temperature",
"object_id": null,
"inputArguments": []
}, {
"ocb_id": "Engine_Oxigen",
"opcua_id": "ns=3;s=Oxigen",
"object_id": null,
"inputArguments": []
}]
}],
"contextSubscriptions": [{
"id": "urn:ngsi-ld:Device:age01_Car",
"type": "Device",
"ngsiVersion": "ld",
"jsonLdContext": "https://uri.etsi.org/ngsi-ld/v1/ngsi-ld-core-context.jsonld",
"mappings": [{
"ocb_id": "Error",
"opcua_id": "ns=3;s=Error",
"object_id": "ns=3;i=1000",
"inputArguments": [{
"dataType": 12,
"type": "Error Type"
}]
}, {
"ocb_id": "Speed",
"opcua_id": "ns=3;s=Speed",
"object_id": "ns=3;i=1000",
"inputArguments": []
}, {
"ocb_id": "Stop",
"opcua_id": "ns=3;s=Stop",
"object_id": "ns=3;i=1000",
"inputArguments": []
}, {
"ocb_id": "Accelerate",
"opcua_id": "ns=3;s=Accelerate",
"object_id": "ns=3;i=1000",
"inputArguments": [{
"dataType": 6,
"type": "Intensity"
}]
}]
}]
}
2 changes: 1 addition & 1 deletion AGECONF/config.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
## SOUTHBOUND CONFIGURATION (OPC UA)
namespace-ignore=2,7
namespace-ignore=0,2,7
endpoint=opc.tcp://iotcarsrv:5001/UA/CarServer

## NORTHBOUND CONFIGURATION (ORION CONTEXT BROKER)
Expand Down

0 comments on commit 0e04b21

Please sign in to comment.