Read online if a DST is assigned to a DC/IO_IN_x

Hi Forum,

I would like to create a function to automatic set the DC/STATE_MASKS.STATEINx fields of a dedicated input / output.

If that dedicated IO_IN_x input is not configured then the function shall set the STATE_MASKS input to ignore after a download.

Reference-parameter can check via the PARAMETER.$REF as string if there is any reference, #IGNORE or empty.

I don't know how to check this IO_IN_x / IO_OUT_x Parameters online within an action in that CM.

Thank You and Best Regards,

Michael

  • The .REF for IO_IN_x / IO_OUT_x (or any IO function block parameter) are not runtime parameters and can't be accessed with logic.

    Unfortunately,
    You will have to manually configure your state masks based on the IO that is configured OR
    You could probably do something in Bulk Edit to export, create some formulas to massage the data and reimport back into the system for existing system (do before you create module using Bulk Edit Excel Formulas for state mask or create Templates with different numbers of IO and state mask already set) OR
    You could create multiple module classes with the different state masks set and relink instances to the appropriate class (I very much dislike this option because if you ever have to make a change...you have to do it multiple times and I prefer the multiple Module Templates linked to a class with different state masks already defined)