Topics covered in this article
- Prerequisites
- Setting the OPC-UA option
- Configuring the OPC-UA option
- MachineMetrics sample script file
Prerequisites
- SINUMERIK Operate is a requirement for OPC UA server.
- The OPC UA license (6FC5800-0AP67-0YBO) is also a requirement and may need to be installed by a service technician.
- The HMI time needs to be checked and set.
Compatibility of OPC UA server version and CNC software versions
CNC software version | OPC UA version |
4.5 | V2.2 and V3.0 SP1 |
4.07 - SP2...SP5 | V2.2 and V3.0 SP1 |
4.08 - SP2...SP3 | V2.2 and V3.0 SP1 |
4.92 and 4.92 - HF2 | V3.0 SP1 |
Setting the OPC-UA option
- Go to Startup
- Press Licenses softkey
- Go to Access MyMachine / OPC UA and check the box under Set as shown below
Photo credit: Siemen's Configuration Manual, 08/2019, 6FC5397-1DP41-0BA3
Configuring the OPC-UA option
- Go to Startup
- Press Network softkey
- Press OPC UA softkey
- Press Setting softkey
- Press Change softkey
- Make required changes to Connection, Authentication, Activation.
-
- Note: Port setting of 4840
-
Photo credit: Siemen's Configuration Manual, 08/2019, 6FC5397-1DP41-0BA3
- Choose OK and you will see a safety note appear regarding an open port in the firewall.
Photo credit: Siemen's Configuration Manual, 08/2019, 6FC5397-1DP41-0BA3
MachineMetrics sample script file
- Snippet of our adapter script file for OPC-UA and the associated namespace tags.
version: 2
endpoint: #Enter OPC-UA Endpoint Here
username: #Enter Username Here
password: #Enter Password Here
tags:
tool-group:
path: ns=2;s=/Channel/State/actToolIdent
tool-num:
path: ns=2;s=/Channel/State/actTNumber
line-number:
path: ns=2;s=/Channel/ProgramInfo/actLineNumber
load:
path: ns=2;s=/Nck/Spindle/driveLoad
prog-status:
path: ns=2;s=/Channel/State/progStatus
controller-op-mode:
path: ns=2;s=/Bag/State/opMode
op-mode:
path: ns=2;s=/Nck/Spindle/opMode
position:
path: ns=2;s=/Nck/Spindle/psModePos
speed:
path: ns=2;s=/Nck/LogicalSpindle/actSpeed
last-alarm-number:
path: ns=2;s=/Nck/LastAlarm/alarmNo
feed-rate:
path: ns=2;s=/Channel/MachineAxis/actFeedRate
prog-name:
path: ns=2;s=/Channel/ProgramInfo/progName
act-parts:
path: ns=2;s=/Channel/State/actParts
spindle-turn-state:
path: ns=2;s=/Nck/Spindle/turnState
total-parts:
path: ns=2;s=/Random@NCU_1/Plc/DB165.DBD50
data-items:
spindle-speed:
value: speed
spindle-load:
value: load
spindle-op-mode:
value: op-mode
spindle-position:
value: position
axis-feed-rate:
value: feed-rate
last-alarm-code:
value: last-alarm-number
line:
value: line-number
tool-group:
value: tool-group
tool-number:
value: tool-num
program-name:
value: prog-name
partcount:
value: act-parts
execution:
value:
INTERRUPTED: prog-status == 1
STOPPED: prog-status == 2 or prog-status == 5
ACTIVE: prog-status == 3 or prog-status == 4
READY: true
controller-mode:
value:
MANUAL: controller-op-mode == 0
MANUAL_DATA_INPUT: controller-op-mode == 1
AUTOMATIC: controller-op-mode == 2
spindle-rotating:
value:
ON: spindle-turn-state == 0 or spindle-turn-state == 1
OFF: spindle-turn-state == 2
total_parts:
value: total-parts
Have Questions?
Reach out to our team at Support@machinmetrics.com.
Comments
0 comments
Please sign in to leave a comment.