The GS20 drives have lots of PID options and features.
But that also means there are lots of additional parameters to wrap your head around and that
can make getting started with PID even more intimidating than usual.
So in this video series I’m going to show you how to filter out all the chaff and get
a simple PID application up and running quickly.
Our goal is to have the GS20 drive use PID to automatically maintain the pressure in
this system regardless of how many valves are open.
This GS20 drive is controlling this motor, which is pumping water to these manual butterfly
valves.
The tank drains to a reservoir
which feeds the pump through this check valve.
This 15psi pressure sensor sends a zero to 10-volt signal back to the drive so PID can
monitor the system pressure and adjust the motor speed accordingly.
I'm assuming you are familiar with the PID feedback process where you tell the drive you want
to be at some value we call the setpoint.
It monitors the system pressure via the process variable, takes the difference between the
two, and uses that error signal to figure out how to adjust the control output.
We can also bypass the PID calculations and manually drive the output which helps us test
the system.
This system is set up like this: we’ll enter the setpoint via the keypad and the zero to 10
volt process variable will come in on analog input 1.
We’ll set up the drive’s local mode configuration to just be a manually controlled drive where
we use the keypad's potentiometer to directly control the drive's output frequency and the
keypad run/stop to start and stop the motor.
We’ll use the remote mode configuration to run PID and we’ll use some external switches
to control the run/stop and if PID is automatically controlling the output or if we are manually
controlling the output.
And we’ll need an external switch to switch between local and remote modes.
Sounds like a lot doesn’t it?
It is, but, I have this cheat sheet that makes it super simple.
These are all the things we need to configure to make this happen.
The setpoint, the PID algorithm, the control output, and the process variable.
And of course, we need to configure the motor and the drive.
The good news is, everything in blue is a default value.
All we have to do is enter the values for the yellow squares and we are done!
Let’s walk through it.
For the setpoint, we just need to tell PID where to get it from.
I have little notes in each of these squares to remind me what all of the relevant options
are.
We want to enter the setpoint from the usual local or remote setup – which we will configure
down here in a minute – and that’s the default, so we don’t need to do anything
here.
For the PID portion, we are just going to start with the blue default values and tweak
them later.
In general, you’ll find these default values will be a great starting place for most industrial
applications.
Notice that the GS20 gives you a choice of TWO different PID algoritms.
In the DEPENDANT PID algorithm, changing P changes I and D. That simulates the old analog
systems where when you change the gain of the system you change everything else too.
In the Independent PID algorithm, P, I and D can be tuned independently without affecting
each other.
That makes it easier to tune because messing with one coefficient doesn’t change the
other two.
This is what you will find in most modern digital systems.
We’re going to use the default which is the dependent PID algorithm.
There’s a lot of options for manipulating the control output, I am just showing two
of them here.
By the way, you can see all the PID options we are not using down here.
Here are the other options for the control output for example.
We need to tell the drive the process variable is coming in on an analog input and configure
analog input 1 to do that.
I’m also going to add a small amount of filtering on that analog input.
You really want to keep filtering as small as possible – a large filter value will
slow down the response of the PID algorithm.
Let’s tell the user display to show us the Process variable.
And of course, we need to tell the drive what motor we are using.
Finally, we need to configure the drive.
We will be using the remote configuration for PID and we want the frequency source – which
will be our setpoint – to come from the keypad and run/stop to come from the digital
input.
I don’t want to use the potentiometer for my setpoint because someone might bump it
and mess it up.
This just says local mode runs local parameters, remote mode uses remote parameters.
In local mode, we’ll use the keypads potentiometer to control the frequency because it’s easy.
We’ll control the drive from the keypads run/stop button just to show you we don’t
have to use the external switch.
We’ll leave the max frequency at the default 60 hz, but I am going to change the min frequency
to zero to make our math easier – you’ll see why in part 2.
You want to keep the acceleration and deceleration as short as possible and let PID control how
fast the drive ramps up.
If you get over current faults, you can increase these to slow PID down if you need to.
Finally, we want digital inputs 1 and 2 to control run/stop and forward and reverse.
We’re not actually using the forward and reverse in this demo, so I don’t even have
it wired up.
It just comes along for the ride when you choose this option.
Digital input 3 will be our local remote selector and input 4 will select if PID automatically
controls the motor or if we manually control it the motor frequency.
Well, that’s it!.
Over here you will find a list of all of the relevant PID parameters in numerical order.
That makes them a lot easier to enter into the drive.
And look ... we didn’t change ANY of the blue default values for the PID parameters
– did we?
All we did was configure the motor, the drive and the I/O.
Not bad at all.
You can download a copy of this tool in the description below the video.
I went ahead and entered all of those parameters, wired everything up and got the pump primed.
We’ll be using the free GSOFT2 scope function to monitor the system and I added a digital
panel meter to monitor the output of the sensor because it automatically converts that 0 to
10 volt signal to psi for me.
So we said in LOCAL mode we want to be able to control the run/stop from the keypad,
yep that works – I see water squirting out the open nozzle - and we wanted to control
the frequency from the potentiometer.
Yep, that works too.
So how much frequency do I need to get my system to 6 psi?
Let’s tell GSOFT2 to show us the drive frequency and the analog input.
If I play with the potentiomter a bit it looks like around 40 hertz with one valve open will
get close to 6 psi.
On the scope we see the frequency in hertz and the analog input in percent.
Ok, if I open a valve we see the pressure drop.
So I’ll increase the frequency to get the pressure back to 6 psi.
Open another valve, pressure drops again.
I’ll raise the frequency again to get back to 6 psi.
Open the last valve, pressure drops so I raise the frequency to compensate.
And if I close the last three valves the system pressure goes way up, so I reduce the frequency
to get the system pressure back to 6 psi.
So the good news is our system IS capable of keeping the system at 6 psi regardless
of how many valves are open.
That’s important – if you can’t make the system do it manually, PID won’t be
able to do it either.
Now we just need PID to automatically change the motor speed when the pressure changes.
Join me in part 2 where we will flip over to REMOTE mode to turn PID on and play with
it for a while to get comfortable with how PID works in the GS20 drive.
Click here to see all of the GS20 variable frequency drive video tutorials.
Click here to subscribe to our YouTube channel so you will be notified when we publish new
videos like this and click here to learn about all of AutomationDirect’s free award-winning
support options.