Skip to main content

Getting Started – Commissioning of NetX Adapters

Requirement: A NetX adapter is inserted into a slot of the computer.

1. Install drivers for Windows

If you want to use a NetX adapter with a CODESYS runtime, then you have to install the following drivers:

  • For CODESYS Control Win: SysDrv3s.sys driver

  • For CODESYS Control RTE: RTIOwdmGenericc.sys driver or SysDrv3s.sys driver

    Note: The installed driver has to be passive. When using CODESYS Control RTE, it is also possible to install no specific driver at all.

Tip

When installing CODESYS Control Win, the SysDrv3s.sys driver is saved in the program folder ../GatewayPLC/Driver; for CODESYS Control RTE, in the ../SysDrv3s folder.

The NetX firmware and the NetX boot loader are located in the HilscherCIFX folder for both runtimes.

Important

The NetX firmware and the NetX Second Stage Boot Loader must be the same version. Otherwise, the NetX firmware and the fieldbus will not work.

The NetX Second Stage Boot Loader and the NetX firmware are reloaded to the NetX chip each time the runtime is started.

2. Edit the file "CODESYSControl.cfg" in the CODESYS runtime system folder

  1. Open the file CODESYSControl.cfg of the respective runtime system directory in a text editor.

  2. Remove the semicolon in the section [ComponentManager] at the beginning of the entry CmpHilscherCIFX so that the entry is no longer commented out.

  3. In the area [CmpHilscherCIFX], follow the steps below to edit the entries for the NetX adapter and the NetX configuration.

    The following entries have to exist for the firmware and boot loader:

    DynamicFirmware=1

    BootloaderFile=./HilscherCIFX/Firmware/NETX100-BSL.bin

    FirmwareFilePath=./HilscherCIFX/Firmware

  4. If the entry DMAMode=1 is commented out, then remove the semicolon (;) at the beginning of the line.

  5. Remove the semicolon in front of the following entries:

    Device.0.BootloaderFilePath=.\HilscherCIFX\Firmware\NETX100-BSL.bin

    Device.0.Channel.0.FirmwareFile=.\.\HilscherCIFX\Firmware\cifxcom.nxf

    Description:

    • Device.X.BootloaderFilePath: Specifies the file path and the file name of the NetX boot loader for each NetX chip. (The relative path starts in the installation folder. Absolute paths are also possible.) If multiple NetX chips are used, the multiple files paths must also be specified:

      Device.0.BootloaderFilePath=.\HilscherCIFX\Firmware\NETX100-BSL.bin

      Device.1.BootloaderFilePath=.\HilscherCIFX\Firmware\NETX100-BSL.bin

    • Device.X.Channel.X.FirmwareFile: Specifies the file path and the file name of the NetX firmware for each NetX chip and each channel. (The relative path starts in the installation folder. Absolute paths are also possible.) In most cases, only channel 0 is used. If multiple NetX chips are used, the multiple files paths must also be specified:

      Device.0.Channel.0.FirmwareFile=.\HilscherCIFX\Firmware\cifxcom.nxf

      Device.1.Channel.0.FirmwareFile=.\HilscherCIFX\Firmware\cifxcom.nxf

  6. If you want to get more comprehensive logger messages from your controller (device editor of the controller, Log tab), then remove the semicolon (;) at the following locations: in the area [CmpHilscherCIFX] before the entry TraceLevel=0xffffffff, and in the area [CmpLog] before the entries:

    Logger.0.Name=PlcLog

    Logger.0.Filter=0xFFFFFFFF

  7. Save the file CODESYSControl.cfg.

3. Creating a NetX configuration for a project

  1. In CODESYS, click File → New Project to create a new standard project. In the New Project dialog, select the Standard Project template.

  2. In Standard Dialog, select the controller (example: CODESYS Control Win) and click OK.

    The new standard project is displayed in the device tree.

  3. Click Add Device in the context menu of the controller.

  4. In the Add Device dialog of Profibus → DP Master, select a NetX fieldbus master (example: CIFX-PB) and click Add Device.

  5. Double-click the NetX fieldbus master in the device tree (example: CIFX-PB) and select the PROFIBUS Master – NetX Configuration tab in the editor.

  6. Select Slot 0 from the Slot list box and NetXComChannel0 from NetX com channel.

    Caution: The number of the selected slot (example: Slot 0) has to correspond to the number of the device in the file CODESYSControl.cfg (example: Device.0). Likewise, the number of the selected NetX com channel (example: NetX Com channel 0) must correspond to the entries in the file CODESYSControl.cfg (example: Channel.0).

  7. Log in to the controller and click Debug → Start to start the application.

    _cds_img_netx_project.png

    If there are no error messages, then the NetX adapter has been configured correctly and you can now continue developing the project.