Command: Check Memory for Active Application
Function: The command starts the memory check for the active application.
Call: menu
Requirement: The CODESYS Memory Tools package is installed. The application is in online mode.
The memory area of the active application is checked for the following:
The results of the check are displayed in the message view. Violations against the check criteria are listed as warnings.
Warning ID (if the check criterion is not fulfilled) | Check Criterion |
|---|---|
|
|
| Enumeration variables may only take on values which are defined in the enumeration. |
| Variables of a subrange type may only take on values within the subrange. |
| All strings must be terminated with zero. |
| Pointers must always point to addresses which have the correct alignment. Pointers must point to memory locations whose address is aligned to the type granularity, or is |
| Pointers must point to memory within the application. Function pointers in the project must point to memory managed by CODESYS Memory Tools. Function pointers to library POUs or external POUs are excluded because these could be in external memory. |
| Pointers must refer to variables of the correct type (for example, when a |
| Internal consistency of compiler structures Function pointer addresses must be internally consistent. |
| Internal consistency of compiler structures Interface variables and function table pointers must be internally consistent. |
| Internal consistency of compiler structures |
| The downloaded code must not have changed since the download. The code of compiled POUs must be unchanged. Note: Compiled POUs with breakpoints are excluded from the check because the code is manipulated for these at runtime. |
| The values of a constant must not have changed since the download. Variable of a constant block type ( |
| Internal consistency of compiler structures |
| Internal consistency of compiler structures |
Double-clicking a message opens the Memory view where the corresponding location is highlighted in orange.
The Memory view can also be opened by means of the View → Memory command.
The check can be limited by means of the 'memory_check' attribute.