You are on page 1of 48

Twido/Magelis Connectivity Users Guide

Instruction Bulletin
XXXXX-XXX-XX
Retain for future use.

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Table of Contents

Table of Contents

Introduction ................................................................................................ 5 Hardware Requirements ............................................................................ 5 Software Requirements ............................................................................. 5 References .................................................................................................. 5 Modbus RTU ............................................................................................... 6 Twido PLC Setup ........................................................................................ 6 Magelis XBTG/XBTGT Operator Terminal Setup ..................................... 12 Modbus TCP/IP ......................................................................................... 24 Twido PLC Setup ...................................................................................... 24 Magelis XBTG/XBTGT Operator Terminal Setup ..................................... 31

2007 Schneider Electric All Rights Reserved

Twido/Magelis Connectivity Users Guide Table of Contents

XXXXX-XXX-XX 08/2007

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Introduction

Introduction

The Magelis XBTG/XBTGT operator terminal can be interfaced to the Twido PLC using either Modbus RTU or Modbus TCP/IP. This document outlines the hardware and software setup needed to accomplish each connection.

Hardware Requirements

You will need the following hardware for this application: 1. The Twido PLC parts necessary for their particular application. An additional serial port is strongly recommended. The additional serial port allows for communication to the XBTG/XBTGT operator terminal while being able to download and monitor the Twido PLC. The Twido Modular processor, TWDLMDA40DTK is used in this example. 2. The XBTG/XBTGT operator terminal appropriate for your application. If Modbus TCP/IP is required, select a model with an Ethernet port. The XBTG4330 operator terminal is used in this example. 3. A serial download cable appropriate for the XBTG/XBTGT operator terminal and Modbus communication cable for the desired communication port. The XBTZG915 serial download cable and XBTZ968 communication cable for the Modbus communication to COM Port 1 are used in this example.

Software Requirements

1. Twido Soft version 3.2 or higher will be needed to program the Twido PLC. 2. Vijeo Designer version 4.3.0 or higher will be needed to program the Magelis HMI.

References

This document provides the user with a guide to connect a Twido PLC to a Magelis XBTG/XBTGT operator terminal using either Modbus RTU or Modbus TCP/IP. It does not provide the user with how to use the Twido Soft software or how to use the Vijeo Designer software. Please refer to the reference material in the Table 1 for more detailed documentation. Table 1: Documentation
Model ID
TWD USE 10AE, V3.2 TWD USE 10AE, V3.2 DIA3ED2041102EN 35010372 MKTED206071EN

Reference Title
Twido Software Reference Guide, V3.2 Twido Hardware Reference Guide, V3.2 Twido Catalog User Manual, Magelis XBTGT Catalog Human Machine Interfaces in English

2007 Schneider Electric All Rights Reserved

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

Modbus RTU
Twido PLC Setup
1. Connect Port 1 on the Twido PLC to the laptop PC with cable TSXPCX3030 (USB) or TSXPCX1031 (serial). This cable has a selector switch on it to allow connection to different devices and it needs to be in the Ter Direct position for the Twido PLC. This example uses TSXPCX3030. 2. Start the Twido Soft software on the laptop PC and open up a project to start the configuration process of the communication ports. See Figure 1. Figure 1: Start Twido Soft

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

3. Check the connection setup for the serial connection from the laptop PC to the Twido PLC. Select Preferences from the File menu listing as shown in Figure 2. Figure 2: Preferences

4. Press the Connections management button as shown in Figure 3. Figure 3: Connections management button

5. Setup all connections to be used to communicate to the Twido PLC. This example uses the TSXPCX3030 (USB) cable so after the connections have been added/modified, select OK to close the window. The Preferences window appears again. Select the preferred connection means from the pull down list and select OK to close the window. See Figure 4. Figure 4: Connections management pull down menu

2007 Schneider Electric All Rights Reserved

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

6. Connect to the Twido PLC to verify that the connection setup and cable works correctly. Go to the PLC menu and select Select a connection USB or comm port needed to connect. See Figure 5. Figure 5: Select a connection

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

7. After the correct connection means has been selected, select Connect from the PLC menu listing. If this is the first connection to the PLC, select the PC Controller button to download the configuration to the Twido PLC as shown in Figure 6. Figure 6: PC Controller button

8. After the connection test, disconnect from the PLC by selecting Disconnect from the PLC menu.

2007 Schneider Electric All Rights Reserved

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

9. Right click Port 1 and select Edit Controller Comm Setup. See Figure 7. Figure 7: Edit Controller Comm Setup

10

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

Figure 8 shows the setup of Port 1 for Remote Link. The Address in this example is 1. Figure 8: Controller Communications Setup

10. Select the tab for Port 2 or right click on Port 2 and select Edit Controller Comm Setup if the window has been closed. Figure 9 shows the setup of Port 2 for Modbus. The Address in this example is 2 with the following parameters: 19200, 8 data bits, No Parity and 1 stop bit. Figure 9: Controller Communications Setup for Modbus

11. After the Port settings have been added/modified, re-connect to the PLC and download the port settings to the Twido PLC.

2007 Schneider Electric All Rights Reserved

11

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

Magelis XBTG/XBTGT Operator Terminal Setup


Figure 10: Cordsets and connection ports

1. Connect Port 2 on the Twido PLC to the Magelis XBTG/XBTGT operator terminal. Please refer to the Figure 10 for the correct connection cable and connection port. (This example used the cable XBT Z968 to COMM Port 1 on a Magelis XBTG4330.)

12

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

2. Start Vijeo Designer on the laptop PC and open up a project to start the configuration process to communicate via Modbus with the Twido PLC. See Figure 11. Figure 11: Start Vijeo Designer

2007 Schneider Electric All Rights Reserved

13

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

3. Setup the Download communication protocol by selecting Serial from the drop down listing in the Property Inspector window. Select the correct COM Port for the laptop PC with the following Baud rate: 19200. This example is using COM port 1. See Figure 12. Figure 12: Property Inspector

14

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

4. Add a Schneider Electric Modbus driver by right clicking on the IO Manager and selecting New Driver. See Figure 13. Figure 13: IO Manager and select new driver

2007 Schneider Electric All Rights Reserved

15

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

5. Select Schneider Electric Industries SAS from the Manufacturer: pull down listing and select the Modbus (RTU) driver as shown in Figure 14. Figure 14: New Driver

6. The new driver will be added to the IO Manager. The driver now needs to be setup to communicate to the serial port on the Twido PLC. Doubleclick on the ModbusRTU01 driver to open up the Driver Configuration window as shown in Figure 15. Figure 15: ModbusRTU01

16

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

The driver needs to be setup with the following: COM1, RS-485, 19200, 8 data bits, No Parity and 1 stop bit. See Figure 16. NOTE: We are using COM1 because we have chosen cable XBT Z968 to communicate to the Magelis XBTG and this cable only works with COM1. Figure 16: Driver Configuration

2007 Schneider Electric All Rights Reserved

17

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

7. The Modbus address needs to be setup to communicate with the Twido PLC in the Equipment Configuration window. Double-click on ModbusEquipment02 to open up the Equipment Configuration window as shown in Figure 17. NOTE: In the Twido example, a Modbus address of 2 was used so we need to make this address 2 to be able to communicate with the Twido PLC. Figure 17: Equipment Configuration

The IEC61131 Syntax must be checked if the variables from the PLC are to be linked to variables within the Vijeo Designer application.

18

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

8. Select the Variables tab in the Navigator window as shown in Figure 18. Figure 18: Navigator Variables Tab

2007 Schneider Electric All Rights Reserved

19

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

9. Right click on the Target1 to link variables from the Twido PLC to variables within the Vijeo Designer application. See Figure 19. Figure 19: Link Variables from Twido PLC to Variables within Vijeo Designer

20

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

10. The Link Variables window allows for the selection of the appropriate Twido application. See Figure 20. NOTE: Be sure to select *.TWD as the type of file and make sure that Twido Soft is shutdown before trying to link the variables. Figure 20: Link Variables

2007 Schneider Electric All Rights Reserved

21

Twido/Magelis Connectivity Users Guide Modbus RTU

XXXXX-XXX-XX 08/2007

11. Select the desired variables to link or press the Select All button. Select the Variables that keep the same name radial so that the variable names are the same in each application. Add the variables to the Vijeo Designer application by pressing the Add button. Then press the Close button to close the window as shown in Figure 21. Figure 21: Select the Variables

12. A status window opens to show the success/failure of the variable linking as shown in Figure 22. NOTE: This window will pop-up at various time to show the status of a function. Figure 22: Feedback Zone

22

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus RTU

13. Create a panel with a few simple objects to test the connectivity with the Twido PLC. When ready, build the application and download it to the XBTG/XBTGT operator terminal by selecting Download All from the Build menu. See Figure 23. Figure 23: Build Menu

14. Test the functionality of the system.

2007 Schneider Electric All Rights Reserved

23

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

Modbus TCP/IP
Twido PLC Setup
1. Connect Port 1 on the Twido PLC to the laptop PC with cable TSXPCX3030 (USB) or TSXPCX1031 (serial). This cable has a selector switch on it to allow connection to different devices and it needs to be in the Ter Direct position for the Twido PLC. This example uses TSXPCX1031. 2. Start the Twido Soft software on the laptop PC and open up a project to start the configuration process of the communication ports. See Figure 24. Figure 24: Start Twido Soft

24

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

3. Check the connection setup for the serial connection from the laptop PC to the Twido PLC. Select Preferences from the File menu listing as shown in Figure 25. Figure 25: Preferences

4. Press the Connections management button as shown in Figure 26. Figure 26: Connections Management

2007 Schneider Electric All Rights Reserved

25

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

5. Setup all connections to be used to communicate to the Twido PLC. This example uses the TSXPCX1031 (Serial) cable so after the connections have been added/modified, select OK to close the window. The Preferences window appears again. Select the preferred connection means from the pull down list and select OK to close the window. See Figure 27. Figure 27: Connections management pull down list

6. Connect to the Twido PLC to verify that the connection setup and cable works correctly. Go to the PLC menu and select Select a connection COM2 or USB/comm. port needed to connect. See Figure 28. Figure 28: Select a Connection

26

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

7. After the correct connection means has been selected, select Connect from the PLC menu listing. If this is the first connection to the PLC, select the PC Controller button to download the configuration to the Twido PLC. See Figure 29. Figure 29: PC Controller

8. After the connection test, disconnect from the PLC by selecting Disconnect from the PLC menu.

2007 Schneider Electric All Rights Reserved

27

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

9. Right click Port 1 and select Edit Controller Comm Setup. See Figure 30. Figure 30: Edit Controller Comm Setup

28

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

10. Figure 31 shows the setup of Port 1 for Remote Link. The Address in this example is 1. Figure 31: Controller Communications Setup

11. Select the tab for Port 2 or right click on Port 2 and select Edit Controller Comm Setup if the window has been closed. Figure 32 shows the setup of Port 2 for Modbus. The Address in this example is 2 with the following parameters: 19200, 8 data bits, No Parity and 1 stop bit. Figure 32: Controller Communications Setup for Modbus

2007 Schneider Electric All Rights Reserved

29

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

12. The Twido Ethernet Port needs to be configured to allow the Twido to communicate on an Ethernet network. Double click on the Twido Ethernet Port. See Figure 33. Figure 33: Twido Ethernet Port

13. Enter the correct IP Address, Subnetwork mask and Gateway Address and press OK as shown in Figure 34. Figure 34: Twido Port configuration

14. After the Port settings have been added/modified, re-connect to the PLC and download the port settings to the Twido PLC.

30

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

Magelis XBTG/XBTGT Operator Terminal Setup


Figure 35: Cordsets and Connections Ports

1. Connect Port 2 on the Twido PLC to the Magelis XBTG/XBTGT operator terminal. Please refer to the Figure 35 for the correct connection cable and connection port. (This example used the cable XBT Z968 to COMM Port 1 on a Magelis XBTG4330.)

2007 Schneider Electric All Rights Reserved

31

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

2. Start Vijeo Designer on the laptop PC and open up a project to start the configuration process to communicate via Modbus with the Twido PLC. See Figure 36. Figure 36: Start Vijeo Designer

32

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

3. Setup the Download communication protocol by selecting Serial from the drop down listing in the Property Inspector window as shown in Figure 37. Select the correct COM Port for the laptop PC with the following Baud rate: 19200. This example is using COM port 1. Since this application is using an Ethernet connection, go ahead and configure the IP Address, Subnet Mask and Default Gateway. Figure 37: Property Inspector

2007 Schneider Electric All Rights Reserved

33

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

4. Add a Schneider Electric Modbus driver by right clicking on the IO Manager and selecting New Driver as shown in Figure 38. Figure 38: Selecting New Driver

34

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

5. Select Schneider Electric Industries SAS from the Manufacturer: pull down listing and select the Modbus TCP/IP driver as shown in Figure 39. Figure 39: New Driver

6. The new driver will be added to the IO Manager. The driver now needs to be setup to communicate to the serial port on the Twido PLC. Doubleclick on the ModbusTCPIP01 driver to open up the Driver Configuration window as shown in Figure 40. Figure 40: ModbusTCPIP01

2007 Schneider Electric All Rights Reserved

35

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

7. Verify the driver settings. The settings should be OK if the Ethernet Port was configured for the download feature. See Figure 41. Figure 41: Verify the Driver Settings

36

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

8. The Modbus address and Equipment IP address need to be setup in order to communicate with the Twido PLC. Double-click on ModbusEquipment01 driver to open up the Equipment Configuration window as shown in Figure 42. 9. Enter the IP Address that was assigned to the Twido PLC and change the Unit ID to the Modbus address that was assigned to the Modbus port on the Twido PLC. NOTE: In the Twido example, a Modbus address of 2 was used so we need to make this address 2 to be able to communicate with the Twido PLC. Figure 42: Equipment Configuration

The IEC61131 Syntax must be checked if the variables from the PLC are to be linked to variables within the Vijeo Designer application.

2007 Schneider Electric All Rights Reserved

37

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

10. Select the Variables tab in the Navigator window as shown in Figure 43. Figure 43: Navigator Variables Tab

38

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

11. Right click on Target1 to link variables from the Twido PLC to variables within the Vijeo Designer application. See Figure 44. Figure 44: Link Variables from Twido PLC to Variables within Vijeo Designer

2007 Schneider Electric All Rights Reserved

39

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

12. The Link Variables window allows for the selection of the appropriate Twido application. See Figure 45. NOTE: Be sure to select *.TWD as the type of file and make sure that Twido Soft is shutdown before trying to link the variables. Figure 45: Link Variables

40

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

13. Select the desired variables to link or press the Select All button. Select the Variables that keep the same name radial so that the variable names are the same in each application. Add the variables to the Vijeo Designer application by pressing the Add button. Then press the Close button to close the window. See Figure 46. Figure 46: Select the Variables

14. A status window opens to show the success/failure of the variable linking. See Figure 47. NOTE: This window will pop-up at various time to show the status of a function. Figure 47: Feedback Zone

2007 Schneider Electric All Rights Reserved

41

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

15. Create a panel with a few simple objects to test the connectivity with the Twido PLC. 16. When ready, build the application and download it to the XBTG/XBTGT operator terminal by selecting Download All from the Build menu. See Figure 48. Figure 48: Build Menu

17. Test the functionality of the system.

42

2007 Schneider Electric All Rights Reserved

XXXXX-XXX-XX 08/2007

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

18. Once the initial download is complete, the XBTG/XBTGT operator terminal will have an IP Address assigned. The Download communication can then be changed to Ethernet. See Figure 49. Figure 49: Property Inspector

2007 Schneider Electric All Rights Reserved

43

Twido/Magelis Connectivity Users Guide Modbus TCP/IP

XXXXX-XXX-XX 08/2007

44

2007 Schneider Electric All Rights Reserved

Twido/Magelis Connectivity Users Guide Instruction Bulletin

Schneider Electric USA


8001 Knightdale Blvd. Knightdale, NC 27545 USA 1-888-SquareD (1-888-778-2733) www.us.Telemecanique.com

Electrical equipment should be installed, operated, serviced, and maintained only by qualified personnel. No responsibility is assumed by Schneider Electric for any consequences arising out of the use of this material.

XXXXX-XXX-XX 2007 Schneider Electric All Rights Reserved 08/2007

You might also like