Establish connection to the PLC
This chapter shows how to import the created datapoint file and establish a connection to the PLCSim Advanced instance.
Create a twin PLCConnector and import datapoint file
In order to establish a connection to an external system (e.g. PLC), the simulation component PLCConnector
is used.
The ScriptComponent
from the previous tutorial, which was used to control the gantry robot, can get deleted. To be able to connect to the PLC,
PLCSIM Advanced
needs to get defined within the Protocol
property.
Then, set the name of the PLCSim Advanced instance and import the datapoint file.
When the simulation starts and the PLCConnector
established a connection to the PLC successfully, the simulation component starts exchanging the IO signals.
To check if the connection works and the definitions are correct, inputs can get set manually in the PLCConnector
simulation component.
Next
In the next chapter we connect the sensors with the inputs and the outputs to the actors in order to execute the PLC program.