14.2 Exercise
|
Exercise: Connect to a CIMON PLC via Ethernet
I/O Device Configuration
Click Tools > I/O Device Editor > + icon, then select Add Ethernet Device. Enter Device Name > choose CIMON CI-net protocol for Device Type > click Ok.
Once the correct Device Type has been selected, an additional configuration menu will be displayed. Match the settings in this window to the below configuration.
Page Configuration
To ensure that the target PLC is communicating properly, a Text Box that displays the value of a real tag can be placed on the main screen. If the PLC is communicating properly, updating the tag’s value in CICON will yield a change in tag value on the XPanel.
Create a tag using the Tag Editor, then configure the tag as shown below.
Place a Text Box on the main page of the project. Then in the Property Editor window, link the tag created above to the Text option.
Checking Operation
In CICON, create the program shown below. The program sets D50 to a random number on each new scan as long as M00 remains pressed.
In the CICON project tree, click Parameter > double-click PLC Parameter.
In the Ethernet tab, match the IP Address to the one used in the I/O Device Editor configuration menu. If the PLC and Xpanel are on the same local network, then the subnet mask and gateway should match. Once finished, click OK.
Download the program to the PLC and run it. You can edit the value of M00 in CICON while connected to the PLC or toggle the M00 and use hotkey [Shift] + [enter]. When the M00 contact turns ON, you will find that the value stored in D0 changes on the Xpanel screen.