Micro800 PID question

I did not do any reverse engineering of the IPIDCONTROLLER or GAIN_PID, so I cannot say anything about the parameters in the GAIN_PID object.
Ok, I've got it. I did that conclusion that you can help me sort out this from your earlier posts where you're talking about IPIDCONTROLLER.

First of all, @Peter and others have warned/mentioned that the parameters from the Cohen & Coon (1953) paper are quarter-wave damping; there is no guarantee that is acceptable for your process, so consider any coefficients derived from that paper to be a starting point at best; if anything maybe set the parameters a bit less aggressively if this will be controlling the actual process.
This is my first project where I have to set up a PID controller from scratch and I don't have such theoretical background as you. This is the reason why I'm asking about it on the Internet. I've found in wide public access only C-C methodology with practical examples of how to commissioning a PID from scratch. Any others were only theory without practice implementation.

Second of all, I am not going to do the work for you, at least not without a purchase order, and in that case you should get someone else for whom this is not a hobby.
I didn't ask you to tune my PID, I just ask about any other equations that differ from C-C. If it cost so much money I'll prefer to buy TechConnect agreement instead of such "help".
 
I didn't ask you to tune my PID, ...

Really? Then what was this asking me to do:

Originally Posted by Yashka And I would be very appreciative if you could say me appropriate corresponded Cohen-Coon coefficients.
Hmm, that sounds a lot like you are asking someone to tune your PID.

... I just ask about any other equations that differ from C-C. If it cost so much money I'll prefer to buy TechConnect agreement instead of such "help".

Google "how to tune PID"

Even if you search for "cohen coon," you will find a lot of results that compare cohen-coon tuning to other methods (Ziegler-Nichols, etc.).
 
@drbitboy. On post #41 there are two sets of C-C gains. Did you notice they are different? The C-C paper was generated in 1953?



The C-C paper acknowledges that C-C tuning only works for FOPDT systems although they didn't use term first order plus dead time.


After all this time we still don't know what kind of system Yashka is trying to control.


Z-N and C-C should be scrubbed from all books and the internet. There are better methods that respond quicker and have little or no over shoot. This saves money in the long run.
 
@drbitboy. On post #41 there are two sets of C-C gains. Did you notice they are different? The C-C paper was generated in 1953?

Actually three sets, and when I wrote that are equivalent, I should have qualified that with "to within a few percent." I went over most of them by eye i.e. to the nearest digit and a half, and I did not see any significant differences*. To be fair I am getting prone to mental math errors when I try to move too quickly (just missed running into the closed half of a gate on bike ride along the Erie Canal today; phew!).

* e.g. For υ2,
  • C-C (1953): υ2 = 1.03 + 0.35μ
  • An image seen in two random YouTubes: υ2 = 1 + 0.3333μ
  • Image from Opticontrols.com website: υ2 = 1.03 + 0.352μ
So yes, they are different, but not enough to be bothered about in the current context.

he C-C paper acknowledges that C-C tuning only works for FOPDT systems although they didn't use term first order plus dead time.


After all this time we still don't know what kind of system Yashka is trying to control.


Which is to say it is identical to just about every other thread on the forum LOL.

Z-N and C-C should be scrubbed from all books and the internet. There are better methods that respond quicker and have little or no over shoot. This saves money in the long run.

That can be true for someone seeking to squeeze every nickel out of their process, for which they have three or four digits of accuracy and precision in the measurement. But perfect can be the enemy of good enough.

However, as you note we know virtually nothing about the OP's process for this thread, and for many processes, the difference between Z-N/C-C-derived results and those of better methods is down in the noise and therefore not worth the time. As you say, and as my brother reminded me last night, the job is often more about business i.e. value, than engineering.

As an example, say we are doing a commissioning and need to get a control loop working to start up the plant and make product. Is it better to

  • have Paul apply Z-N, get it "close enough" now, and move to the next thing to get the plant started sooner, and then have Peter come in later to optimize the tuning later
  • OR
  • have Peter spend the time now to optimize the tuning, but have that delay the eventual startup?
Of course, if the better tuning can be done quickly then of course it would be better to do it that way, but one of the benefits of Z-N is someone can memorize the approach and learn when it is useful, and more importantly when it is not.
 
Last edited:
Actually three sets, and when I wrote that are equivalent, I should have qualified that with "to within a few percent." I went over most of them by eye i.e. to the nearest digit and a half, and I did not see any significant differences*. To be fair I am getting prone to mental math errors when I try to move too quickly (just missed running into the closed half of a gate on bike ride along the Erie Canal today; phew!).

* e.g. For υ2,
  • C-C (1953): υ2 = 1.03 + 0.35μ
  • An image seen in two random YouTubes: υ2 = 1 + 0.3333μ
  • Image from Opticontrols.com website: υ2 = 1.03 + 0.352μ
So yes, they are different, but not enough to be bothered about in the current context.




Which is to say it is identical to just about every other thread on the forum LOL.



That can be true for someone seeking to squeeze every nickel out of their process, for which they have three or four digits of accuracy and precision in the measurement. But perfect can be the enemy of good enough.

However, as you note we know virtually nothing about the OP's process for this thread, and for many processes, the difference between Z-N/C-C-derived results and those of better methods is down in the noise and therefore not worth the time. As you say, and as my brother reminded me last night, the job is often more about business i.e. value, than engineering.

As an example, say we are doing a commissioning and need to get a control loop working to start up the plant and make product. Is it better to

  • have Paul apply Z-N, get it "close enough" now, and move to the next thing to get the plant started sooner, and then have Peter come in later to optimize the tuning later
  • OR
  • have Peter spend the time now to optimize the tuning, but have that delay the eventual startup?
Of course, if the better tuning can be done quickly then of course it would be better to do it that way, but one of the benefits of Z-N is someone can memorize the approach and learn when it is useful, and more importantly when it is not.
Some tuning formulas are better than others but take the same inputs and time to calculate.
There are better formulas on the www.controlguru.com site.
I know how they are derived and they are valid unlike the fudged formulas of Z-N and C-C that appear to work. The formulas on www.controlguru.com will not over shoot much if at all. The ones for FOPDT are simpler than the Z-N and C-C to implement and more accurate and they are also mathematically sound.



It doesn't take that long to calculate optimum gains when you already have it done in Mathcad, python, or even a spread sheet.
 
I think you should make it clearer that Rockwell's documentation and implementation is wrong and here is the proof by doing black box test.
The problem is that in the past it has always been operator error so claiming you have proof is more of a in your face claim.
Now will anyone from Rockwell do anything about it?
Probably not. Changing how the PID works would screw up a lot of people that replace an old Micro800 with a new and improved one. The problem is that most people are clueless and just fumble around with numbers until it appears to work without understanding enough to ask questions like you did.
 
Hey Peter, thanks for the suggestion, I added a second post with more detail; let me know if it should be more "in their face."

...
Now will anyone from Rockwell do anything about it?
Probably not. Changing how the PID works would screw up a lot of people that replace an old Micro800 ...

That is exactly the comment my daughter made when I was regaling her with tales of the journey: backwards compatibility, or lack thereof, has serious consequences.

She suggested that the IPIDCONTROLLER instruction, on paper offering little more than duplicate functionality to the broken PID instruction in the Micro800 line, may have been the Rockwell response, complete with a separate GAIN_PID input object, so there would be at least one working PID that could be properly documented.
 
This URL: https://github.com/drbitboy/CCW_Micro8xx_PID_reverse_engineering/tree/main/CCWcode. contains a CCW project that has a PID-controlled FOPDT process model using a 2048-element REAL FIFO array for dead-time and with a decay rate of 0.001 per scan.

TL;DR

The process model runs in a continuous task; on my Micro820, scan time is about 3.5ms, so the dead-time is ~7s, and the First-Order time constant is ~3.5s.

  • The PID runs at 1Hz via 1000ms interrupts
  • the PID's output CV feeds the input of the 2048-element FIFO
  • the FIFO output goes into a 100-element FIFO and is summed
  • that sum is scaled and offset,
  • the scaled and offset sum is run through a First-Order exponential filter to become the output of the Process Model and the PV of the PID.
With the default scale and offset of 1.0 and 0.0, respectively, the process gain is 100 (from the sum of the 100-element FIFO).
xxx.png
The following list is an example of how to calculate Cohen-Coon (1953) PID parameters for the process described above, and enter them into the CCW/Micro8xx PID instruction.

  • L = dead-period lag = deadtime = θ = 7s
  • Z = process time constant = τ = 3.5s
  • M = process sensitivity = K = ∆PV/∆CV at steady state after CV disturbance = 1000/10 = K = 100
  • μ = RL/M = L/Z = θ/τ = μ = 2
  • PID tuning
    • υ2 = 1.35 + 0.25μ = υ2 = 1.85
    • υ1 = 0.54 + 0.33μ = υ1 = 1.20
    • υ3 = 0.5
  • S = Controller proportional sensitivity = υ2/(RL) = Kc = ∆CV/∆Error = υ2/((K(θ/τ)) = 1.85 / (100 * 2) = Kc = 9.25e-3
  • U = Reset rate = υ1/(Lυ2) = 1/Ti
    • Ti = 1/U = integral time = Lυ2/υ1 = θυ2/υ1 = 7 * 1.85 / 1.20 = Ti = 10.79s
  • T = derivative time = Lυ3/υ2 = Td = CCW/Micro800 PID_GAINS.FC ;) = θυ3/υ2 = 7 * 0.5 / 1.2 = Td (i.e. .FC) = 2.92s
The image below shows typical performance using these parameters over several minutes with three separate manually-induced events with responses by the PID; reducing the Kc by a ~45% reduces the cycling and overshoot considerably, but it is still slow to settle. The output CV filtering parameter has been set small (pidgains.Td/pidgains.FC = [1e-3/2.92] seconds), so with the 1s update time there is essentially no output filtering.

The response time could almost certainly be improved by following @Peter Nachtwey's recommendations.


yyy.png
 

Similar Topics

So I am using a Micro850 and I downloaded the RA_PID UDFB for tuning the temperature of my Thermocouples(TC). I am not sure if I am using enough...
Replies
0
Views
1,427
Can someone tell me what i am doing wrong here? I have set the limits of the CV value for 5min and 60max. The output of the PID is not staying...
Replies
1
Views
1,591
Hi there, I have a small heating system with a micro 830 PLC to assist with the learning process of automation and PLC's etc. The system is a...
Replies
11
Views
8,300
My company built a small test machine using a Micro800 PLC and CCW software. We chose the Micro800 because the machine is very simple. We are...
Replies
2
Views
140
Back
Top Bottom