AI Fault, OUT.CV value problem

 I would like to have a fail over value go into a PID block. As soon as I pull the fuse the value freezes and any downstream blocks dont see the value (PID and CMP block no longer work) . Also the Bad_Active and the Block_ERR both just go to "Non-Zero instead of some sort of value that I can use to send or activate the select block. 

Further the value freezes for sending via modbus so I have no way of alerting the PLC of the Transmitter failure. Any help would be appreciated. 

  • Instead of using outputs from blocks directly, I suggest to use a CALC block and add specific logic to handle this issue. The CALC block can evaluate the status parameter of a value or variable and execute specific logic to send whatever value you want to the PLC. The CALC block could replace the CMP and XFR block in your structure as well and perform their function.

    In order to use the BAD_ACTIVE parameter of the AI block, you would have to set the BAD_MASK parameter of the AI block during configuration. I imagine that the "Input Failure/Bad PV" option in BAD_MASK would apply to a failed CHARM input. BAD_ACTIVE would still not be a TRUE or FALSE expression. It would have to be evaluated with logic (in a CALC block).

    Within the CALC block, you can check the status of the OUT parameter with IF ... THEN and execute accordingly.

    Here is a simple CALC expression to start with (assumption: AI2/OUT is connected to CALC1/IN1, PI6800 is connected to CALC1/IN2, FAULT (-5) is connected to CALC1/IN3, CALC1/OUT1 is connected to PID1/IN, CALC1/OUT2 is connected to TEST_TO_PLC) :

    IF ('IN1.ST' < 128) OR ('IN1.CV' < 'IN3.CV') THEN
        'OUT1.CV' := 'IN2.CV';
        'OUT1.ST' := 'IN2.ST';
        'OUT2.CV' := 'IN2.CV';
        'OUT2.ST' := 'IN2.ST';
    ELSE
        'OUT1.CV' := 'IN1.CV';
        'OUT1.ST' := 'IN1.ST';
        'OUT2.CV' := 'IN1.CV';
        'OUT2.ST' := 'IN1.ST';
    END_IF;

  • In reply to fkitzmann:

    Going through a CALC block as you suggested works perfectly! I am just in the final stage of testing everything. Thank you so much for taking the time to give me the solution.
  • In reply to Peter Horrelt:

    Warning: If the PID block is locked to a fixed value with a GOOD status, it may saturate as the PV-SP ERROR will be fixed. This is why Status is used by the PID to Shed Mode and prevent an unwanted process disturbance. The PID block did not stop working, but rather stopped any automatic action caused by a bad signa.

    It looks like your goal is to drive a negative value (-5) as the new PV to the PID, which along with a GOOD status would cause the PID to bump its output and integrate to a limit based on the PID Direction setting, either closing or opening the valve. The PID Tuning will determine the profile of the output movement, all the while leaving the PID in AUTO and masking any error from the failed Input, except via the Block Error mechanism.

    Another way might be to use the PID TRACK feature to explicitly drive the PID/OUT parameter to the desired location. An expression of (AI/OUT.ST < Good) could set TRACK_IN and TRAC_VAL set to 0 and the PID/OUT goes to 0 on loss of the AI. Using a CALC Block, you could ramp the TRACK VAL so that you define the profile of the OUT signal under this fault condition.

    If shifting the PV to -5 with GOOD status is what you want, you could use the XFER block. Use a CND block to detect the non-Good Status and connect this to the Selector of the XFER. In2 has the -5 value with Good status and In1 has the AI/Out.

    This would give you a clearer diagram view of the logic.

    Andre Dicaire

  • Whenever the block error is selected, the blocks having bad active or fault these will active both flags of bad_active block_error. PID have property whenever the status of the tag is bad(i.e fault or open connection) the bad_active for particular PID will activate and try to move your process on safe state which may be freeze as per your selected option.
    In fault case the option of freeze in last state hold the last value with bad status. If you want to send the failure status to PLC please write a code in Calca block where the transmitter signal health is checked as per status and generate a bit so you can find out that particular signal is faulty and we are getting false data.
    But if you want to send the data manually ( you know that transmitter is faulty and want to operate PID out put), directly force the AO associated with PID or force AI with simulate to send the good health signal on Modbus(temporary).
  • In reply to Andre Dicaire:

    Hello Andre thank you for taking the time to answer. Forgive me, i did not explain the goal correctly. In the event that the original control transmitter fails (kpa < -5) I want to use the pressure from PI6800 as the PV (PI6800 is the shutdown TX on the same chunk of pipe) Using the CALC block as suggested allows this to work. Rest assured I still get the Fault alarm and have an additional Differential alarm if the 2 transmitters are more than 200 kpa apart.
  • In reply to Yawar Khan:

    Thank you for taking time Yawar, I really do appreciate the solutions that come from this forum! As mentioned, i did not explain the goal correctly and want to use an alternate PV until the original transmitter is back in service. Work was successful filtering the AI through the CALC block.
  • In reply to Peter Horrelt:

    The Input selector block provides First good or Hot back up selection of up to four inputs.

    Andre Dicaire