
- •1 A Brief Introduction to CoDeSys
- •1.1 What is CoDeSys
- •1.2 Overview of CoDeSys Functions...
- •1.3 Overview on the user documentation for CoDeSys
- •2 What is What in CoDeSys
- •2.1 Project Components...
- •2.2 Languages...
- •2.2.1 Instruction List (IL)...
- •2.2.2 Structured Text (ST)...
- •2.2.3 Sequential Function Chart (SFC)...
- •2.2.4 Function Block Diagram (FBD)...
- •2.2.5 The Continuous Function Chart Editor (CFC)...
- •2.2.6 Ladder Diagram (LD)...
- •2.3 Debugging, Online Functions...
- •2.4 The Standard...
- •3 We Write a Little Program
- •3.1 Controlling a Traffic Signal Unit...
- •3.2 Visualizing a Traffic Signal Unit...
- •4 The Individual Components
- •4.1 The Main Window...
- •4.3 Managing Projects...
- •4.4 Managing Objects in a Project...
- •4.5 General Editing Functions...
- •4.8 Help when you need it...
- •5 Editors in CoDeSys
- •5.1 This is for all Editors...
- •5.2 Declaration Editor...
- •5.2.1 Working in the Declaration Editor
- •5.2.3 Pragma instructions in the Declaration Editor
- •5.3 The Text Editors...
- •5.3.1 Working in text editors
- •5.3.2 The Instruction List Editor...
- •5.3.3 The Editor for Structured Text...
- •5.4 The Graphic Editors...
- •5.4.1 Working in graphic editors
- •5.4.2 The Function Block Diagram Editor...
- •5.4.3 The Ladder Editor...
- •5.4.4 The Sequential Function Chart Editor...
- •5.4.5 The Continuous Function Chart Editor (CFC)...
- •6 The Resources
- •6.1 Overview of the Resources
- •6.2 Global Variables, Variable Configuration, Document Frame
- •6.2.1 Global Variables...
- •6.2.2 Variable Configuration...
- •6.2.3 Document Frame...
- •6.3 Alarm Configuration
- •6.3.1 Overview
- •6.3.2 General information on alarms, Terms
- •6.3.3 Alarm classes
- •6.3.4 Alarm groups
- •6.3.5 Alarm saving
- •6.3.6 'Extras' Menu: Settings
- •6.4 Library Manager...
- •6.6 PLC Configuration...
- •6.6.1 Overview
- •6.6.2 Working in the PLC Configuration...
- •6.6.3 General Settings in the PLC Configuration
- •6.6.4 Custom specific parameter dialog
- •6.6.5 Configuration of an I/O Module...
- •6.6.6 Configuration of a Channel
- •6.6.7 Configuration of Profibus Modules...
- •6.6.8 Configuration of CAN modules...
- •6.6.9 Configuration of a CanDevice (CANopen Slave)
- •6.6.10 PLC Configuration in Online Mode
- •6.6.11 Hardware scan/State/Diagnosis information from the PLC
- •6.7 Task Configuration...
- •6.7.1 Working in the Task Configuration
- •6.7.2 System Events
- •6.7.3 Taskconfiguration in Online Mode
- •6.8 Watch and Receipt Manager...
- •6.8.1 Overview
- •6.8.2 Watch and Receipt Manager in the Offline Mode
- •6.8.3 Watch and Receipt Manager in the Online Mode
- •6.9 The Sampling Trace
- •6.9.1 Overview and Configuration
- •6.9.2 Display of the Sampling Trace
- •6.9.3 'Extras' 'Save Trace'
- •6.9.4 'Extras' 'External Trace Configurations'
- •6.10 Workspace
- •6.11 Parameter Manager ..
- •6.11.1 Overview, Activating
- •6.11.2 The Parameter Manager Editor, Overview
- •6.11.3 Parameter List Types and Attributes
- •6.11.4 Managing parameter lists
- •6.11.5 Editing parameter lists
- •6.11.6 Parameter Manager in Online Mode
- •6.11.7 Export / Import of parameter lists
- •6.12 Target Settings
- •6.13 The PLC-Browser
- •6.14 Tools
- •6.14.1 Properties of available Tool Shortcuts (Object Properties)
- •6.14.2 Managing Tool Shortcuts
- •6.14.3 Frequently asked questions on Tools
- •7.1 What is ENI
- •7.2 Preconditions for Working with an ENI project data base
- •7.3 Working with the ENI project data base in CoDeSys
- •7.4 Object categories concerning the project data base
- •8 DDE Interface
- •8.1 DDE interface of the CoDeSys programming system...
- •8.2 DDE communcation with the GatewayDDE Server...
- •9 The License Management in CoDeSys
- •9.1 The License Manager
- •9.1.1 Creating a licensed library in CoDeSys
- •10 APPENDIX
- •Appendix A: IEC Operators and additional norm extending functions
- •Arithmetic Operators...
- •Bitstring Operators...
- •Selection Operators
- •Comparison Operators...
- •Address Operators...
- •Calling Operators...
- •Type Conversions...
- •Numeric Operators...
- •Appendix B: Operands in CoDeSys
- •Constants
- •Variables
- •Addresses
- •Functions
- •Appendix C: Data types in CoDeSys
- •Standard data types
- •Defined data types
- •Appendix D: The CoDeSys Libaries
- •The Standard.lib library
- •String functions...
- •Bistable Function Blocks...
- •Trigger...
- •Counter...
- •Timer...
- •The Util.lib library
- •BCD Conversion
- •Bit-/Byte Functions
- •Mathematic Auxiliary Functions
- •Controllers
- •Signal Generators...
- •Function Manipulators...
- •Analog Value Processing...
- •The AnalyzationNew.lib library
- •The CoDeSys System Libraries
- •Appendix E: Operators and Library Modules Overview
- •Appendix F: Command Line-/Command File
- •Command Line Commands
- •Command File (cmdfile) Commands
- •Appendix G: Siemens Import
- •Import from a SEQ Symbol File
- •Import from a S5 Project File
- •Converting S5 to IEC 61131-3
- •Appendix H: Target Settings in Detail
- •Settings in Category Target Platform
- •Appendix I: Use of Keyboard
- •Appendix J: Compiler Errors and Warnings
- •Warnings
- •Errors

The PLC-Browser
Attention !: Please be aware, that each modification of the predefined target configuration can cause severe changes in performance and behaviour of the target !
Press <Default> if you want to reset the target settings to the standard configuration given by the target file.
6.13The PLC-Browser
The PLC-Browser is a text-based control monitor (terminal). Commands for the request of specific information from the controller are entered in an entry line and sent as string to the controller. The returned response string is displayed in a result window of the browser. This functionality serves diagnosticand debugging purposes.
The commands available for the set target-system are made up of the CoDeSys standard set plus a possible extension set of the controller manufacturer. They are managed in an ini file and implemented accordingly in the runtime system.
6.13.1General remarks concerning PLC-Browser operation
Select the entry PLC-Browser in the Resources tab-control. It will be available there if it is activated in the current target settings (category networkfunctionality).
The CoDeSys PLC Browser window
The browser consists of a command entry line and a result/display window.
In a selection box the input line displays a list of all the commands entered since the start of the project (input history). They are available for re-selection until the project is closed. Only commands, which differ from those already existing, are added to the list.
The entered command is sent to the controller with <Enter>. If there is no Online connection, the command is displayed in the result window in the same way as it is sent to the controller, otherwise the response from the controller is shown there. If a new command is sent to the controller, the content of the result window is deleted.
Commands can be entered in the form of command strings , the use of macros is possible as well:
6.13.2Command entry in the PLC-Browser
Basically the PLC-Browser makes available the 3S standard commands hard-coded in the run-time system. It is concerned with functions for direct memory manipulation, for the output of projectand
6-68 |
CoDeSys V2.3 |
6 - The Resources
status functions as well as for run-time monitoring. They are described in the browser's ini-file, which is an integral part of the Target Support Package. These standard commands can be further supplemented by specialized ones, e.g. self-diagnostic functions or other status messages of the control application. The expansion of the command list must be carried out both in the customer interface in the run-time system as well as through additional entries in the Browser ini-file.
When opening the project the command list available in the PLC-Browser is generated based on the entries in the Browser ini-file. It can be accessed as input help using the ... key in the dialog „Insert standard command" or using <F2>. Also the command 'Insert' 'Standard commands' can be used to get the command list. A command can be typed in manually to the command line or it can be selected from the list by a double-click on the appropriate entry.
The general command syntax is: <KEYWORD><LEER><KEYWORD-DEPENDEND PARAMETERS>
The keyword is the command. With which parameters it can be expanded is described in the respective tooltip in the entry help window.
The command, which has been sent, is repeated in the output data window, the controller's response appears below it.
Example: Request for the project Id from the controller with the command "pid"
Entry in command line: pid.....
Output in result window:
pid
Project-ID: 16#0025CFDA
A help text can be supplied for each standard command with ?<BLANK><KEYWORD>. This is similarly defined in the ini-file.
The following commands are firmly integrated in the run-time system and contained in the ini-file with the corresponding entries for entry help, tooltips and help:
Command |
Description |
? |
The run-time system supplies a list of the available commands. The list is independent of the |
|
status of the description files of the target system. |
mem |
Hexdump of a memory area |
|
Syntax 1: mem <start address> <end address> |
|
Syntax 2: mem <start address>-<end address> |
|
Addresses can be entered decimal, hexadecimal (Prefix 16#) or as a macro. |
memc |
Hexdump relative to the start address of the code in the controller; like mem, the data are |
|
added to the code area |
memd |
Hexdump relative to the data base address in the controller; like mem, the data are added to |
|
the data area |
reflect |
Reflect current command line, for test purposes |
dpt |
Read data-pointer table |
ppt |
Read POU table |
pid |
Read project Id |
pinf |
Read project info |
tsk |
Show IEC-task list containing task infos. |
startprg |
Start PLC program |
stopprg |
Stop PLC program |
resetprg |
Reset PLC program. Only not-retentive data get initialized. |
resetprgcold |
Reset PLC program cold. Retentive data also get initialized. |
resetprgorg |
Reset PLC program original. The current application program as well as all data (incl. retentive |
|
and persistent) are deleted. |
reload |
Reload boot project |
getprgprop |
Program properties |
getprgstat |
Program status |
CoDeSys V2.3 |
6-69 |

|
The PLC-Browser |
filedir |
File command "dir" |
filecopy |
Copy file [from] [to] |
filerename |
Rename files [old] [new] |
filedelete |
Delete file [filename] |
saveretain |
Save retain variables |
restoreretain |
Load retain variables |
setpwd |
Set password on controller |
|
Syntax: setpwd <password> [level] |
|
<level> can be "0" (default) just valid concerning logins from the programming system, or "1" |
|
valid for all applications |
delpwd |
Delete password on controller |
Note: The first word of the command sequence entered is interpreted as keyword. If a keyword is preceded by a „<SPACE>?" (e.g. „mem ?"), the ini-file will be searched for the existence of a help section to this keyword. If one is available, nothing is sent to the controller, but only the help text is displayed in the output data window.
If the first word of the command entry (<KEYWORD>) is not recognized by the controller, the response 'Keyword not found' will appear in the result window.
6.13.3Use of macros during the command entry in PLC-Browser
If a command associated with a macro is entered in the command line, this is expanded before it is sent to the controller. Then the response in the result window appears in a similarly expanded form.
The entry syntax is: <KEYWORD><macro> <KEYWORD> is the command.
Macros are:
%P<NAME> If NAME is a POU-name, the expression is expanded to <POU-Index>, otherwise there is no alteration
%V<NAME> If NAME is a variable name, the expression is expanded to #<INDEX>:<OFFSET>, otherwise there is no alteration (this notation #<INDEX>:<OFFSET> is interpreted by the controller as a memory address)
%T<NAME> If NAME is a variable name, the expression is expanded to <VARIABLENTYP>, otherwise there is no alteration.
%S<NAME> If NAME is a variable name, the expression is expanded to <SIZEOF(VAR)>, otherwise there is no alteration.
The % character is ignored if the escape symbol \ (Backslash) is placed in front. The escape symbol as such is only transmitted if written \\.
Example:
Entry in command line: (memory dump of the variable .testit ?) mem %V.testit
Output in result window:
mem #4:52
03BAAA24 00 00 00 00 CD CD CD CD ....ÍÍÍÍ
6.13.4Further PLC-Browser options
In the 'Extras' menu or in the PLC-Browser's toolbar there are the following commands for handling the command entry or history list:
With History forward and History backward
you can scroll backwards and forwards through the query results already carried out. The history recording is continued until you leave the project. With Cancel command
you can break off a query which has been initiated.
6-70 |
CoDeSys V2.3 |