Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
osie
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Martin Manchev
osie
Commits
211bcc7a
Commit
211bcc7a
authored
Apr 21, 2022
by
Ivan Tyagov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use constants.
parent
223dc70f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
coupler/opc-ua-server/keep_alive.h
coupler/opc-ua-server/keep_alive.h
+8
-2
No files found.
coupler/opc-ua-server/keep_alive.h
View file @
211bcc7a
...
...
@@ -4,6 +4,12 @@ Keep alive implementation for couplers based on OPC UA's pub/sub mechanism
// both publisher and subscriber should use same publisher id
const
int
PUBLISHER_ID
=
2234
;
// the interval for publishing messages
const
int
PUBLISHING_INTERVAL
=
100
;
// a hard coded writer group (should be same for publisher / subscriber)
const
int
WRITER_GROUP_ID
=
100
;
UA_NodeId
connectionIdent
,
publishedDataSetIdent
,
writerGroupIdent
;
static
void
addPubSubConnection
(
UA_Server
*
server
,
UA_String
*
transportProfile
,
...
...
@@ -52,9 +58,9 @@ static void addWriterGroup(UA_Server *server) {
UA_WriterGroupConfig
writerGroupConfig
;
memset
(
&
writerGroupConfig
,
0
,
sizeof
(
UA_WriterGroupConfig
));
writerGroupConfig
.
name
=
UA_STRING
(
"Demo WriterGroup"
);
writerGroupConfig
.
publishingInterval
=
100
;
writerGroupConfig
.
publishingInterval
=
PUBLISHING_INTERVAL
;
writerGroupConfig
.
enabled
=
UA_FALSE
;
writerGroupConfig
.
writerGroupId
=
100
;
writerGroupConfig
.
writerGroupId
=
WRITER_GROUP_ID
;
writerGroupConfig
.
encodingMimeType
=
UA_PUBSUB_ENCODING_UADP
;
writerGroupConfig
.
messageSettings
.
encoding
=
UA_EXTENSIONOBJECT_DECODED
;
writerGroupConfig
.
messageSettings
.
content
.
decoded
.
type
=
&
UA_TYPES
[
UA_TYPES_UADPWRITERGROUPMESSAGEDATATYPE
];
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment