Commit 25c3975c authored by Ivan Tyagov's avatar Ivan Tyagov

Add a heart beat variable which is published. Remove PubSub over Ethernet/UADP...

Add a heart beat variable which is published. Remove PubSub over Ethernet/UADP as simply not plans to use directly Ethernet directly.
parent abad3a39
...@@ -232,23 +232,11 @@ int main(int argc, char **argv) ...@@ -232,23 +232,11 @@ int main(int argc, char **argv)
UA_Double defaultDouble = 0; UA_Double defaultDouble = 0;
const PublishedVariable publishedVariableArray[] = { const PublishedVariable publishedVariableArray[] = {
{ {
.name = "lattitude", .name = "heart_beat",
.description = "Lattitude", .description = "Heart beat",
.pdefaultValue = &defaultDouble, .pdefaultValue = &defaultDouble,
.type = UA_TYPES[UA_TYPES_DOUBLE], .type = UA_TYPES[UA_TYPES_DOUBLE],
}, },
{
.name = "longitude",
.description = "Longitude",
.pdefaultValue = &defaultDouble,
.type = UA_TYPES[UA_TYPES_DOUBLE],
},
{
.name = "altitude",
.description = "Altitude",
.pdefaultValue = &defaultFloat,
.type = UA_TYPES[UA_TYPES_FLOAT],
},
}; };
UA_String transportProfile = UA_String transportProfile =
...@@ -257,9 +245,6 @@ int main(int argc, char **argv) ...@@ -257,9 +245,6 @@ int main(int argc, char **argv)
{UA_STRING_NULL , UA_STRING("opc.udp://224.0.0.22:4840/")}; {UA_STRING_NULL , UA_STRING("opc.udp://224.0.0.22:4840/")};
UA_ServerConfig_addPubSubTransportLayer(config, UA_PubSubTransportLayerUDPMP()); UA_ServerConfig_addPubSubTransportLayer(config, UA_PubSubTransportLayerUDPMP());
#ifdef UA_ENABLE_PUBSUB_ETH_UADP
UA_ServerConfig_addPubSubTransportLayer(config, UA_PubSubTransportLayerEthernet());
#endif
addPubSubConnection(server, &transportProfile, &networkAddressUrl); addPubSubConnection(server, &transportProfile, &networkAddressUrl);
addPublishedDataSet(server); addPublishedDataSet(server);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment