PID-Problem

Join Date
Jul 2010
Location
Hyderabad
Posts
2
Dear Friends,

I am working for the project having Allen-Bradley Contrologix system.We are using RSLogix 5000 programming software.I am facing a problem in creating the PID for a temperature control.We have 4-20mA input(temperature) which is a Process Value(PV).But the control valve which is to be controlled by the PID will not take 0-100%(4-20mA).It takes only Digital Outputs("Open" or "Close").I could not found any block in RSLogix 5000 for this type of PID output.Is there there any Add-On Block(to download) or any logic for this type of PID.Please help me.
 
What you are looking for is called time proportional control by allen bradley in their examples for the SLC-500.

I am sure it could be adapted for use in your system.

Basically, you take the CV output of your PID block, and scale that as a percentage of time that you want the digital output to be on.

For example, if your timebase is ten seconds, and the PID CV is at ten percent, then the output will be on for 1 second and off for 9 seconds.

Hope this helps.
Paul
 
Dear Paul

We have two digital outputs to be given to the valve.

One is open output (then it rotates in forward direction) and

another is close output (then it rotates in reverse direction).How can

we give open or close.You are saying only for one output.


SeshuChowdhary
 
Peter is the man to listen to when it comes to PID, sliding mode control, and motion control of all types.

I have used a "bidirectional" single PID to control a gas valve with 4-20mA and a cooling solenoid valve. It really needs two PIDs since the cooling and heating control characteristics, both lag time and ideal gains, are not linear, but using time proportional control with an output of +/-100% it was easy to code, and I simply adjusted the timebase for the liquid ammonia refrigerant valve to bend the line and get it to perform much better than the look up table it replaced.

I did this in a 5/02 with integer math and the SCL instruction which is kind of a pain, and I am saving what little memory is left for comms. It isn't perfect, but it met my specs, and exceeded the HAACP plan specs.

The positive half of the scaled output goes directly to a gas valve, and if it's above deadband I send an ignition command to the burner control relay. If it's below zero, I do a MUL/DIV including the sign change to end up with whole seconds, 1-10. I can keep room temperature within 2 degrees F of setpoint, with doors opening and closing all day, and a best case 6 minute lag time for cooling to a setpoint of 42 degrees. At night we switch to ouside air and exhaust the room as we heat it up to around 70 degrees during sanitation while they blast the room with tens of thousands of gallons of hot water. My method varies around 8 degrees F at night, which is, again, better than the lookup table which didn't deal with massive disturbances very well at would have the poor sanitation crew anywhere between 50 and 100 degrees, depending on the latest weather catastrophe to hit that week...

It sounds like what you're doing is positioning a valve or damper?


If so, then I would keep the PID analog, and model the position of the valve in the PLC, and drive it to position.

Most valve positioners or dampers I have worked on have a fixed rate of travel and at least offer end position limit switches. Sure, using a PLC timer to position a valve open loop is going to result in error, so passive home it when you hit an end limit or by operator intervention if the valve never fully opens or closes.

We should know the lag time of the control action among other basic details before I could go any farther.

I am speculating that Peter can offer you a much better for control method, perhaps sliding mode control may work better?

I am trying to think of what's simpler than time proportion PID that Peter is trying to educate us about.

Paul
 
Peter is the man to listen to when it comes to PID, sliding mode control, and motion control of all types.

I have used a "bidirectional" single PID to control a gas valve with 4-20mA and a cooling solenoid valve. It really needs two PIDs since the cooling and heating control characteristics, both lag time and ideal gains, are not linear, but using time proportional control with an output of +/-100% it was easy to code, and I simply adjusted the timebase for the liquid ammonia refrigerant valve to bend the line and get it to perform much better than the look up table it replaced.

I did this in a 5/02 with integer math and the SCL instruction which is kind of a pain, and I am saving what little memory is left for comms. It isn't perfect, but it met my specs, and exceeded the HAACP plan specs.

The positive half of the scaled output goes thru a SCL command to the gas valve positioner via a 1746-NO4I, and if it's above deadband I send an ignition command to the burner control relay. If it's below zero, I do a MUL/DIV including the sign change to end up with whole seconds, 1-10. I can keep room temperature within 2 degrees F of setpoint, with doors opening and closing all day, and a best case 6 minute lag time for cooling to a setpoint of 42 degrees. At night we switch to ouside air and exhaust the room as we heat it up to around 70 degrees during sanitation while they blast the room with tens of thousands of gallons of hot water. My method varies around 8 degrees F at night, which is, again, better than the lookup table which didn't deal with massive disturbances very well at would have the poor sanitation crew anywhere between 50 and 100 degrees, depending on the latest weather catastrophe to hit that week...

It sounds like what you're doing is positioning a valve or damper?


If so, then I would keep the PID analog, and model the position of the valve in the PLC, and drive it to position.

Most valve positioners or dampers I have worked on have a fixed rate of travel and at least offer end position limit switches. Sure, using a PLC timer to position a valve open loop is going to result in error, so passive home it when you hit an end limit or by operator intervention if the valve never fully opens or closes.

We should know the lag time of the control action among other basic details before I could go any farther.

I am speculating that Peter can offer you a much better for control method, perhaps sliding mode control may work better?

I am trying to think of what's simpler than time proportion PID that Peter is trying to educate us about.

Paul
 
Last edited:
Since no one seems to see the problem

The valve integrates the output.

A normal temperature system is type 0 or non-integrating. This means the if the output goes to 0 the temperature will go back to ambient. seshuchowdhary's system integrates the output so if the control output goes to 0 the valve will stay in position and the current temperature will be maintained and not drop back to ambient.

Pandiani has actually written a paper on this topic but couldn't get it published. In his plant they have what they call step controllers. These use PWM digital outputs like seshuchowdhary's does. A Siemens PLC uses PI control and the output goes to the step controller phase where the control output is converted to pulses. There is a trick though. If the controller has a PI control that introduces 90 degree of phase lag and the valve integrates and that adds another 90 degrees of phase lag. This causes a 180 degree phase lag which will be unstable. The step controller used an integrator in the feedback to correct the phase lag. This is not obvious but it is necessary and I feel not the simplest way to go.

I will let you guys think about this. Perhaps Pandiani will comment. Pandiani is the expert on these step controllers. I have a different plan that I think is MUCH simpler.
 
The OP is trying to drive an actuator motor, typically over a 90° stroke some period of time (typically 30S to a minute, stop to stop) These actuators are used to drive dampers or valves. Most acuators nowadays come with 4-20mA inputs and separate power wiring.

But the drive circuit on older actuator used a two separate contact closures supplying motor voltage to one of two coils, one drove clockwise, one drove counter clockwise.

Closed feedback control was achieved with a mechanical slidewire providing resistance feedback to the controller. The controller's PID determined where to drive the motor. That direction, relative to the current position determined close or open action. The resistance feedback determined when the motor had achieved its position, at which point the drive relays opened.

1z4hbwh.jpg


The Europeans invented open loop version of actuator control, which Honeywell calls "3 position step control", which does not use slidewire feedback. The motor's travel time, stop-to-stop is a known, either from decoding the model number or running the actuator stop-to-stop in the field and timing it with a stop watch. On power-up, the actuator is driven to a home position, then seeks the PID output value on a timed basis. For instance, on a 30 second motor, the run time to 50% output is 15 seconds.

At one point in 1990's Allen Bradley's process controller was a private labeled Honeywell, so there might be a 3 position step function block in the CLX.

An alternative, if there's a slidewire in the motor for position feedback, is to use a conventional 4-20mA output from the CLX PID to a converter module, like the one linked to at API below, which does the dual relay output drive based on the 4-20mA demand signal and the resistance feedback.
http://www.api-usa.com/pdf/api/api_3200g.pdf
 
Last edited:
The OP is trying to drive an actuator motor, typically over a 90° stroke some period of time (typically 30S to a minute, stop to stop)
I wondered when someone would bring that up. We still don't know the true value.

Closed feedback control was achieved with a mechanical slidewire providing resistance feedback to the controller.
seshuchowdhary hasn't mentioned any valve position feedback.


The controller's PID determined where to drive the motor.
In this case you don't know where to drive the motor, only that the valve must be opened or closed a little.
 
danw said:
The OP is trying to drive an actuator motor, typically over a 90° stroke some period of time (typically 30S to a minute, stop to stop) These actuators are used to drive dampers or valves. Most acuators nowadays come with 4-20mA inputs and separate power wiring.

I just removed one from a TRIAC controls valve and it's laying on my file cabinet. The job was spec'd by another person who only needed two position electric control, so I used the limit switches.

danw said:
The Europeans invented open loop version of actuator control, which Honeywell calls "3 position step control", which does not use slidewire feedback. The motor's travel time, stop-to-stop is a known, either from decoding the model number or running the actuator stop-to-stop in the field and timing it with a stop watch. On power-up, the actuator is driven to a home position, then seeks the PID output value on a timed basis. For instance, on a 30 second motor, the run time to 50% output is 15 seconds.

At one point in 1990's Allen Bradley's process controller was a private labeled Honeywell, so there might be a 3 position step function block in the CLX.

An alternative, if there's a slidewire in the motor for position feedback, is to use a conventional 4-20mA output from the CLX PID to a converter module, like the one linked to at API below, which does the dual relay output drive based on the 4-20mA demand signal and the resistance feedback.
http://www.api-usa.com/pdf/api/api_3200g.pdf

Even if you have to write the ladder logic to measure the travel time between limit switches, it's easier and cheaper than purchasing a purpose built positioner for your valve. All you need for this is a position limit switch and a way to measure travel time.

If you can get a positioner that accepts analog quickly added to the system, it would be less work for you, but not a whole lot.

Once you have a positioner, whether by ladder logic modelling based on rate of travel measurements as Dan's post eloquently describes, or whether you buy one, then you can use the PID as you'd expect.

I am not qualified to delve into the depths that Peter is going, so I'll humbly bow out now.

Good Luck,
Paul
 

Similar Topics

Dear all . I made a program for boiler tank using TIA V15 , the program consists of 2 PID blocks in OB30 . but the PID didn’t work automatically...
Replies
3
Views
2,679
Dear all . I made a program for boiler tank using TIA V15 , the program consists of 2 PID blocks in OB30 . but the PID didn’t work...
Replies
1
Views
1,134
Hello Friends; I am working on a GE Funac LM 90-30 software. I face the problem to set the CV value when PID in auto mode. The parameters are set...
Replies
13
Views
3,056
I had a problem on a hydraulic servo controlled cylinder, which I believe was caused by the PID loop and the cylinder reaching a hard stop at one...
Replies
10
Views
2,471
We have a machine we're trying to commission. It's a web converting machine. It takes webs of foil, wicking paper & a label and creates a chemical...
Replies
1
Views
1,313
Back
Top Bottom