Proportional control calculation

Proportional control calculation

Postby 2lostkiwis » Thu Apr 12, 2012 8:57 am

Hi there,

I'm trying to tune the osPID to control a small electric jewelers furnace. Everything's going fine electrically, I can control the osPID using the front end. To start with I thought I would just implement a proportional only controller, I used the following settings:
kp=2.0, ki=0.0, kd=0.0

The strange thing, is that the output appears to be at 50% when the input is at the set point. I would have thought at this point the error term would have been zero, so that the output should also have been 0% not the 50% I was getting.

Does anyone have any ideas? I have attached a screen shot showing what I think it's the problem.

Kind regards,
Ian.

Screen Shot 2012-04-12 at 8.41.26 PM.png
Screen Shot 2012-04-12 at 8.41.26 PM.png (38.63 KiB) Viewed 1650 times
2lostkiwis
 
Posts: 5
Joined: Thu Apr 12, 2012 8:50 am

Re: Proportional control calculation

Postby Brett » Sun Apr 15, 2012 4:11 pm

Hi Ian, when the pid is turned on (Manual -> Automatic) the current value of the Output is remembered as the baseline value. moving forward all output corrections are based off this value. so in your trend, you started pid with an output of 50. when the input crosses setpoint the proportional term is indeed 0, as you expected, it's just being added to this starting value.

this is standard pid behavior, and it exists to allow for a "bumpless transfer" from manual to automatic.
User avatar
Brett
Site Admin
 
Posts: 84
Joined: Fri Mar 09, 2012 10:05 pm
Location: Boston

Re: Proportional control calculation

Postby 2lostkiwis » Mon Apr 16, 2012 12:14 am

Brett wrote:Hi Ian, when the pid is turned on (Manual -> Automatic) the current value of the Output is remembered as the baseline value. moving forward all output corrections are based off this value. so in your trend, you started pid with an output of 50. when the input crosses setpoint the proportional term is indeed 0, as you expected, it's just being added to this starting value.

this is standard pid behavior, and it exist to allow for a "bumpless transfer" from manual to automatic.


Many thanks Brett, you're totally correct. It's been a long time since I was at Uni so I was relying on the distant past in my mind. If I start with an output of 0% before switching to automatic everything is great.

Kind regards,
Ian.
2lostkiwis
 
Posts: 5
Joined: Thu Apr 12, 2012 8:50 am


Return to PID Control / Tuning

Who is online

Users browsing this forum: No registered users and 1 guest