Hello! I’m wondering how I can make in inverz control with the function block PID_C. I mean, at deafult, it is a “heater” control, as an example. if SP is higher than PV, the output climbs up to 100%. (e.g. opening a heater valve) I need also a “cooler” implementation. There is a DIRECTN (direction) switch in the FPID implementation, but I don’t find it in PID_C Thanks for the help.
Just off the top of my head - does a negative gain (P) value work in this case? (EDIT: or, you could try swapping the SP and PV variables … but that’s not a nice solution …) If not, I will check with the developers. ~ Martin.
Swapping PV and SP was also in my mind, I will try that as a workaround. With the Gain, I’m not sure, as it does not effect the Integral and Derivative part, so probably would give some strange result. Let me know if You have some feedback from developers. Thank You!
You may use wMode.X14 (YINV_ON), please refer for library doc for details.
YINV_ON is not inverted control. It’s inverted output. If SP < PV then rY is 0.0 So -1*rY is still 0.0, which should not be the case for an inverted control.
You have to specify the params e.g. like this:
=>