How to export a CODESYS recipe to a USB

How to export a CODESYS recipe to a USB
none 0.0 0

Is there a way to use Codesys Recipe Manager to save recipe files to USB stick plugged into HMI USB port for storage and retrieval?

Hi @vladmen,

As long as the CODESYS Recipe Manager is set to save files within the internal storage, you can use the “SysFileCopy” from the SysFile library to transfer this data to a USB as shown in the image below:

Here is the a demo project that can perform this operation: Link

I was planning to use File Browser tool on HMI to pick recipe files, but it only points to the USB storage, so I would not be able to use it to get file names from USB.
Looks like I cannot put a path pointing to USB storage into RecipeManCommands either.

Hi @vladmen,

Per my suggestion, please export the files within CODESYS’s internal storage then use the SysFileCopy function block from the SysFile library to move these files into USB memory. This will make the files accessible to the HMI’s File Browser.

However, depending on your use case, you may also be able to use other functions within the SysFile library to create blank files with the same file names as those in your CODESYS recipes.