New Automation Technology
Beckhoff Training
Beckhoff
Structures
Structures are used to define elements of a larger item and are commonly referred to as custom data types or data unit types A temperature sensor; for example, is more than just the temperature temperature value The status of the Analog input card, the scaling parameters, and the offset are all possible elements that are directly related to the temperature sensor In order to keep these elements together and make the code c ode more re-useable a structure of these elements can be created
Beckhoff
Structures
To add a Structure, ‘Right‘Right-Click’ on the ‘DUTs’ folder
Then Select ‘Add’ -> ‘DUT’
Beckhoff
Structures
Change the Name to ST_TemperatureSensor
Select the Radio button for Structure
Click the ‘Open’ button
Beckhoff
Structures - Decleration
This will create the basic framework for a structure
Beckhoff
Structures - Decleration
Define the elements with the structure
Initial values can be given
A structure can also contain other structures
Beckhoff
Structures - Use
A structure must be instantiated just like a Function Block
Beckhoff
Structures - Use
After typing the instance name of the structure place a ‘.’ immediately after it and the intellisense window will appear, showing what elements exist inside of the structure
Beckhoff
Structures - Use
The elements in a structure can be written to t o or read from
New Automation Technology
Beckhoff Training
Beckhoff
Enumerations
Enumerations can be used to assign a variable name to a number.
Enumerations can be used in two different ways; with or without being instantiated.
If the Enumeration is not instantiated then the Enumeration E numeration works similar to a list of constants. If the Enumeration is instantiated then the instance of the enumeration will hold the variable of the current value of the Enumeration
Beckhoff
Enumerations
To add an Enumeration, ‘Right‘Right-Click’ on the ‘DUTs’ folder
Then Select ‘Add’ -> ‘DUT’
Beckhoff
Enumerations
Change the Name to E_Mode
Select the Radio button for Enumeration
Click the ‘Open’ button
Beckhoff
Enumerations
The basic framework of an Enumeration looks like the following
Beckhoff
Enumerations
When the Enumeration is defined the first variable in the list lis t will be assigned a value of 0, the variables following will be assigned their values in ascending order
Manual = 0
Semi_Auto = 1
Auto = 2
Beckhoff
Enumerations
If a variable in the list is explicitly assigned a value v alue then the following variables will be incremented from this value
Manual = 1
Semi_Auto = 2
Auto = 3
Manual = 1
Semi_Auto = 2
Auto = 3
Maintenance = 10
Unknown = 11
Beckhoff
Enumerations
Using Enumerations in this manner allows for easier understanding of the code when it is being read In this Case statement the Variables in the Enumeration are used to represent the number equivalent of iStep. As iStep changes in value the Case statement will change states iStep can be assigned a numerical value or an Enumeration variable The displayed online value of iStep1 will always be an INT value because iStep1 is declared as an INT
Beckhoff
Enumerations
The displayed online value of iStep will always be an INT value because iStep is declared as an INT
Beckhoff
Enumerations
If an instance of the Enumeration is declared then the instance of the Enumeration holds the variable name of the value of the Enumeration
Beckhoff
Enumerations
If eStep is of type E_Mode then eStep holds either ‘Manual’, ‘Semi_Auto ‘Semi_Auto’, ’, or ‘Auto’
New Automation Technology
Beckhoff Training
Beckhoff
Arrays
An Array is a list of data, the data data in the Array Array can be of any type type
An Array can contain more than one dimension dimension
Think of a Notebook of graph paper
The column on a single sheet of paper would be a 1 dimensional array
The entire sheet with its rows and columns would be a 2 dimensional array
The Notebook with all of its sheets would be a 3 dimensional array
Beckhoff
Arrays
1 Dimensional Array
The Array is defined from 1 to 10 of type INT
This Array will hold 10 integer values
The position in the Array is referred to as the index
The Array name along with an index can be used just like any other variable
Beckhoff
Arrays
2 Dimensional Array
The Array is defined from 1 to 10 and 1 to 3 of type String S tring
This Array will hold 30 (3*10) String values
The comma ‘,’ is used to denote the multiple dimensions of the array
Beckhoff
Arrays
3 Dimensional Array
Beckhoff
Arrays - Initialization
Initializing each index of an array
Initializing multiple indexes with the same value
The above 2 examples can be mixed together
Beckhoff
Arrays
Indexing through an Array with a FOR loop A FOR loop can be used to easily fill an Array or read the values in an array The following will set all values in the Array to 0
New Automation Technology
Beckhoff Training
Beckhoff
Breakpoints
WARNING! A Breakpoint will stop the PLC
Note: Logging out of the PLC will remove all breakpoints, and allow the code to start running again.
Beckhoff
Breakpoints
Breakpoints can be used to aid in debugging the PLC code When the line is selected where the Breakpoint is to happen the PLC code will run until that line of code is reached When the breakpoint is reached the PLC will stop s top running and the status of variables can be seen in their current state This will allow the checking of the code to determine if the code c ode is executing properly
Beckhoff
Breakpoints
To set a breakpoint click on the line, placing the cursor where you wish the PLC to stop
From the PLC menu select Toggle Breakpoint
Note: Breakpoints can only be set on lines that have the gray circle.
Beckhoff
Breakpoints
The Breakpoint has now been set on Line 4
When the PLC reaches this line of code c ode the PLC will halt before running Line 4
You can also see that the Run R un command for the PLC is enabled.
Beckhoff
Breakpoints
The PLC menu provides the programmer with a list of options
The Run (F5) command will start the PLC again and it will run until it hits a breakpoint
The Toggle Breakpoint(F9) command will remove or add a Breakpoint at the t he
line where the cursor is currently located
Step over (F10) will execute the line of code and go to the next line of code If a call to another POU is on the line of code being executed, the POU will run in its entirety
Beckhoff
Breakpoints
Step Into (F11) will perform the same action as Step over with the added functionality of opening the called POU and stepping through its code line by line Note: The Step in command will not open a POU inside of a library
Step Out (Shift + F11) will leave the current
POU and return to the calling POU
TwinCAT 3
Multiple PLC Tasks
TWINCAT 3
Multiple PLC Tasks
Right-Click on POUs, select ‘Add’, then select ‘POU…’
Multiple PLC Tasks
Give the POU a name
Set the ‘Type’ to ‘Program’
Click ‘Open’
Multiple PLC Tasks
The new Program has been added to the ‘POU’ list
Multiple PLC Tasks
Under ‘PLC’, Right-Click ‘Untitled1 ‘Untitle d1 Project’ Project ’, select s elect ‘Add’, Add’, select ‘Referenced Task…’
Multiple PLC Tasks
In the ‘New Task’ section, provide a unique name for the ‘Task’
Click ‘Create New Task’
Multiple PLC Tasks
Select the task under the ‘Available Tasks:’ column
Click ‘Open’
Multiple PLC Tasks
The new task has been added
Multiple PLC Tasks
Right-Click on the name of the new task
Select Selec t ‘Add’ ‘Add’,, ‘Existing Item…’
Multiple PLC Tasks
Select the desired POU name from the ‘Items’
section
Click ‘OK’
Multiple PLC Tasks
The ‘POU’ is now called by the ‘T ‘ Task’
Double-Click on the Task to view its properties
Multiple PLC Tasks
The first first Task Task is i s at Port 350 with a Priority of 20
The second Task is at Port 351 with a Priority of 21
Multiple PLC Tasks
Adjust the ‘Cycle Ticks’ to change
how often the task starts its execution.
The lower the priority (closer to 0), the lower the ticks.
TC3 TwinSAFE
TwinCAT 3 Software
TC3 TwinSAFE
Safety and standard I/O in one system
TC3 TwinSAFE
Safety and standard I/O in one system
1. High Performance Control 2. Scalable Hardware 3. One Software TwinCAT 4. Outstanding Diagnostics
TC3 TwinSAFE
High Performance Control High Performance expands possibilities
1 controller 50us PLC scan rate 30us I/O update rate Synchronous Scan 10ns resolution w/ XFC Terminals 100 data point w/ Oversampling Terminals 250us Motion task
11,000 Terminal Terminal Demo 4ms update rate
TC3 TwinSAFE
Safety and standard I/O in one system
1. High Performance Control 2. Scalable Hardware 3. One Software TwinCAT 4. Outstanding Diagnostics
TC3 TwinSAFE
Scalable Hardware Scalable I/O including TwinSAFE works with any size system
1 Controller 1 EtherCAT NIC (built in) 0 switches 0 IP addresses 0 I/O configuration Auto Scan Software sends config info
Redundancy(Ring Redundancy(Ring)) 65,535 Devices 255 Axes
11,000 Terminal Terminal Demo
TC3 TwinSAFE
Scalable Hardware Scalable I/O works with any field bus protocol
25+ protocols TwinSAFE Variables can be tied to these other systems
TC3 TwinSAFE
Scalable Hardware Scalable I/O does not require racks or backplane chassis
400+ Terminal Types IP20, 65, 67, IP69K 100 Oversampling Power Monitoring LoadCell AC/DC Motor Stepper Servo
TC3 TwinSAFE
Scalable Hardware Scalable Controllers work with all of the I/O Devices
266Mhz Atom CPU 2.1Ghz i7 Quad Core Multi HD Raid SSD Cfast Flash Fan/Fanless Integrated PB‘s/LT‘s All TwinSAFE ready
TC3 TwinSAFE
Scalable Hardware Scalable Motion
255 Axis 2 axis per drive Single Cable Power/Feeback Linear Synchronous Stepper All TwinSAFE ready
TC3 TwinSAFE
Scalable Hardware Scalable Safety: TwinSAFE System •IPC •TwinCAT TwinCAT Development Develop ment Software •TwinSAFE CPU Logic Controller Terminal •TwinSAFE Input Terminal •TwinSAFE Output Terminal
TC3 TwinSAFE
Scalable Hardware Scalable Safety: TwinSAFE System •Certified to SIL 3 according to IEC 61508, EN 954 Cat. 4 and and DIN EN ISO 13849 PLe • Approvals: Approvals: UL, CE, ATEX •Enables networks with up to 1,024 TwinSAFE devices •Safe Motion •The required functions are configured via TwinCAT Development software • All All TwinSAFE TwinSAFE data can be be sent to other Network Protocols ie:Ethernet/IP •Complete Hardware/Software diagnostics
TC3 TwinSAFE
Scalable Hardware Scalable Safety : TwinSAFE EL6900 CPU Logic Controller •Supports up to 128 TwinSAFE terminals. •14 different Safety software functions available. Can easily be selected and linked. •Multiple TwinSAFE TwinSAFE Controllers can co-exist within a network •255 Function blocks total •32 Independant TwinSAFE TwinSAFE Groups •Dip switch on Terminal required for certification 0-1023. Diagnostic Lights: Voltage Temperature Communication Function Block
TC3 TwinSAFE
Scalable Hardware Scalable Safety: TwinSAFE Various Input Devices Operation Mode: • Standstill monitoring 1 • Standstill monitoring 2 • Digital
Logic of Channels: • Single logic • OSSD signals (two channel) • asynchronous pulses, • inactive sensortest • OSSD signals (two channel) • any pulse repetition, • inactive sensortest • Cross-circuit detection • cause no module fault
Standstill Monitoring
Light Curtains
Laser Scanners
Safety Mats
TC3 TwinSAFE
Scalable Hardware Scalable Safety : TwinSAFE Input Terminals •Fail-safe inputs •Supports sensor test, short clock signal every 250hz. •Diagnostic Lights: Voltage Temperature Sensor Test Cross Wiring
Dip switches on Terminal required for certification 0-65535
EL1904 4ch
Dip switches on Terminal required for certification 0-4095
EP1908 8ch (IP65)
EL1908 8ch
TC3 TwinSAFE
Scalable Hardware Scalable Safety: TwinSAFE Various Outputs
Standard outputs active: •PLC output control is logically AND connected with with the safety outputs. SafeState is always ensured, has priority. priority.
Standard and Safe output
Current measurement active: •Setting allows use of a common ground for the safety outputs. Enable/Disable min/max checks of current measurement.
Common Ground wiring
Testing of outputs active: •Test pulses of the safety outputs output s can be deactivated.
Solid State Devices
TC3 TwinSAFE
Scalable Hardware Scalable Safety : TwinSAFE Output Terminal Terminals s • Fail-safe Outputs • Switches 24 V DC actuators. • Switches off automatically (fail stop) if a fault is detected • Diagnostic Lights: Voltage Temperature Output Current Cross Wiring
Dip switches on Terminal required for certification 0-1023.
EL1904 4ch 0.5Amp
EL1902 2ch 2.3Amp
EL1901 1ch 10Amp
EL2964 1ch 3 simultaneously N.O. contacts
TC3 TwinSAFE
Scalable Hardware Scalable Safety : TwinSAFE AX5805 Safety Card Meets requirements for: PL e / SIL 3
Stop Functions: STO: Safe Torque Off SS1: Safe Stop 1 → STO SS2: Safe Stop 2 → SOS Limiting Functions: SOS: Safe Operating Stop SSM: Safe Speed Monitor SLS: Safe Limited Speed SLP: Safe Limited Position SAR: Safe Acceleration Range SSR: Safe Speed Range SMA: Safe Maximum Acceleration SMS: Safe Maximum Speed SDI: Safe Direction
Main voltage remains connected
No additional wiring or switching device required!
TC3 TwinSAFE
Scalable Hardware Scalable Safety: Fieldbus Gateway •IPC acts as built in gateway to other controllers on network. •Integrate TwinSAFE data to EthernetIP via shared memory map. •1 CIP connection for many nodes of I/O. •IPC can also be programmed with PLC logic and motion logic.
IPC is generic E/IP slave 498 bytes Input data 498 bytes Output data
TC3 TwinSAFE
Scalable Hardware Scalable Safety: Fieldbus Gateway •Uplink/Downlink Uplink/Downlink values for Generic CIP connection to AB is auto calculated . These are the values which would be typed into the RSLogix5000 side. •Input / Output Memory map connection occurs as Scheduled Class1 Connection.
TC3 TwinSAFE
Scalable Hardware Scalable Safety: Field bus Gateway •Input /Output Shared Memory Map Data looks just like any other I/O I/O Device •Add 2nd NIC or multiplex to expand data xfer.
TC3 TwinSAFE
Safety and standard I/O in one system
1. High Performance Control 2. Scalable Hardware 3. One Software TwinCAT 4. Outstanding Diagnostics
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Development Overview 1.
All Software Elements in One Location (Safety)
2.
All Co Code Wr Writin ting in One Location
3.
All Parameter ters in One Location
4.
All Code feedback in one location
2.
2. 3.
1.
4.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Add Target TwinSAFE Controll Controller er Terminal •
Add Target Target TwinSAFE Controller Terminal
2.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Attach to Target PLC Terminal Controlle Controllerr •
User Administration can be performed
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks •
EL6900 has 14 total pre-defined FB available
•
Safety functions can easily be selected and linked.
•
All FB can be freely connected and are complemented with operators such as AND, OR, etc.
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks •
8 EstopPB or 4 DualContact EstopPB can be connected to each Estop FB
•
Each Estop can be set for single or dual contacts
•
External Device Monitoring Inputs for ensuring Contactor is switching states
•
Use AND blocks for more Estops.
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks •
Add variables to each input and output of the FB 2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks •
Configurable Delay Time
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks
2.
External Device Monitoring
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks •
Raw Material additions
•
Automatic Roll Changes
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks
2.
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Function Blocks
2.
TC3 TwinSAFE
One Software TwinCAT TwinSAFE: Add Function Blocks to Group1 Network •
Point at the SafeEstop function block
•
Hold down the left-click button
•
Drag the safeEstop block onto the code writing area.
2.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Create Cr eate TwinSAFE Function Func tion Block Variables 1.
Click on the Restart input connection point
2.
In th the pro prop perti rties windows you can alter the properties or parameters of the “In Port”
•
• •
3.
2.
1. 2.
Single or Two Channel operation Discrepancy time Select input as N.C or N.O Assi ssign Variab riable le Name
3.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Connectio Connection n between FB’s FB’s •
Click and hold connection and drag connection to another FB connection point.
2.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Create Cr eate TwinSAFE Function Func tion Block Variables •
Click on Comment and add a comment to a FB
2.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: Create Cr eate TwinSAFE Function Func tion Block Variables 1.
Selecting magnifying glass icon will zoom in on workspace
2. 2.
Selecting magnifying glass icon will auto scale workspace to fit all FB’s
3.
Selecting magnifying glass icon will zoom out on workspace
4.
Selecting and moving the move icon will show a zoomed in popup window of workspace
5.
CTRL and Mouse Wheel zooms in/out
TC3 TwinSAFE
One Software TwinCAT Create TwinSAFE Function Block Variables •
Example of several FB on one network. 2.
TC3 TwinSAFE
One Software TwinCAT TwinCA winCAT T: TwinSAFE Download Safety Project, Start Safety Project Projec t •
Click Download Icon 2.
Username: Administrator Serial Number: nnnnnnnn
Password: TwinSAFE
TC3 TwinSAFE
One Software TwinCAT TwinCAT: TwinSAFE Version History •
Click Version Icon 2.
TC3 TwinSAFE
Safety and standard I/O in one system
1. High Performance Control 2. Scalable Hardware 3. One Software TwinCAT 4. Outstanding Diagnostics
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Online Monitoring •
Green indicates Input is High/True 2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Online Monitoring •
Online status is shown as Green when ON. 2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Online Monitoring •
•
Each channel of the connection can be mapped back to variable tag for use in the PLC. Live online update of a TwinSAFE or any input/output is available
2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Variable Tags •
TwinSAFE Group and FB Variable Tags available to be aliased to PLC project.
2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Variable Tags •
Estop FB Variable Tags available to be aliased to PLC project.
2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Document •
•
Right-click on the “Project” level of the safety tree view in the Solution Explorer
Add Extra company specific data as needed, notice logo file jpg file attached in example.
2.
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Document • Detailed information about devices and parameters
TC3 TwinSAFE
Outstanding Diagnostics Diagnostics: Demo
TC3 TwinSAFE Document Demo TC3 Diagnostics Runtime Demo
TC3 TwinSAFE
I/O Configuration I/O Configuration: Demo
TC3 TwinSAFE I/O Auto Configuration Configura tion Demo
TC3 TwinSAFE
Questions
Questions?
TwinCAT 3
TwinSAFE – Getting Started
TWINCAT 3
Getting Started
A TwinSAFE Project will consist of one or more TwinSAFE TwinSAFE Groups.
Each group will have its own set of Safety Application Application Variables and Function Blocks TwinSAFE Project TwinSAFE Group
FB
Safety Application Variables
Getting Started
Each TwinSAFE TwinSAFE Project is associated as sociated with an EL6900
EL6900
TwinSAFE Project TwinSAFE Group
FB
Safety Application Variables
Getting Started
Each Variable Variable going into or out of the Group must pass through an Alias
TwinSAFE Project Alias
TwinSAFE Group
FB
Safety Application Variables
Alias
Getting Started
The Alias is then connected to a PLC variable or to the I/O
Note: The I/O may be Safety I/O or Standard I/O depending on the application a pplication
TwinSAFE Project Alias
TwinSAFE Group
FB
Safety Application Variables
Alias
PLC I/O
TwinSAFE – Estop and Relay
TWINCAT 3
Estop and Relay
Scan in the Hardware
Add a PLC Project and create the following Global Variables Variables
Estop and Relay
In the body of MAIN add the following line of code
Estop and Relay
se lect ‘Rebuild’ Right-Click on the Project and select
Estop and Relay
Link the PLC Input variable to the first push button
Estop and Relay
Right-Click on ‘Safety’ and select ‘Add New Item’
Estop and Relay
Select ‘ TwinCAT Default Safety Safety Project’ Project ’
Name the project
Click ‘Add’
Estop and Relay
The Author and Internal Project Name can be supplied
Click ‘OK’
Estop and Relay
Right-Click on the ‘Project’ and select ‘Properties’
Estop and Relay
Estop and Relay
Click on the ‘Map’ button
Estop and Relay
Select the EL6900 that this TwinSAFE Project will be associated with
Click ‘OK’
Estop and Relay
The information of the EL6900 that was selected s elected is displayed
Estop and Relay
Verify the Dip-Switch address, then click the green Up arrow. This will copy the Dip-Switch value into the FSoEAddress
Estop and Relay
Before Before moving on, these values need to be saved
Notice the TAB TAB at the top has an * next to it, this means the data has not been saved. s aved.
Estop and Relay
Tab and select s elect ‘Save Selected Right-Click on the Project Tab Items’
Estop and Relay
Expand each Item in the tree under SAFETY
Double-Click on the ErrorAcknowledgement.sds
Estop and Relay
Click the ‘Map’ button
Estop and Relay
Select the PLC variable for Error Acknowledge and click ‘OK’
Estop and Relay
Right click on ‘Alias ‘Alias Devices’ and select ‘Import Alias -
Devices from I/O-configuration’
Estop and Relay
Select All Safety I/O to be associated as sociated with this TwinSAFE Group
Click ‘OK’
Estop and Relay
The Aliases for the Safety I/O have have now been added and are already mapped to the I/O
Estop and Relay
From the ‘View’ menu select ‘Properties Window’
Estop and Relay
Under the ‘Safety’ Item, Double-Click on ‘TwinSafeGroup1.sal’
Estop and Relay
Left-Click in the empty area of ‘Network1’
Estop and Relay
In the ‘Properties’ windows select the down arrow
Estop and Relay
Select ‘T ‘ TwinSAFE Safety Application’ from the drop down
list
Estop and Relay
The properties window now displays the ‘Safety Application Application Variables’ that can be connected to an Alias
Estop and Relay
Click on the Ellipse button to map the Alias
Estop and Relay
Select ‘Channel 1’ of the ‘ ErrorAcknowledgement’ Alias
Click ‘OK’
Estop and Relay
It is now possible to expand the ErrAck and se what it is connected to
Estop and Relay
From the ‘View’ menu, select ‘Toolbox’
Estop and Relay
The Safety Toolbox contains items that can be added to the TwinSafeGroup1.sal winSafeGroup1.sal file f ile
Estop and Relay
Under the ‘Function Blocks’ group, select ‘safeEstop’
Click and drag the item to place it on the network
Estop and Relay
Left-click on the ‘Restart’ input
Estop and Relay
The ‘Properties’ window should now display the properties of the ‘Restart In Port’
Estop and Relay
In the ‘Assigned Variable Name’ create a unique name for
the Input and pres ‘Enter’
SafetyRestartPB
Estop and Relay
The name should now be displayed next to the input of the Function Block
Estop and Relay
Repeat these steps to Assign Variable Names to the first 2 Inputs and the Estop Output
Estop and Relay
From the ‘View’ menu, select ‘Other Windows’ and then ‘Variable ‘Variable Mapping’
This window is typically opened automatically and
can be found next to the ‘Error’ or ‘Output’
windows
Estop and Relay
The ‘Variable Mapping’ window contains the variables that
were created in the Safety Networks
From here these variables can be connected to an Alias
Estop and Relay
Select the Ellipse button of the Restart
Estop and Relay
Select the Alias that is connect to the Safety Hardware Hardware Input
Estop and Relay
The ‘Port Name’ is provided by the ‘Function Block’ Blo ck’
The ‘Assigned Variable’ is created by the programmer
The ‘Alias ‘Alias Port’ Port ’ is the connection to an Alias Al ias that will then
connect to something outside of the TwinSAFE TwinSAFE Group
Estop and Relay
Select the Ellipse button for EStopInput1
Select the Alias for Channel 1 of the EL1904
Estop and Relay
Select the Ellipse button for EStopInput2
Select the Alias for Channel 3 of the EL1904
Estop and Relay
Select the Ellipse button for EStopOutput
Select the Alias for Channel 1 of the EL2904
Estop and Relay
Estop and Relay
At this point the project has been created, the last step is to verify it and load it into the EL6900
Estop and Relay
At this point the project has been created, the last step is to verify it and load it into the EL6900
Before Before continuing select ‘Save All’ from the ‘File’ menu
Estop and Relay
From the ‘View’ menu, select ‘ Toolbars’ oolba rs’,, and then select ‘ TwinCAT Safety Toolbar’
Estop and Relay
The Safety Toolbar is configured in the order of operation for the needed commands
The Toolbar will be grayed out if the active window is not part of the Safety Project. Project.
Estop and Relay
Verify Safety Project (Project Level)
Verify Complete Safety Project (Project and Hardware Level)
Download Safety Project
Estop and Relay
Click on Verify Safety Project (Project Level)
This will check che ck for any errors errors within the Safety Project Project
If any errors errors are found they will be shown in the ‘Error’ ‘Error ’
window
Estop and Relay
Click on Verify Complete Safety Project Project (Project and Hardware Level)
In addition to the Safety Project, this will also check the
Safety Hardware Configuration
Estop and Relay
Before Before downloading the Safety Project Project to the EL6900, verify that the Serial Number is correct
se lect ‘Properties’ Right-Click on the Project and select
Estop and Relay
Verify the Serial Se rial Number matches the serial se rial number printed on the hardware hardware
When working with Multiple EL6900s, this will help to ensure that the correct program is being loaded
Estop and Relay
Double-click the Serial Number to select it
Right-click on it, then select ‘Copy’
Estop and Relay
Click on ‘Download Safety Project’
Estop and Relay
Provide the Login Information for the EL6900
This information is CASE senstitive
Username:
Serial Number: Ctrl+V to paste
Password:
Administrator TwinSAFE
Estop and Relay
Click ‘OK’
If the information was correct you will be ask as ked for the password one more time
Enter the same password and click ‘OK’
Estop and Relay
Activate Activate the Configuration Configuration
Restart TwinCAT in Run Mode
Login and start the PLC
Estop and Relay
The TwinSAFE TwinSAFE Group will have a Com Error
Press the ErrAck Push Button to clear it
Depress and then twist the Estop push button to ensure that it is reset
Press the Restart push button to restart the Safety Function Block
The relay should now be pulled in
TwinCAT 3
Changing Fonts
TWINCAT 3
Changing Fonts
From the ‘T ‘ Tools’ menu select ‘Options’
Changing Fonts - ST
TwinCAT – TwinCAT – PLC PLC Environment – Environment – Text Text Editor
Changing Fonts - ST
Select the ‘Text area’ tab
Click on the ‘Font’ Box at the bottom
Changing Fonts – FBD, LD, IL
TwinCAT – TwinCAT – PLC PLC Environment – Environment – FBD, FBD, LD and IL Editor
Changing Fonts – FBD, LD, IL
Select the ‘General’ tab
Click on the ‘Font’ Box at the bottom
TwinCAT 3
Data Type Comparison
TWINCAT 3
Data Type Comparison System Manager
IEC611313
.Net Type
C# Keyword
Visual Basic Keyword
BIT
BOOL
System.Boolean
bool
Boolean
BIT8
BOOL
System.Boolean
bool
Boolean
BITARR8 BITARR8
BYTE
System.Byte
byte
Byte
BITARR16 BITARR16
WORD
System.UInt16
ushort
-
Data Type Comparison System Manager
IEC611313
.Net Type
C# Keyword
Visual Basic Keyword
INT8
SINT
System.SByte
sbyte
-
INT16
INT
System.Int16
short
Short
INT32
DINT
System.Int32
int
Integer
INT64
LINT
System.Int64
long
Long
Data Type Comparison System Manager
IEC611313
.Net Type
C# Keyword
Visual Basic Keyword
UINT8
USINT
System.Byte
byte
Byte
UINT16
UINT
System.UInt16
ushort
-
UINT32
UDINT
System.UInt32
uint
-
UINT64
ULINT
System.UInt64
ulong
-
Data Type Comparison System Manager
IEC611313
.Net Type
C# Keyword
Visual Basic Keyword
FLOAT FLOAT
Real
System.Single
float
Single
DOUBLE
LREAL
System.Double
double
Double
TwinCAT 3
Password Protection
TWINCAT 3
Password Protection
It is possible po ssible to protect parts of the TwinCAT TwinCAT Project and prevent prevent changes from being made.
Password Protection
Double-click on the ‘System’ ‘System’
Password Protection
Select the ‘Protection’ tab
Password Protection
Press ‘Enter Credentials’ C redentials’
Password Protection
Supply a ‘User Name’ and ‘Password’
Click ‘OK’
Note: The User Name and Password Password are both Case Sensitive
Password Protection
The Protection has been applied, but you are currently logged in as the User you created.
Password Protection
Select ‘File’, then ‘Save All’
Password Protection
Select ‘File’, then ‘Close Solution’
Password Protection
Select ‘File’, then ‘Open’, then ‘Project/Solution’
Password Protection
Select your solution file, then press ‘Open’
Password Protection
Notice the ‘Activate Configuration’ icon is grayed out
It is possible to put the system system in ‘ Config Mode’ and also ‘Restart TwinCAT’
Although settings can be changed, they can not be activated
Password Protection
Double-click on the ‘System’ ‘System’
Password Protection
Notice the red box, this indicates indicates that the ‘System’ is protected
It is still possible to edit the PLC
Use the
‘Enter Credentials’ button to login and
access the Config uration tion’ ‘Activate Configura button
TwinCAT 3
Source code download
TWINCAT 3
Source code download
By default default the source code will be placed in the boot folder on the target target device
This will allow for the source code to be read and modified
It is also possible to disable this feature
Source code download
Double-click Double-click the project name under ‘PLC’
Source code download
Select the ‘Settings’ tab
Source code download
By default the ‘Project Sources’ are created on the target device in the boot folder
Source code download
De-select De-select the ‘Project Sources
Source code download
Right-Click Right-Click on the project and select ‘Activate Boot Project’
Source code download
The boot folder now contains only the compiled libraries