USB Files manipulation

USB Files manipulation
none 0.0 0
  • HMI Model: cmt2078x
  • EasyBuilder Pro Version: 6.08
  • Serial Number or supplier:

Is there any way to delete a folder or multiple files from a USB drive connected on a cmt2078x?

From what I see the only way is to use the File Browser that doesn’t delete folders and the file needs to be deleted one by one. I have more than 1500 small pictures that needs to be erased periodically or my USB memory will get full in less than a day.

Deleting a folder from a USB drive can be accomplished using any FTP client software installed on a PC. Before doing this, you have to turn on a permission option called “FTP client can modify USB/SD data” on the HMI screen.

Hi @jdamas,

This question is a little complex, but the following workaround may work in this application:

  1. Within the “Data/History” tab create an FTP server object with invalid credentials:


    Example: I used these credentials while testing in our office.
    image

  2. Within the “Object” tab create an “Action Trigger (Global)” object:

  3. Configure the “Action Trigger (Global)” object’s “Mode” to “Value changed” and configure an appropriate trigger address and condition:
    image

  4. Within “Action Group 1” add a “File Transfer”:
    image

  5. Configure the transfer type to “Upload” and ensure that “Delete the source file after successful transfer” is enabled:
    image

  6. Within the “File” tab configure the path name of the folder that will hold the image files in your application:
    image

  7. Click “Ok” when finished.

During runtime, implement the trigger condition configured within step 3 and the HMI should delete the folder listed in step 6 and replace it with an empty folder. However, please note that this is a potential workaround. The “File Transfer” feature was not designed with this application in mind.