PlcSim
We need a running program on PlcSim. PlcSim has to use the PLCSIM(TCP/IP) interface and has to be listening on the same IP as the computer.
Here a DB with one bit that is toggled every second :
Your PLC side is ready !
NetToPlcSim Software
Install
To allow Galileo and PlcSim to communicate we need a third party software that will act as a gateway : NetToPlcSim (OpenSource).
Download from : http://sourceforge.net/projects/nettoplcsim/
Startup
At startup, it’ll ask to close the service using the port 102 :
If NetToPlcSim fail to close this service, you might do it manually (as administrator) :
Configuration
We need to “add” a new server:
The pamameters window :
We start by the “Network IP Address”, use the “…” and choose your computer IP :
Then do the same for the PlcSim IP (PlcSim has to be running) :
Your configuration should now looks like this :
Then we can click on “Start” to start the server:
Your gateway is ready !
Galileo Software (HMI)
Create a new project :
The panel has to support Ethernet as we’ll use this for the communication between the PLC and HMI :
For the PLC IP, use the same as for PlcSim :
Create a new byte and not a bit (see below)
Why a byte and not a bit ?
Read and write 1 bit is not supported by Galileo via Ethernet. If you try to do so, you’ll have the following message when compiling :
ERROR: bit ‘MyBit’:the size of 1 bits is not supported (increase to 8 bits) – PLC ‘Siemens - Industrial Ethernet’
Then we can map our byte to our bit in our DB :
Create a new value display/entry :
And map it to our byte :
Save and then compile :
And we can start the simulation :