Tab 'Communication Settings'Permalink

On this tab of the generic device editor, you define the connection between CODESYS and the device on which your application(s) should run. This includes security settings such as encrypted communication and signing.

If you prefer the classic mode of display for the dialog, then select it in the CODESYS “Options” in the “Device editor” category).

You select a gateway and a target device from the list boxes. The possible selections depend on the entries in the “Manage Gateways” and “Manage Favorite Devices” dialogs (see the “Gateway” menu).

You can also specify the target directly with the IP address (example: "192.168.101.109"), device address (example: "[056D]"), or device name (example: "MyDevice"). After the device is entered, CODESYS searches for the device in the network of the gateway.

The option of searching by device name requires unique device names in the network.

The solid circle on the lower right corner of the gateway symbol provides information about the connection status:

  • Red: CODESYS cannot establish the connection.

  • Green: The connection is established.

  • Black: The connection status is unknown.

Some communication protocols allow regular checking of the gateway so that the status cannot be displayed.

Clicking the solid circle of the target device starts a network scan for the device. This works only if the network is not already being scanned.

“Scan Network”

This button opens the “Select Device” dialog. It lists all configured gateways with the associated devices. You can select one target device from this list. If the name of the selected device is unique, then the name will be used in the connection settings. Otherwise, the unique device address is applied.

For details about this dialog, see the description of the classic view below.

Option: Hide non-matching devices, filter by Target ID:

_cds_icon_option_activated: The display is limited on the devices that have the same target ID as the current device configured in the project.

_cds_icon_option_deactivated: All available devices in the network are displayed. Double-clicking the entry of a device, which has a different target system ID than the device configured in the project, opens a dialog box. This dialog box allows you to update the device description of the device in the project to the one matching the selected device. Note: This kind of update is possible only with devices which have different IDs, not for those which only have different versions. The update also requires that the device description is already installed in the repository.

“Gateway ”

This menu includes the following commands:

  • “Add New Gateway”: Opens the “Gateway” dialog for defining a new gateway channel.

  • “Manage Gateways”: Opens the “Manage Gateways” dialog with an overview of all gateways. You can add or delete entries here or change their order.

  • “Configure Local Gateway”: Opens the “Gateway Configuration” dialog. You can configure the block drivers for the local gateway.

“Device”

This menu includes the following commands:

  • Options:

    • “Add Current Device to Favorites”: Adds the currently set device to the list of favorite devices.

    • “Manage Favorite Devices”: Opens the favorites dialog with a list of all preferred devices. In this dialog, you can add or delete entries or change their order. The top device is the default.

    • “Confirmed Online Mode”:

      _cds_icon_option_activated: For security reasons, CODESYS requires you to confirm the following when calling the following online commands: Force Values, Write Values, Multiple Loading, Release Force List, Single Cycle, Start, Stop.

    • “Store Communication Settings in Project”:

      _cds_icon_option_activated: CODESYS saves the communication settings in the project for reuse on the same computer.

      Note: If you use the project on another computer, then you have to reset the active path.

      _cds_icon_option_deactivated: CODESYS saves the communication settings in the options of the local installation for reuse on the same computer.

      Note: When using CODESYS SVN, the option should be cleared in order to prevent blocking the device object.

  • “Rename Active Device”:

    Opens a dialog for changing the device name.

  • “Wink Active Device”: Devices that support this function react by blinking.

  • “Send Echo Service”: CODESYS sends five echo services to the controller. These are used to test the network connection, similar to the ping function. The services are sent first without a payload and then with a payload. The scope of the payload depends on the communication buffer of the PLC. A message view opens with information about the average echo service delay and the scope of the sent payload.

  • “Encrypted Communication”:

    _cds_icon_option_activated: The communication to this controller is encrypted. A certificate of the controller is required in order to log in to the controller. If the certificate is not available, then an error message opens prompting whether or not the certificate should be displayed and installed.

    If the “Enforce encrypted communication” option is selected as “Security level” in the “Security Screen” view, then the “Encrypted Communication” command is disabled here.

  • “Change Runtime Security Policy”

    Opens the “Change Runtime Security Policy” dialog for changing the device setting for the encryption of communication.

  • “Change Runtime Password Policy”

    Opens the “Change Runtime Password Policy” dialog to change the settings for the password policy and the login lock

  • “Security Settings”: This command is available only if CODESYS Security Agent >= 1.3.0.0 is installed. It opens the “Device Security Settings” dialog. The current security settings on the connected device are displayed. You can change the settings in the “Value” column and click “OK” to write them to the device.

  • “Filter Network Scans by Target ID”:

    _cds_icon_option_activated: The display is limited on the devices that have the same target ID as the current device configured in the project.

Table 587: Dialog “Change Runtime Security Policy”

When you select a new communication policy in this dialog, the configuration in the runtime system is changed.

“Communication Settings”

“Current policy”

Shows the currently selected policy for the encryption of communication with the device

“New policy”

List box for the new policy for encryption

  • “No encryption”: The controller does not support encrypted communication.

  • “Optional encryption”: The controller supports encrypted and unencrypted communication.

  • “Enforced encryption”: The controller supports encrypted communication only.

“Code Signing”

“Current policy”

Display of the code signing policy which is currently set in the runtime system

“New policy”

  • “All”: All types of application code are accepted.

  • “Enforced signing”: Only signed application code is accepted (preventing loading an application from untrusted sources).

“Device User Management”

“Current policy”

Shows the currently selected policy for user management

“New policy”

  • “Optional user management”: It is the responsibility of the user to enable user management on the device or leave the device unprotected.

  • “Enforced user management”: The user management on the device is enabled and cannot be disabled by the user.

“Allow anonymous login”

_cds_icon_option_activated: Specific registered components (for example, OPC UA) can connect to the controller without the providing any credentials. Even if anonymous access to the OPC UA is permitted, the created device user management for the controller remains active.

Table 588: Dialog “Change Runtime Password Policy”

The runtime system password policy configured here is already checked in advance in the programming system when the password for a new device user is entered or when the existing password of a device user is changed.

“Password policy is active”

_cds_icon_option_activated: The “Password settings” can be changed and are used when a password for the device user management is created.

“Password settings”

  • “Minimum length”

    Default setting: 8

  • “Number of unique characters”

    Default setting: 4

  • “Requires lowercase letter”

    Default setting: enabled

  • “Requires uppercase letter”

    Default setting: enabled

  • “Requires digit”

    Default setting: enabled

  • “Requires special character”

    Default setting: enabled

  • “Must not contain username”

    Default setting: enabled

The following rules for the password always apply, even when the rules are partially or completely disabled:

  • The password must not be blank.

  • The password must not be the same as the user name.

“Login lock is active”

_cds_icon_option_activated: The “Login lock settings” are applied at login.

“Login lock settings”

  • “Scope”

    • “ADMINS”: The settings apply to users who have administrator permissions.

    • “NOADMINS”: The settings apply to all users who do not have administrator permissions.

    • “ALL”: The settings apply to all users.

  • “Maximal Retries”: When the number of login attempts specified here is exceeded, the user will be locked out for the amount of time which is specified in the “Lock duration” field. The user cannot log in again until the lock is removed by an administrator or the lockout time has expired.

  • “Lock duration [s]”: Lock time (in seconds)

Communication Settings - Classic Mode

In the CODESYS options, you can activate the classic mode of the dialog (“Tools  Options”, "Device Editor" category).

“Select the network path to the controller”

Gateway channel for the connection.

Select the channel from the lower part of the view.

Table 589: “View displaying configured gateway channels and network devices”

Left side of view

Tree structure of the configured gateway channels with the connected devices in the local network:

_cds_img_gateway_channels

Note: CODESYS saves these entries on the local system, not in the project.

The device entries are preceded by a device symbol (icon_device.png). Entries with a target ID that are different from those currently configured in the project are displayed in gray.

Click “Scan Network” to refresh the list.

Note: If you created the first project on the local system, then the local gateway is listed as an entry in the tree by default. CODESYS starts this gateway automatically on system boot.

The solid circle on the lower right corner of the gateway symbol provides information about the connection status:

  • Red: Automation Builder cannot establish the connection.

  • Green: The connection is established: _cds_img_gateway_connected

  • Black: The connection status is unknown.

    Note: Some communication protocols allow regular checking of the gateway so that the status cannot be displayed.

Each of the device entries in the tree consists of a symbol followed by the “Device name”> [“Device address”]. On the right side of the view, you also see the “Target ID”, “Target Name”, “Target Type, Target Vendor”, and “Target Version”.

Right side of view

Information about the gateway channel of device selected on the left side of the view.

When a gateway channel is selected in the left view, the following information is displayed: “Device name”, “IP address”, “Port”, “Driver”

When a device is selected in the left view, the following information is displayed (depending of the device): “Device name”, “Device address”, “Number of channels”, “Block driver”, “Serial number”, “Encrypted communication”, “Target vendor”, “Target ID”, “Target name”, “Target type”,“ Target version”.

Table 590: “Filter and sorting functions on the right side of the dialog”

“Filter”

You can reduce the displayed list of devices that have the same “Target ID” as the current device configured in the project.

“Sorting order”

You can sort the list by “Name” or “Device Address” in alphabetical or ascending order.

Table 591: Command buttons on the right side of the dialog

“Set Active Path”

The command sets the selected communications channel as active. Double-clicking the entry in the channel tree achieves the same result.

“Add Gateway”

The command opens the “Gateway” dialog where you can define a gateway that CODESYS should add to the current configuration.

“Add Device”

The command opens the “Add Device” dialog. Here you can manually define a device that is to be inserted under the gateway entry currently selected in the tree. Note the functionality of “Scan Network” as well.

“Scan Network”

The command starts a search for available devices in the local network. The configuration tree of the gateway is refreshed accordingly.

Table 592: “Commands in the context menu of the gateway tree and device tree in the dialog”

“Scan for Device by Address”

The command searches the network for devices with a unique address as given in the configuration tree. CODESYS displays the detected devices with the given address below the gateway. The search always applies to the devices below the selected gateway or below the selected entry.

“Scan for Device by Name”

The command searches the network for devices with the same name as given in the configuration tree. Capitalization is ignored. CODESYS displays the detected devices below the gateway with the given name together with its unique device address. The search always applies to the devices below the selected gateway or below the selected entry.

“Scan for Device by IP Address”

The command searches the network for devices with a unique IP address as given in the configuration tree. CODESYS displays the detected devices with the given address below the gateway together with its name. The search always applies to the devices below the selected gateway or below the selected entry.

“Send Echo Service”

CODESYS sends five echo services to the controller. These are used to test the network connection, similar to the ping function. The services are sent first without a payload and then with a payload. The scope of the payload depends on the communication buffer of the PLC. A message view opens with information about the average echo service delay and the scope of the sent payload.

“Delete Selected Device”

The command deletes the selected device from the channel tree.

“Edit Gateway”

The command opens the “Gateway” dialog for editing the settings for the selected gateway.

“Configure the Local Gateway”

The command opens a dialog for configuring a local gateway. This provides an alternative to manually editing the ‎Gateway.cfg‎ file.

Table 593: Options in the lower part of the dialog

“Don't store communication settings in project”

  • _cds_icon_option_activated: CODESYS saves the communication settings in the options of the local installation for reuse on the same computer.

    Note: When using CODESYS SVN, the option should be selected in order to prevent blocking the device object.

  • _cds_icon_option_deactivated: CODESYS saves the communication settings in the project for reuse on the same computer.

    Note: If you use the project on another computer, then you have to reset the active path.

“Confirmed Online Mode”

_cds_icon_option_activated: For security reasons, CODESYS requires you to confirm the following when calling the following online commands: “Force Values”, “Write Values”, “Multiple Loading”, “Release Force List”, “Single Cycle”, “Start”, “Stop”.