Вы находитесь на странице: 1из 32

TM481

Valve-based Hydraulic Drives


Prerequisites and requirements
Training modules TM210 The Basics of Automation Studio
TM480 The Basics of Hydraulics
Software AS 3.0.90 or higher
Hardware ---

2 TM481 - Valve-based Hydraulic Drives


Table of contents

TABLE OF CONTENTS

1 INTRODUCTION.................................................................................................................................. 4
1.1 Training module objectives..................................................................................................... 4
2 THE CONCEPT OF VALVE-BASED HYDRAULIC DRIVE CONTROL............................................... 5
2.1 Control tasks........................................................................................................................... 5
2.2 The AsHydCon library for valve-based hydraulics..................................................................6
2.3 AsHydCon example packages................................................................................................7
3 SIMPLE POSITIONING........................................................................................................................8
3.1 The control loop...................................................................................................................... 8
3.2 HCRSPF()............................................................................................................................... 8
3.3 HCRs_Cont()........................................................................................................................... 9
3.4 HCRLinValve().........................................................................................................................9
3.5 Simple positioning exercise.................................................................................................. 10
4 POSITIONING WITH SERVO CORRECTION (OPTIONAL)............................................................. 13
4.1 Servo correction.................................................................................................................... 13
4.2 Servo correction exercise..................................................................................................... 16
5 ALTERNATING POSITIONING AND FORCE CONTROL................................................................ 18
5.1 The principle of alternating control....................................................................................... 18
5.2 Exercise.................................................................................................................................19
6 SELECTING THE RIGHT FUNCTION BLOCKS............................................................................... 21

7 PROJECT DEVELOPMENT.............................................................................................................. 22
7.1 Helpful information regarding project preparation.................................................................22
7.2 Commissioning guidelines.................................................................................................... 25

TM481 - Valve-based Hydraulic Drives 3


Introduction

1 INTRODUCTION

The TM481 training module deals with the topic of controlling hydraulic cylinders by actuating hydraulic
valves. It will also present sample solutions programmed using the AsHydCon library. To improve com-
prehension, each control loop with be implemented and analyzed directly in Automation Studio.

1.1 Training module objectives

This training module uses selected examples and exercises to help you learn about how to implement
control loops with valve-based hydraulic drives.

You will learn about the structure of the AsHydCon library.


You will learn how to use the function blocks in the AsHydCon library.
You will learn the function blocks' most important parameters and what they do.
You will learn the most important machine parameters needed to configure the function blocks.
You will learn how to develop and commission simple positioning tasks for hydraulic axes.
You will learn about alternating position and force control applications.

4 TM481 - Valve-based Hydraulic Drives


The concept of valve-based hydraulic drive control

2 THE CONCEPT OF VALVE-BASED HYDRAULIC DRIVE CONTROL

The following section will present a closed loop control concept for hydraulic drives. We will start out by
taking a look at the hardware configuration. Then we will work through the closed loop control strategies
implemented in the AsHydCon library in Automation Studio.

B&R's approach to controlling hydraulic drives is


built on products from their standard product range
rather than specialized modules. Control algo-
rithms are executed directly on the CPU. A wide
range of CPUs (e.g. Power Panel, X20 CPU, APC)
allows users to get the exact level of performance
they need, as determined by the number of hy-
draulic axes and the desired cycle and response
times. The following image shows a sample con-
figuration with an X20 system as the CPU.

Sensors for position, pressure, force and flow rate are integrated using appropriate input modules (in
this example, the current position is read using an X20 encoder module). Manipulated variables for valve
positions are transferred to the valves via analog output modules that, like the input modules, are also
connected via X2X.

Valve-based hydraulic control is computed as soft-


ware on the controller. As a result, the software
control loop can be put together easily and flexi-
bly using a building block system. The image to
the right depicts a control loop for positioning that
uses profile generator, control and valve lineariza-
tion function blocks. In this example, the function
blocks from the AsHydCon library are executed on
the X20 CPU.

2.1 Control tasks

Valve-based hydraulic control tasks generally involve the following elements:


Position control with or without a profile generator
Speed control
Force/Pressure control

TM481 - Valve-based Hydraulic Drives 5


The concept of valve-based hydraulic drive control

2.2 The AsHydCon library for valve-based hydraulics

The AsHydCon library offers function blocks in the following categories to help create optimal solutions for the
valve-based hydraulics applications listed above.

Figure 1: Categories of function blocks included in the AsHydCon library

Selecting a control function block is an especially important decision when designing a control loop. The
AsHydCon library offers several different control blocks to best cover the wide range of applications for
control loops. The following table provides an overview of the different types of closed-loop control:

Position Speed Force/Pres-


Control block Description
sure
HCRPID General hydraulic control

Simple positioning without a profile


HCRP2P_Cont
generator

HCRs_Cont Positioning with a profile generator

Positioning with a profile generator


HCRs_Cont_p
and cylinder pressures

HCRF_Cont Force controller

Force controller with cylinder pres-


HCRF_Cont_p
sures

HCRsF_Cont Position and force controller

Position and force controller with


HCRsF_Cont_p
cylinder pressures

6 TM481 - Valve-based Hydraulic Drives


The concept of valve-based hydraulic drive control

2.3 AsHydCon example packages

The Automation Studio online help includes example packages based on the AsHydCon hydraulic control
library that can be used as templates for typical applications.

In many cases, the programs included in these packages can be used as-is to control hydraulic axes;
the only preparation necessary is to adjust the parameters for the particular application. The following
table lists the available packages and the sensors used by the control application in each case.

AsHydCon ex-
Function blocks used Sensors Function
ample package
Lib_AsHydCon1 HCRp2PCont() Cylinder position Simple positioning
HCRSPF() Dynamic positioning with a
Lib_AsHydCon2 Cylinder position
HCRs_Cont() profile generator
Cylinder position
HCRSPF() Dynamic positioning with a
Lib_AsHydCon3 Cylinder pressure
HCRs_Cont_p() profile generator
System pressure
HCRSPF() Cylinder position Alternating positioning and
Lib_AsHydCon4 HCRRampGen() Cylinder pressure force control with profile gen-
HCRsF_Cont_p() System pressure erators

The packages above are numbered according to the complexity of the control applications they contain.
Higher numbers indicate more complex control but also increased control quality, as long as the control
parameters are tuned for the application.
The first package uses very little data about the hydraulic system in order to minimize the time and cost
of implementation. Subsequent packages utilize increasing amounts of system data in order to provide
higher levels of dynamics and precision.

Before using any of the example packages, it is a good idea to first read the documentation
contained in the "Doc" folder to become more familiar with the structure of the program and
how it works.

TM481 - Valve-based Hydraulic Drives 7


Simple positioning

3 SIMPLE POSITIONING

This section provides information about the simple positioning of hydraulic cylinders. The first thing cov-
ered is the control loop itself. We will then take a look at the individual components of a control loop
(function blocks). At the end of this section, we will work with one of the examples to implement the
positioning task and test it using simulation.

3.1 The control loop

Two control function blocks are provided for simple positioning, HCRP2P_Cont() and HCRs_Cont().

The HCRP2P_Cont() block is used to move from the current position of a hydraulic drive to a specified
target position as quickly as possible (within the limitations of the settings).

Doing so usually requires movement profiles, however, which are subject to predefined limitations with
regard to maximum acceleration and/or jolt as well as maximum speed. In this case, the AsHydCon
library provides the HCRSPF() block to create a movement profile with the required corresponding char-
acteristics. It is also possible to use other profile generators, for example from an electrical axis. The
movement profile is then implemented using the HCRs_Cont() control function block. This manipulated
variable is then readied for the valve in the HCRLinValve() function block (compensation of the static
valve characteristic curve).

3.2 HCRSPF()

The HCRSPF() function block allows you to generate a movement profile (starting from the current
position) which can be defined by specifying the target position and a maximum speed, acceleration
and deceleration.

Keep in mind that control is not yet active since the movement profile created by the movement
profile generator represents a position setpoint curve. Nevertheless, take the characteristics of
the hydraulic drive into consideration when configuring this setpoint profile.

This type of cyclic movement profile occurs in almost all machine-related tasks since recurring tasks are
most often handled by the drive.

8 TM481 - Valve-based Hydraulic Drives


Simple positioning

3.3 HCRs_Cont()

The HCRs_Cont() function block is a controller optimized for valve-based hydraulics. It can be used for
flexible positioning with the aid of a profile generator such as the HCRSPF() function block.

The HCRs_Cont() function block block includes two components, a PID controller and servo correction.
The servo correction mode vyServoMode can be configured to adapt flexibly to known machine para-
meters. More information about using servo correction can be found in the next section.

In the simplest case, the HCRs_Cont() function block is operated as a pure PID controller. Servo cor-
rection is disabled by setting vyServoMode = 0x08. In this mode, only the PID parameters pPID_Para_s
have to be configured. The position setpoint s_set and s_act are the only cyclic inputs. The manipulated
variable (a valve opening) is connected to the yValve output. This variable's default range is {-1..+1}.

Changes to the parameter structure and the servo correction mode do not take effect until the
function block is enabled or there is a rising edge at the update input.

3.4 HCRLinValve()

The HCRLinValve() function block allows static linearization of valves. This can be used to compensate
static valve characteristic curves, which are usually non-linear. The HCRLinValve function block converts
a given valve opening to the necessary valve voltage.

For this conversion, the static characteristic curve of the valve is needed. This is specified in the form
of coordinates. Areas between the coordinates are calculated using linear interpolation. The inverted
valve characteristic curve is calculated in the function block when it is enabled and at every update.
The inverted valve characteristic curve is used by the HCRLinValve() function block to calculate a valve
voltage for the desired valve opening.

HCRLinValve() Nonlinear valve Resulting (linear)


characteristic
10 100 100
8 80 80
Reference signal [volts]

6 60 60
Nominal flow [%]
Nominal flow [%]

4 40 40
2 20 20
-10 V
-8 V
-6 V
-4 V
-2 V
-1.0
-0.8
-0.6
-0.4
-0.2

-1.0
-0.8
-0.6
-0.4
-0.2

0 0 0
2V
4V
6V
8V
10 V
0.2
0.4
0.6
0.8
1.0

0.2
0.4
0.6
0.8
1.0

-2 -20 -20
-4 -40 -40
-6 -60 -60
-8 -80 -80
-10 -100 -100
Controller output [-1..1] Reference signal [volts] Controller output [-1..1]

TM481 - Valve-based Hydraulic Drives 9


Simple positioning

3.5 Simple positioning exercise

The exercise for simple positioning consists of two implementation parts and a controller tuning stage.
In the first part, a profile generator program is implemented using the HCRSPF() function block. In the
second part, the control program is implemented using the HCRs_Cont() function block and the HCR-
LinValve() valve linearization function block. In the third part, the controller is adjusted by varying the
proportional gain.

Automation Studio project "TM48_PositionControlling" with an HMI application and a simulated con-
trolled system (valve and cylinder) are used for this exercise. The necessary machine data and speci-
fications can be found in the exercise instructions. The following image shows a block diagram of the
project when completed. The simulation task is already completely implemented in the project and should
not be modified:

Program: ProfGen Program: Control


s_end [mm]
Global REAL
s_set [mm]
s_end_init Profile generator Global REAL u_valve [V]
Global BOOL HCRSPF() s_act [mm] Controller Linearization Global REAL
Global REAL HCRs_Cont() HCRLinValve()

Program:
Simulation

Simulation
HydSimValve()

Part 1: Profile generation program


Create a new program called ProfGen. Use the HCRSPF() function block to generate a movement pro-
file between two positions (s_end = 100mm, s_end = 200mm). Use the Automation Studio online help
documentation as a reference. Trace the path of the profile on the visualization device.

Program: ProfGen

s_end [mm] Profile generator


s_set [mm]
Init HCRSPF()

Customer requirements
Max. acceleration in all effective directions: 1000.0 mm/s
Max. speed in both directions: 100.0 mm/s
No jerk limitation

10 TM481 - Valve-based Hydraulic Drives


Simple positioning

Part 2: Controller program


Create a new program called Controller. The controller program consists of the control loop function block
HCRs_Cont() and the HCRLinValve() block for static valve linearization. Test the behavior of the control
loop. (Is the effective direction of the manipulated variable OK?)
Procedure
a) Configure the HCRLinValve() function block using the (static) valve characteristic curve derived
below.
b) Configure the HCRs_Cont() function block using the controller data given in the following.
c) Note: A structure variable of type HCRPIDPara_s_typ is needed to configure the HCRs_Cont()
function block.
d) Connect the two function blocks.
e) Verify the functionality.

TM481 - Valve-based Hydraulic Drives 11


Simple positioning

Static valve characteristic curve

Control loop data


Servo correction should be disabled: vyServoMode = 8
No use of the PID derivative element
No use of the PID integral element
No speed feed-forward control

Part 3: Adjusting the controller


Connect the individual programs using the global variables s_set, s_act and u_valve. Move the cylinder
with value setpoint profiles while varying the value of Kp. Kp = 0.001 can be used as the starting point.
Observe the control deviation.

12 TM481 - Valve-based Hydraulic Drives


Positioning with servo correction (optional)

4 POSITIONING WITH SERVO CORRECTION (OPTIONAL)

In this case, servo correction is added to the simple positioning control loop. The goal is to improve the
precision and dynamics of the positioning task using servo correction.

4.1 Servo correction

Up until now, we have assumed that the volumetric flow rate (and with it, the cylinder speed) has been
roughly proportional to the valve opening. As explained in the TM480 training module, however, there is
a direct relationship between the drop of pressure at the valve and the volumetric flow rate. The approach
described below takes this relationship into consideration in order to improve positioning.

In addition, the necessary volumetric flow rate can be defined for a certain velocity setpoint (using the
cylinder surface areas A_Cyl_pos and A_Cyl_neg).

By applying servo correction, adjusting for the cylinder surface areas and performing valve linearization,
the cylinder's velocity setpoint is converted into a corresponding valve voltage that compensates for the
loss of pressure at the valve, the difference in surface areas and the valve characteristic curve.

TM481 - Valve-based Hydraulic Drives 13


Positioning with servo correction (optional)

The following extended positioning block diagram shows that the PID controller now outputs a velocity
setpoint. Servo correction dynamically converts this velocity setpoint into a valve opening. Applying valve
linearization to the valve opening then results in the valve voltage.

In short, servo correction converts cylinder velocities into valve openings. This makes it additionally
possible to use the velocity setpoint of the profile generator. This velocity setpoint is passed directly to
the servo correction as a feed-forward value after the position controller.

In some hydraulic applications, the system pressure is not always constant at all operating points. A
change in system pressure over a large range (e.g. more than 10 % of the nominal pressure) can have
negative effects on the control behavior. In this case, it would be better to measure the system pressure
with a sensor and use the actual measurement rather than a constant.

The controller blocks (e.g. the HCRs_Cont() function block) in the AsHydCon library already include the
functionality needed for servo correction. As a result, only the controller blocks have to be configured.

The loss of pressure at the valve is calculated either directly using the chamber pressures in the cylinder
or indirectly using the dynamic process force. There is a distinction between servo correction with or
without pressure sensors.

4.1.1 Servo correction without pressure sensors

If there are no pressure sensors to measure the pressure of the two cylinder chambers, then the servo
correction is calculated using the friction force and process force. The process force can be measured
using a force sensor on the piston rod, for example, or derived from the gravitational force. The following
rule of thumb can be used to calculate the friction:
Approx. 10 N friction force per mm rod diameter.

14 TM481 - Valve-based Hydraulic Drives


Positioning with servo correction (optional)

Ffriction

Fprocess
Ffriction
Ffriction
The HCRs_Cont() function block can be used for servo correction without pressure sensors. It includes
the controller and servo correction in this case. Setting the input vyServoMode = 0x02 enables servo
correction while also taking the system pressure pSupply into consideration. This is illustrated in the
following block diagram with a sensor used to measure the process force.

4.1.2 Servo correction with pressure sensors

If the controller block has direct access to the measured chamber pressure values, then the exact pres-
sure difference at the valve is known. Servo correction in this case only needs the system pressure and
the two chamber pressure values. The HCRs_Cont_p() function block can be used for positioning. This
function block includes both a controller as well as servo correction with pressure sensors. The following
block diagram shows how the HCRs_Cont_p() function block is connected when the system pressure
is measured. In this use case, vyServoMode is set to 0x02.

TM481 - Valve-based Hydraulic Drives 15


Positioning with servo correction (optional)

4.2 Servo correction exercise

Use the prepared project provided by your trainer


(TM481_ServoCorrectionPositionControlling).
Use the proportional gain (start value Kp = 0.01) to minimize the control deviation. Compare the results
with those from the first exercise.
Procedure
a) Set up the HCRs_Cont_p() controller function block.
b) Create the parameter structures.
c) Connect HCRs_Cont_p() to HCRLinValve().
d) Connect s_set, v_set, s_act and u_valve.
e) Set servo correction mode 0x02.
f) Set the parameters.

Machine data

16 TM481 - Valve-based Hydraulic Drives


Positioning with servo correction (optional)

Constant system pressure = 200.0 bar


Tank pressure = 0.0 bar
Cylinder surface area A_pos = 12.57 cm
Cylinder surface area A_neg = 6.41 cm
Nominal valve volumetric flow rate Qnom_neg = Qnom_pos = 100 l\min
Nominal drop in pressure at the valve edge pDelta_nom = 35 bar

Block diagram

Program: ProfGen Program: Control


s_end [mm] s_set [mm] ,
s_end_init
Profile generator v_set [mm/s]
[BOOL] HCRSPF() s_act [mm] Valve
Controller + opening HCRLin- u_valve [V]
pCyl_pos [bar] servo correction
Valve()
HCRs_Cont_p()
pCyl_neg [bar]

s_act [mm] Velocity calc. v_act [mm/s]


HCRDT1()

Program:
Simulation

Simulation
HydSimValve()

TM481 - Valve-based Hydraulic Drives 17


Alternating positioning and force control

5 ALTERNATING POSITIONING AND FORCE CONTROL

Many real world applications require a solution that alternates between position and force control. This
requirement is characterized by the following cycle:

Position-controlled movement
Changeover to force control upon reaching an adjustable threshold value for the press force
Controlled increase of the press force to the target force, maintaining the target force and force
reduction until the threshold value is achieved
Return to initial position

5.1 The principle of alternating control

With alternating control of position and force, the position and force controllers run in parallel. Only one
controller is connected to the actuator at a time, however. For this reason, the following two points are
crucial:

Definition of consistent changeover conditions


Smooth changeover between the controllers

Both of these points are taken into consideration by the HCRsF_Cont_p() control block. Depending on
the operating mode, this uses one of the two force control blocks HCRF_Cont() or HCRF_Cont_p() in ad-
dition to the HCRs_Cont_p() position control block and the HCRJoltFree() block for smooth changeovers
between position and force control.

The changeover condition can either be defined in the application (e.g. changeover at specified force
or pressure value), or the minimum selector can be used. When using the minimum selector, the
HCRsF_Cont_p() control block automatically selects the internal controller with the smallest manipulat-
ed variable.

Position controller / force controller


HCRsFCont(), HCRsFCont_p()

s_set [mm]
Position cont.
s_act [mm]
HCRs_Cont()
Valve
HCRs_Cont_p() opening
Lineari- u_valve [V]

F_set [mm]
zation
Force cont.
F_act [mm]
HCRF_Cont() Min
HCRF_Cont_p()

uSwitch

The minimum selector automatically ensures a smooth changeover between position and force control.
If the changeover is handled by the uSwitch input, then the changeover time tSwitch can be defined for
a smooth changeover. This is the time during which the manipulated value is adjusted.

18 TM481 - Valve-based Hydraulic Drives


Alternating positioning and force control

5.2 Exercise

The goal is to implement combined positioning and force control with velocity feed-forward control dur-
ing positioning control and servo correction based on the cylinder chamber pressure in both operating
modes. A profile generator is used to generate the position setpoint.

You will receive a prepared project to use with this exercise. The cyclic signals (cylinder pressures, etc.)
are taken from the servo correction project and applied to the s_Cont_InVar and F_Cont_InVar structures
for the two controllers.

Configure the parameters of the positioning/force controller with the HCRsFCont() block in the Control
program. Move from the start position in the positive direction until contact is made with the workpiece
and a process force of 10000 N is reached. This force should be maintained until another movement
is performed (e.g. back to the initial position). The minimum selector should be used to switch between
the controllers.
Repeat this procedure while varying the proportional gain Kp of both controllers.
Procedure
a) Use the prepared project provided by your trainer (TM481_PositionForceControlling).
b) Establish a connection with the HMI application via a VNC viewer (IP: localhost, Password: c).
c) Enable F-y servo correction mode FyServoMode = 0x02.
d) Enable v-y servo correction mode vyServoMode = 0x02.
e) Enable the minimum selector by setting uSwitch = 2.
f) Configure the controller using the machine data.
g) Calculate the maximum process force Fp (1bar = 10 N/cm).
h) Tune the position controller by adjusting Kp (starting value of Kp = 1.0).
i) Tune the force controller by adjusting Kp (starting value of Kp = 0.1).
j) Optional: Configure the PT1 pressure filter.
k) Optional: Configure the valve leakage.
l) Optional: Tune a PI force controller.
m) Optional: Tune a PI positioning controller.
n) Optional: Adjust the gain of the velocity feed-forward control.

TM481 - Valve-based Hydraulic Drives 19


Alternating positioning and force control

Machine data

Constant system pressure = 200.0 bar


Tank pressure = 0.0 bar
Cylinder surface area A_pos = 12.57 cm
Cylinder surface area A_neg = 6.41 cm
Cylinder height h_Cyl = 500.0 mm
Mass of the piston m_Cyl = 10.0 kg
Volume of the feed lines V0_neg = V0_pos = 40.0 cm
Nominal valve volumetric flow rate Qnom_neg = Qnom_pos = 100 l\min
Nominal drop in pressure at the valve edge pDelta_nom = 35 bar
Contact point with the workpiece s_act = 350 mm
Force setpoint on the workpiece Fp_set = 10000 N

Block diagram

Program: ProfGen
Program: Control
s_end [mm]

s_end_init
Profile generator
s_set [mm],
[BOOL] HCRSPF() v_set [mm/s]

Fp_set [N]
Valve
Position / force
pCyl_neg [bar], opening HCRLin- u_valve [V]
pCyl_pos [bar] Force calc. Fp_act [N] Controller
Valve()
10*(pPos*A_pos HCRsF_Cont_p()
pNeg*A_neg)

s_act [mm] Velocity calc. v_act [mm/s]


HCRDT1()

pCyl_neg [bar], Program:


pCyl_pos [bar], Simulation
s_act [mm]
Simulation
HydSimValve()

20 TM481 - Valve-based Hydraulic Drives


Selecting the right function blocks

6 SELECTING THE RIGHT FUNCTION BLOCKS

The following flow chart should serve as a selection guide for the function blocks provided in the AsHy-
dCon library.

Position Position or
control force control task?
Force
control
Simple (and fast)
Position
movements from start
and force Which measured values
to finish?
control are available?
(no jolt limitation
requirements) (force control block
selection)
Yes No
Chamber Force
pressures
Is specifying
Block: Block:
HCRP2P_Cont block: a movement profile
HCRF_Cont_p HCRF_Cont
No trajectory required?
generator necessary (with acceleration
here! and jolt limitations)

Yes

HCRSPF block:
Which measured values
are available?
(Selection:
Control block)
Position +
Position
Chamber pressures

Control block: Control block:


HCRs_Cont HCRs_Cont_p
(optional: Use Which measured values
of a known load force) are available?
(control block
selection)
Chamber Force
pressures
Valve curve known?

Yes Block: Block:


HCRsF_Cont_p HCRsF_Cont

Block: HCRLinValve

TM481 - Valve-based Hydraulic Drives 21


Project development

7 PROJECT DEVELOPMENT

7.1 Helpful information regarding project preparation

7.1.1 Hydraulics circuit diagram

The hydraulics circuit diagram should be studied and discussed with the machine operator before the
beginning of each hydraulics project.

7.1.2 Machine description

The information for configuring the AsHydCon function block relies significantly on the valves in use, i.e.
the hydraulic drive in use, e.g. a linear drive. This information can be found in the respective data sheets.

7.1.3 Hardware selection

Choosing the right hardware depends significantly on the number of hydraulic axes to be operated and
the required response time. Recommended values for selecting a response time are provided in the
following table.

Medium level control quality and dynamics Response time: approx. 2 ms


High level control quality and dynamics Response time: approx. 1 ms
Highest level control quality and dynamics Response time: approx. 0.5 ms

The following table provides additional recommended values for selecting the appropriate CPU for a
predefined response time and number of axes.

PP400 or X20CPx484 1 2 hydraulic axes with a response time of ap-


prox. 1.5 ms
X20CPx485 Up to 4 hydraulic axes with a response time of
approx. 1 ms
X20CPx486 Up to 2 hydraulic axes with a response time of
approx. 0.5 ms

Up to 4 hydraulic axes with a response time of


approx. 1 ms
APC620 Up to 16 hydraulic axes with a response time of
approx. 1 ms

Up to 10 hydraulic axes with a response time of


approx. 0.8 ms

2 hydraulic axes with a response time of approx.


0.4 ms

22 TM481 - Valve-based Hydraulic Drives


Project development

The response time consists of


inputting the measurement signals from the input modules into the computer via the X2X Link,
processing the measurement signals and determining the output values by the CPU,
issuing the output sizes to the output module via the X2X Link.

The response time can be determined using the following formula:

The Excel sheet provided in the Automation Studio help system can be used to determine the smallest
possible X2X Link cycle time as well as the I/O communication time for a given I/O configuration, cable
length and X2X settings in Automation Studio.

Communication / X2X / General information / Determining the cycle time

TM481 - Valve-based Hydraulic Drives 23


Project development

7.1.4 Settings in Automation Studio

The following guidelines should be observed in order to achieve the minimum response time for the
given hardware configuration:
Generally, a hydraulic controller is executed in the fastest task class. The coordination of the task class
cycle time with that of the X2X Link is important: the cycle time of the task class must always be a whole-
number multiple of the X2X Link cycle time in order to allow synchronous operation.
An X2X Link cycle time of 200 s can be set for most hydraulic control loops. A value of 400 s is
recommended as the cycle time for the fastest task class, if the CPU performance permits it. The stack of
the task class must generally be increased compared to the standard setting. In order to avoid memory
problems, it is best to start with a value of 65535 bytes. Below you see how to make the settings for the
system timer, task class and X2X Link.

System timer settings:

Open the CPU properties window:

Go to the "Timing" tab and make the following settings:

24 TM481 - Valve-based Hydraulic Drives


Project development

Task class settings:

In the CPU properties window, go to the "Resources" tab and make the following settings:

X2X Link settings:

Open the X2X Link configuration window.

Make the following settings:

7.2 Commissioning guidelines

In general, the supplier of a hydraulic system must provide commissioning instructions for the system
that should be consulted before each commissioning.

The following section covers several additional points to consider with regard to commissioning.

Especially in the case of hydraulic systems, it is important to make detailed preparations in advance
and to develop a step-by-step plan that verifies the functionality of each required component before it
is commissioned.

Most important, this requires the implementation of appropriate operating modes. In addition to automatic
mode, the option of manual operation must always be available as well. With complex systems, it is a
good idea to implement a suitable visualization application for manual operation in advance.

The following components should be observed during a function test:

TM481 - Valve-based Hydraulic Drives 25


Project development

Only very small, slow movements are performed for testing.


System pressure is kept as low as possible during commissioning. The purpose of
this is to protect all components since the hydraulic oil is generally still contaminated.

Valves: "Does the valve response (open/closed for switching valves, position of continuous
valves) match the control action performed?"
System pressure pump: "Does the direction of rotation of the electric motor match the intended
direction of rotation for the pump?"
Valve control: The linkage between safety and proportional valves must be taken into account
for valve control actions. In general, the safety valves are opened in the first step while the pro-
portional valve is closed. The proportional valves are then controlled in manual mode in order
to verify their effective direction (a control block is not used for this; instead, the valve voltage
is specified directly).
During manual operation and at low system pressure, the entire operating area of a hydraulic
cylinder, for example, should be run through several times in order to remove potential air
pockets before the system pressure is increased.

Gradual implementation of automatic mode should commence only after it has been confirmed that all
components are functioning.

7.2.1 Controller configuration

AsHydCon library control blocks are generally configured in two steps:

a) Using valve parameters, valve characteristic curves, cylinder dimensions, etc. that are listed in
data sheets
b) By configuring a higher-level PI controller

The first point has already been described in detail in this training module. Training module "TM261
Closed-loop Control with LoopConR" contains much useful information regarding the second point. The
following is a possible approach for configuring the control blocks provided in the AsHydCon library.

An approximate value for the proportional gain Kp of the position controller can be determined
using the HCRAutoTune() function block by entering a few physical parameters.
As a test experiment, it is recommended that you specify a cyclical position profile that can be
implemented using this P controller. Kp can now be adjusted as needed. Increasing this value
makes the control loop faster, but it also increases the potential for vibration. It is important to
test the controller in the central piston position since this is where the potential for vibration is
highest.
In the next step, velocity feed-forward control can be used to simplify the task for the controller.
In general, proper feed-forward can help increase the controller's Kp value.
Finally, the remaining control error can be reduced by adding an I component. It is important to
note that stationary I components with high static friction can lead to stick-slip effects.

26 TM481 - Valve-based Hydraulic Drives


Project development

Stick-slip effects occur if the static friction is greater than the kinetic friction. In these cases, a strong
force is needed to overcome the static friction. Once the static friction has been overcome, this force
results in a movement past the position setpoint. The effect is repeated in the opposite direction and can
result in a persistent oscillation around the position setpoint.
The way to prevent this is to set up a dead zone for the I component. As long as the absolute value
of the control deviation is smaller than a specified value, the I component is simply frozen in order to
avoid the stick-slip effect.

7.2.2 Controller optimization

AsHydCon library control blocks have many options which allow them to be optimized for specific types
of tasks. A couple of examples are provided below.

If the load force is known, then the process force can be taken into consideration and compen-
sated for in the HCRs_Cont() function block.
Acceleration forces can also be interpreted as (dynamic) load forces. In order to improve the
control sequence behavior for accelerating movements, the force m*a to be overcome can be
specified for the acceleration process along with the mass m and the acceleration a.
The modularity of these function blocks allows the standard control loop being implemented
using the AsHydCon library framework to also be expanded to include a state controller.

The following image shows the basic principle of this. If, as depicted here, the current acceleration a_act
is available, it can be included in the control loop accordingly. The manipulated variable generated by
this controller is then a direct function of the state variables' path (P component), speed (D component)
and acceleration. These types of controllers are called state controllers.

HCRs_Cont
vset uvalve
sset
HCRPID() HCRvyServo_Fp() HCRLinValve
- +
vadd aact
Ka
sact

TM481 - Valve-based Hydraulic Drives 27


Training modules

TRAINING MODULES

TM210 Working with Automation Studio


TM213 Automation Runtime
TM223 Automation Studio Diagnostics
TM230 Structured Software Development
TM240 Ladder Diagram (LD)
TM241 Function Block Diagram (FBD)
TM242 Sequential Function Chart (SFC)
TM246 Structured Text (ST)
TM250 Memory Management and Data Storage
TM400 Introduction to Motion Control
TM410 Working with Integrated Motion Control
TM440 Motion Control: Basic Functions
TM441 Motion Control: Multi-axis Functions
TM450 ACOPOS Control Concept and Adjustment
TM460 Initial Commissioning of Motors
TM500 Introduction to Integrated Safety
TM510 Working with SafeDESIGNER
TM540 Integrated Safe Motion Control
TM600 Introduction to Visualization
TM610 Working with Integrated Visualization
TM630 Visualization Programming Guide
TM640 Alarms, Trends and Diagnostics
TM670 Advanced Visual Components
TM800 APROL System Concept
TM811 APROL Runtime System
TM812 APROL Operator Management
TM813 APROL XML Queries and Audit Trail
TM830 APROL Project Engineering
TM890 The Basics of LINUX
TM920 Diagnostics and service
TM923 Diagnostics and Service with Automation Studio
TM950 POWERLINK Configuration and Diagnostics

TM1010 B&R CNC System (ARNC0)


TM1110 Integrated Motion Control (Axis Groups)
TM1111 Integrated Motion Control (Path Controlled Movements)
TM261 Closed Loop Control with LOOPCONR
TM280 Condition Monitoring for Vibration Measurement
TM480 The Basics of Hydraulics
TM481 Valve-based Hydraulic Drives
TM482 Hydraulic Servo Pump Drives

28 TM481 - Valve-based Hydraulic Drives


Training modules

TM481 - Valve-based Hydraulic Drives 29


Training modules

30 TM481 - Valve-based Hydraulic Drives


Training modules

TM481 - Valve-based Hydraulic Drives 31


V1.3.0.2 2014/11/20 by B&R, All rights reserved.
All registered trademarks are the property of their respective owners.
We reserve the right to make technical changes.