Horner XL4 Establishing Communication

We program the Horner XL4 OCS all-in-one controller by using Cscape. We will now use our Cscape software to establish communication. Last time we customized Cscape with icons to make it easier to find, communicate and control the unit. There are two different ways to communicate to the XL4 OCS controller, Ethernet and Serial. There are several different methods within these two ways that the XL4 will communicate. The Cscape software package will communicate both of these ways. We will look at establishing communication using Ethernet, USB (Serial), and Serial RS232. Another two serial ways to communicate would be RS485/RS422 (Serial) and CAN Bus (Serial). These two methods allow multiple controllers connected to the communication network. This is similar to Ethernet.

Previously we discussed the following in our Horner XL4 Series:
System Hardware
Installing the Software Cscape
Cscape Software Setup

We will discuss each way of establishing communication and then look at how to implement the programming package.

USB Port Communication – Horner XL4

This is the preferred method of communicating to the Cscape software package. It is quick and the drivers are preloaded already with the installation of the Cscape software. (Version 9.7 or newer) The drivers can also be downloaded from the Horner website at the following URL:
http://www.horner-apg.com/en/download/ocs.aspx

Horner XL4 Establishing Communication
Plug your USB 2.0 Mini B plug into the XL4 controller and the other end into your computer. The computer will automatically load the driver required. A serial port number will be assigned to your computer. Please refer to your device manager to see the port assigned. Start | Control Panel | Device Manger
Horner XL4 Establishing Communication
In my case, the Controller USB COM Port (COM9) is being used.

Serial Port Communication – Horner XL4

Horner sells an RS232 cable to communicate to the XL4. This will plug into your 9 pin serial port on your computer. The following is from the XL4 manual and shows the pinout of the RS232 port so that you can make your own cable.
Horner XL4 Establishing Communication
Most computers will no longer come with serial ports, so you will have to use a USB to Serial adapter.
Most serial adapters use the same method for installation. Here is a link to describe the steps involved in installing this adapter.

USB to RS485 PC Adapter Installation


Plug your serial cable into your computer and the other end into the RS232 port of the XL4 controller. Please refer to your device manager to see the port assigned. Start | Control Panel | Device Manger
Horner XL4 Establishing Communication
In my case, the Prolific USB-to-Serial Comm Port (COM8) is being used.

Ethernet Communication – Horner XL4

The first thing that we need to do is to set the IP address and Network Mask on the XL4 controller. To do this hit the system button on the front of the controller. This will call up a menu that allows you to set a number of items in the controller.
Horner XL4 Establishing Communication
We will set the IP Address to 192.168.1.131 and the mask to 255.255.255.0. A previous post was done titled “What everybody ought to know about IP Addressing”. This post will explain the IP addressing and mask network settings.
The IP address and mask must also be set in the Cscape software package. This is done by selecting Controller | Hardware from the main menu.
Horner XL4 Establishing Communication
You can manually fill in the Series, Device Type and Model #. When this is done you can select the ‘Config’ button beside LAN1.
Horner XL4 Establishing Communication
Enter the IP address and mask settings. Note that this can also be set by registers in the controller. Now hit OK.

Cscape – Control Station Central Application Programming Environment – Communication

Now that we have our method of communication attached we can now start to communicate. When we start our program the connection wizard will appear. If it does not, then from the main menu select Controller | Connection Wizard.
Horner XL4 Establishing Communication
Select the method that you want to communicate and then hit next.

USB

If you are unsure of the port number just hit the ‘I Don’t Know’ button and it will scan your system for the correct port.
Horner XL4 Establishing Communication

Serial

If you are unsure of the port number just hit the ‘I Don’t Know’ button and it will scan your system for the correct port.
XL4 Establishing Com

Ethernet

Horner XL4 Establishing Communication
You will now hit the ‘Finish’ button on the connection wizard window to now establish communication.

We can see the status of the controller by selecting Controller | Status from the main menu.
Horner XL4 Establishing Communication
The menus have now all changed when you are communicating to the controller. The greyed-out options are now available.
XL4 Establishing Com
The status bar at the bottom of the Cscape window will indicate your online communication connection.
XL4 Establishing Com

Horner provides a troubleshooting guide on their website for communication to the Cscape software package. This can also be found in the XL4 manual.
Troubleshooting Communications on the X series Controllers:
https://hornerautomation.com/wp-content/uploads/2017/08/MAN1018-03-EN.pdf

FAQ – Frequently Asked Questions

All of the documentation can be downloaded at the following URL:
https://hornerautomation.eu/product/xl4-prime-ocs-3-5-colour-touchscreen/

Next time we will look at numbering systems and addressing.

Watch on YouTube: Horner XL4 Establishing Communication

If you have any questions or need further information please contact me.
Thank you,
Garry



If you’re like most of my readers, you’re committed to learning about technology. Numbering systems used in PLCs are not difficult to learn and understand. We will walk through the numbering systems used in PLCs. This includes Bits, Decimal, Hexadecimal, ASCII, and Floating Point.

To get this free article, subscribe to my free email newsletter.


Use the information to inform other people how numbering systems work. Sign up now.

The ‘Robust Data Logging for Free’ eBook is also available as a free download. The link is included when you subscribe to ACC Automation.


Leave a Comment