Eclectic71 (Customer) asked a question.

How do I make sure that my PID is always in Auto Mode and the set-point is always "120".

I wrote a quick subroutine using a Set Coil that should have always set that particular bit, in my case C317, and should have made sure that it was always set. But when I run the program it doesn't show that it is doing anything in monitor mode. So I tried it a different way using an Out Coil but that also doesn't seem to be working either. Is there another way to do this or is it not possible to change this because it is reserved to the PID?

For the set-point I just added a math function to always set the DF register, DF201 in my case, to 120 and it seems to be working.

 

I appreciate any assistance, thank you.

 

image


  • Todd Dice (Customer)

    Do you have C317 in a reset instruction in the program somewhere else and it is currently true?

  • Eclectic71 (Customer)

    No. As you can see from the Cross Reference View below, the only places it is used is in the PID and the subroutine I wrote.

     

    image

  • Eclectic71 (Customer)

    Those are the bits that tell the device whether it is in auto or manual mode. I use them to enable a bit state, call a subroutine for every scan, call a subroutine that would be in auto or manual mode. In this case it's a subroutine that would be called on every scan to ensure the PID doesn't go out of auto and the set point doesn't change.

    In the example below,

    On rung 1 those bits keep the Display Trigger set so that several things are displayed continuously on the HMI.

    On rungs 2 and 3 those bits make sure that the PIDPresets and the MFCControl subroutines are called on every scan.

    On rung 4 they also make sure another bit I use is always set.

    On rung 5 the make sure a math function runs on every scan feeding a combined base number and user input number to a timer.

    On rung 6 they are used to reset my digital outputs for my levels,

    From rung 7 on they are mostly used to determine, along with level bits, which particular subroutine will be used to run based on user input.

    image

    Expand Post
  • ADC Community_04 (AutomationDirect)

    Take a look at this timing chart from Help topic CL246.

    https://cdn.automationdirect.com/static/helpfiles/click/Click_Help.htm#246.htm?TocPath=Main%2520Menu%257CSetup%2520Menu%257CPID%2520Setup%257C_____1

    imageThe Auto Mode request bit is turned off by the PLC when PID is in Auto mode. You typically would never even see the request bit turn on. You should view the PID mode indicator bits to verify what mode PID is in. If your Auto Mode request bit is at C317, you should look at C326 (Manual Mode Indication) and C327 (Auto Mode Indication). If the Auto Mode Indication bit is on, PID is in Auto Mode and you will not see the request bit on.

     

    To test if the request bit is working as desired, you could place the PLC into Stop and then back into Run and view C326 and C327. Normally, PID will be placed into Manual mode upon a Stop to Run transition. If yours goes into Auto mode, your logic is working.

     

    Expand Post
  • Eclectic71 (Customer)

    Ahhh, so it is working, just too fast for me to see it. I tried your suggested test and it seems to have worked. Thank you for the help Todd and ADC, I appreciate it!