Object: Recipe Manager
Tab: Storage
The recipe manager provides functions for maintaining user-defined variable lists, known as recipe definitions. The recipe definitions can be stored in "recipe files" on the PLC.
For more information, see: Using Recipes to Set Values
Storage Type | Textual: CODESYS saves the recipe in a readable format with the configured columns and delimiters. Binary: CODESYS saves the recipe in a non-readable binary format. This format requires less storage space. Note: You can read binary recipes again only if you have not changed the variable lists. |
File path |
Example: Path on the runtime system . Notes:
Example of the file path in the runtime system: CODESYS saves a file in this directory for each recipe when downloading to the PLC. The requirement is that you select the Recipe management in the PLC option. The files are loaded to the Recipe Manager each time the application is restarted. |
File extension | File extension for the recipe file in the format The resulting default name for recipe files is in the form: |
Separator | Separators between the individual values in the saved file |
Available Columns Selected Columns | Defines the information that is saved and in which order in the recipe file |
Save as Default | CODESYS uses the settings on the tab throughout the entire project for all other Recipe Managers. |
Tab: General
Recipe management in the PLC |
If you transfer recipes to the PLC exclusively via the CODESYS programming interface, then you can clear this option. |
Save recipe changes to recipe files automatically | When Recipe management in the PLC is selected, there is the following option to save the recipe:
The recipe files on the PLC are updated automatically at runtime whenever a recipe is changed. |
When Recipe management in the PLC is selected, there are the following two options for downloading from the PLC: | |
Download only for exact match of the variable list |
|
Download variables with matching names |
As a result, recipe files can also be downloaded if variables in the file or in the recipe definition have been deleted. |
Overwrite existing recipes on download |
Requirement: The Storage Type is Textual and the Save recipe changes to recipe files automatically option is selected. |
The following options are available for writing recipe values to the variables on the PLC: | |
Limit the variable to min/max when recipe value is out of the range |
|
Do not write to a variable when the recipe value is out of the min/max range |
|
The following option is available to read recipe values from the PLC into the recipe in the project: | |
Check recipe for changes | Always use the function block
The option can be used in order to update the recipe file in the local file system only if recipe values have changed on the PLC. However, it affects performance because it generates additional code for checking.
Note: As the file system is written to each call, the controller can be very burdened. |
Recipes during online mode
Menu Commands | Behavior of the recipes defined in the project | Behavior of the defined recipes at runtime |
---|---|---|
The recipes of all recipe definitions are downloaded with the values from the current projects. | Dynamically generated recipes remain unchanged. | |
The application is removed from the PLC. If a download is done again afterwards, then the recipes are restored as for an online reset warm. | ||
Shutdown and restart of the PLC | After a restart, the recipes are downloaded again from the automatically created files. This will restore the same state as before shutdown. | |
The recipe values remain unchanged. In runtime mode, a recipe can be changed only via the function block command | ||
The recipes remain unchanged when the PLC is stopped or started. |
Actions | Recipes defined in the project | Recipes defined at runtime |
---|---|---|
The recipes of all recipe definitions are downloaded with the values from the current projects. However, these are set in the memory only. To save recipes to a file, you need to run the Save Recipe command explicitly. | Dynamically generated recipes are lost. | |
The application is removed from the PLC. When a download is performed afterwards, the recipes are restored. | Dynamically generated recipes are lost. | |
Shutdown and restart of the PLC | After the restart, the recipes are downloaded again from the automatically created files. This will restore the same state as before shutdown. | |
The recipe values remain unchanged. In runtime mode, a recipe can be changed only via the function block command | ||
The recipes remain unchanged when the PLC is stopped or started. |