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
Nikola Balog
osie
Commits
14afa67e
Commit
14afa67e
authored
May 17, 2024
by
Philipp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update minimal-server.py
parent
ba69c99d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
5 deletions
+17
-5
opcua-server-fhi /minimal-server.py
opcua-server-fhi /minimal-server.py
+17
-5
No files found.
opcua-server-fhi /minimal-server.py
View file @
14afa67e
#!//usr/bin/python
"""
Basic server with minimal data
"""
# from https://opcua-asyncio.readthedocs.io/en/latest/usage/get-started/minimal-client.html
import
asyncio
import
logging
from
asyncua
import
Server
,
ua
from
asyncua.common.methods
import
uamethod
import
argparse
# command line handling
parser
=
argparse
.
ArgumentParser
(
description
=
'Run OPCUA Server.'
)
a
=
parser
.
add_argument
a
(
'--ipv6'
,
help
=
'The IPv6 address on which the OPCUA Server runs'
,
default
=
"::"
)
a
(
'--ipv6-enabled'
,
help
=
'The IPv6 address check whether it is enabled or disabled'
,
default
=
"1"
)
a
(
'--port'
,
help
=
'The port on which the OPCUA Server runs'
,
default
=
"4840"
)
args
=
parser
.
parse_args
()
# ipv4 = args.ipv4
ipv6
=
args
.
ipv6
ipv6_enabled
=
args
.
ipv6_enabled
port
=
args
.
port
@
uamethod
...
...
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