Codesys programming errors

Introduction:
Weintek’s implementation of Codesys is such that certain features like Codesys visualization are not supported. The use or addition of objects or libraries related to unsupported features may produce errors within your project, preventing compilation. Within this post, we provide examples of some common errors and describe steps that may lead to their resolution.

Software Version:
Codesys IDE 3.5.15.50
Codesys package
[Optional] Codesys firmware

Symbols:

Symbol Description
14x14 The device description could not be found in the device repository.
14x12 The device is configured, but not fully operational. No data is exchanged.
14x12 The device is not exchanging data; bus error, no configuration, or simulation mode
16x14 The device is running in demo mode for 30 minutes. When this time has elapsed, demo mode will expire and the field bus will end the data exchange.
14x12 The PLC is connected and the application is running, but diagnostic information is available for the affected device.
15x14 The device itself is running, but a child device is not running or it has a diagnosis message. The child device is not visible due to a collapsed device tree.
33x12 The object contains an error and the project cannot compile. An error is available within the messages window.
Note: Errors within objects are typically marked with a 14x14 symbol.
33x11 The object contains an error and the project cannot compile. An error is available within the messages window.
Note: Errors within objects are typically marked with a 14x14 symbol.
33x11 The object may not produce the intended result. A warning is available within the messages window.
33x11 The object may not produce the intended result. A warning is available within the messages window.
33x11 A child of this object contains an error or warning.
33x11 A child of this object contains an error or warning.

Examples:

Library:

When transferring a project to another PC, the application may fail to load if the owner of that PC is using a different version of Codesys. However, if the application does load it may display several errors or warnings related to objects within the “Library Manager”.
Example: The IDE indicates that their are 2 warnings associated with objects in the “Library Manager”. Some large applications may produce 10 or more warnings.

To resolve issues related to objects within the “Library Manager”, please perform the following:

  1. Double click to open the “Library Manager”:
    image

  2. Within the following menu, select “Download missing libraries”:

  3. Follow the prompts to download any missing libraries:
    Note: A library developed by Weintek cannot be retrieved using this method. Instead, please install our Codesys package on this PC. We highly recommend using Codesys version 3.5.15.50.

Note: Weintek’s built-in Codesys is not compatible with most libraries that require OS support such as the IIoT library that includes the following functions MQTT Client, Web Client, etc. The libraries within the table below are compatible with Weintek’s built-in Codesys. Other libraries that do not require OS support are also compatible with Weintek’s built-in Codesys.; e.g. OSCAT Basic, Util library…etc.

Sys Library Cmp Library CAA Library
SysTimeRtc CmpTraceMgr CAAType
SysTimer CmpSrv CAATick
SysTime CmpSettings CAATickUtil
SysTask CmpSchedule CAAStorage
SysTarget CmpRouter
SysSocket CmpPlcShell
SysMem CmpLog
SysFile CmpIoMgr
SysExcept CmpIoDrvC
SysEvent CmpIecVarAccess
SysEthernet CmpIecTask
SysDir CmpEventMgr
SysCpuHandling CmpDynamicText
SysCom CmpCheckSum
CmpChannelServer
CmpBinTagUtilIec
CmpAsyncMgr
CmpAppBP

add-on(s):

When transferring an application from one PC to another the IDE may display a warning that indicates any number of missing add-on(s). This message will display in the bottom right corner. If this occurs, please double-click on this warning and follow the prompts to install all missing packages.

Messages:

The Codesys IDE uses a drop-down list to organize messages depending on their relevance to various components. If The IDE indicates that you have a project error but you do not see one within the “Messages” dialog, please select each component within the drop-down list to view the corresponding message:
Example: This project has 216 errors but none are visible within the messages window. To resolve this, please follow the steps described below.

  1. Select the drop-down list on the top left:
  2. Select each item within this list to view the corresponding messages:
    Note: While “Build” is selected within this example each error is visible.

    Note: If the "error(s) option is not selected the errors will not be displayed. In this image the error option is not enabled so no errors are visible.
  3. Double click an error and the IDE may open the source of this error within the project:

Notes:

  • Hover your mouse over a variable with an underline image and the corresponding message will be displayed:
    image
  • Hover your mouse over a 14x14 symbol and the corresponding message will be displayed:
    image
Keywords

C00, C01, C02, C05, debug, blue underline, red question mark, red underline, grey underline, red triangle, orange triangle, error code, unknown type, cannot convert type