Control Design and Validation for Floating Piston Electro-Pneumatic Gearbox Actuator

: The paper presents the modeling and control design of a ﬂoating piston electro-pneumatic gearbox actuator and, moreover, the industrial validation of the controller system. As part of a heavy-duty vehicle, it needs to meet strict and contradictory requirements and units applying the system with different supply pressures in order to operate under various environmental conditions. Because of the high control frequency domain of the real system, post-modern control methods with high computational demands could not be used as they do not meet real-time requirements on automotive level. During the modeling phase, the essential simpliﬁcations are shown with the awareness of the trade-off between calculation speed and numerical accuracy to generate a multi-state piecewise-linear system. Two LTI control methods are introduced, i.e., a PD and an Linear-Quadratic Regulators (LQR) solution, in which the continuous control signals are transformed into discrete voltage solenoid commands for the valves. The validation of both the model and the control system are performed on a real physical implementation. The results show that both modeling and control design are suitable for the control tasks using ﬂoating piston cylinders and, moreover, these methods can be extended to electro-pneumatic cylinders with different layouts.


Introduction
In recent years, the main trends of the automotive industry, such as automated driving and electric mobility, have reached the heavy-duty vehicle market. Advanced driver assistance systems (ADAS) and autonomous functions, such as platooning [1], automated highway driving [2], and autonomous yard maneuvering [3], are expected to increase fuel efficiency, decrease emissions [4], and also enhance safety [5]. As a consequence of the continuous development in the field of electric mobility, the application of electric actuators already started to expand. They provide a more viable alternative to pneumatic systems in pure electric vehicles, but at present, in diesel and diesel hybrid trucks, pneumatic actuators are indispensable. They have many advantages over equivalent electro-mechanic and hydraulic actuators, such as the unlimited supply of air, high operational safety, and easy maintainability. Still, their nonlinear behavior makes modeling and controlling them difficult. Despite having an already extensive literature and prior knowledge, the continuously tightening qualitative requirements and increased functionality caused by the more and more automated system generates a need for further research.
Besides the application of single-and double-acting pneumatic cylinders in heavy-duty vehicles, pneumatic systems are also widely used in robotics, and Pneumatic Artificial Muscles (PAM) represent one of the most promising solutions for interactions between robots and humans. In both applications, one of the most widely researched areas is the modeling of the hysteretic aspects of pneumatic linear actuators. Proposed methods contain the Preisach model [6], the Maxwell-slip model [7], the generalized Bouc-Wen model [8], and empirical approaches, such as the method presented in [9].
There are many approaches in the literature to achieve the position control of pneumatic linear actuators, such as linear controllers, for instance, Linear-Quadratic Regulators (LQR) and Proportional-Integral-Derivative (PID) -type controllers with their robustness enhanced with different types of compensations. In [10], a Linear Quadratic servo control is presented to control a single-piston pneumatic gearbox actuator. Many PID-based solutions exist to achieve the position control of a PAM. In [11], a fuzzy PID control is presented, where fuzzy models are used to provide dynamic feedback, which cancels the nonlinear effects; therefore, a PID controller can be used effectively. In [12], a novel Neural Network based PID controller is presented, which proves to be more robust than a conventional PID controller. The authors of [13] show an adaptive fuzzy PD controller combined with a non-fuzzy integral branch, where a fuzzy inverse model dynamically adjusts the PD part. In [14], an active model-based, advanced nonlinear PID controller is presented to reduce the errors of the simplified dynamics model and improve the performance of the controller. The authors of [15] present a two-degree-of-freedom nonlinear PID controller to compensate for the nonlinear hysteretic phenomena of the PAM and to increase its disturbance rejection.
Model Predictive Controllers (MPC) are also proposed to control PAMs and clutch actuators, such as in [16,17], where a discrete-valued MPC controller is developed to control a hybrid pneumatic-electric actuator. Moreover, the authors of [18] present an explicit MPC method using Pulse-Width Modulation (PWM). Nonlinear methods, such as sliding-mode control (SMC) and backstepping controllers, are also used. The authors of [19] present an Extended Proxy-Based Sliding Mode Controller through the application of a PAM to solve the "chattering" problem of a traditional Sliding Mode Controller. The authors of [20] present an analytic control design model of PWM-based pneumatic systems, which serves to transform a discontinuous switching model into a continuous model, then develops an SMC controller for such a system. In [21], an SMC is presented for an electro-pneumatic clutch actuator, then a controller reduction possibility is proposed. In [22], a cascaded tracking controller is performed by combining sliding-mode and Lyapunov techniques based on a nonlinear state-space representation. A similar method is presented in [23]. However, instead of SMC, a model-based backstepping controller is used. The authors of [24] show a dual-mode controller for an electro-pneumatic clutch actuator, which is a combination of a local and a global switched controller. In [25], a switched backstepping control of an electro-pneumatic clutch actuator is presented, showing better performance than PWM-based methods and also using less solenoid valve switches. The authors of [26] propose a Fuzzy Backstepping Controller for a PAM, where three fuzzy sets are used: one for inflation, one for deflation, and one for the transition region.
In [27], an adaptive robust neural network controller is proposed for a pneumatic actuator, which can achieve high tracking accuracy without knowing the bounds of the parameters and disturbances. In [28], the position control problem of an electro-pneumatic clutch actuator is formulated as a robust asymptotic tracking control problem, which is solved through a constructive robust stability algorithm using Simulated Annealing Algorithm. The authors of [29] present a H∞ controller, which is used to achieve high reference tracking performance and meet stability specifications, then proposes Hankel singular value-based model order reduction.
Most of these methods perform well in their given applications, which are mainly PAMs using proportional valves or electro-pneumatic clutches. Proportional valves can be used to achieve constant mass flow rates, thus the control problem significantly differs, while in the latter case, the actuator must hold the clutch in the requested position, therefore it has to utilize a diaphragm spring, which has a highly nonlinear and hysteretic force characteristic. In this regard, the position control of a clutch actuator is more difficult, but there are further differences between these systems. In essence, clutch actuators are single-acting cylinders with 2-way 2-position solenoid valves, which means there are distinct valves to load and to exhaust the chamber, thus it is also possible to hold the chamber at constant pressure. On the other hand, gearbox actuators mostly are double-acting cylinders with a single 3-way 2-position solenoid valve connected to each chamber. Therefore, it is not possible to achieve constant chamber pressure during a gear change. There is also a difference in the average actuating speed, gearbox actuators have an actuation speed higher by a factor of around 3-5, than that of a typical clutch actuator. This paper aims to present and compare two control methods, which can achieve the high-quality position control of an electro-pneumatic gearbox actuator. The quality of the gear change has a considerable impact on the vehicle comfort and the expected lifetime of the actuator. Using a high number of solenoid valve activations or achieving too fast gear changes with high impact velocity decreases the expected lifetime of the system and increases its noise. At the same time, too slow gear changes harm the torque flow. Thus they can reduce passenger comfort and debase the vehicle dynamics.
In addition to the qualitative requirements, the closed-loop system should be robust to the changes of the supply pressure, as it can be decreased due to failure when the controller should also be able to reach a safe state, which is the neutral position of the actuator. Besides, if the controllers can operate reliably with different supply pressures, the same system could be used for different vehicles, decreasing production and development costs. In an optimal case, the robustness analysis of a system should provide mathematical evidence and guarantees. However, it is not feasible in this example, thus the robustness and reliability of the system can only be determined by detailed testing, which is a common approach in industrial applications.
In this domain, the industrial application is a crucial point. Even for the LQR control, one has to use precalculated lookup tables to fit in the computational resources, with the awareness of the trade-off between calculation speed and numerical accuracy. Further problems arise from the fact that in this case, continuous control signals can not be actuated, as the only possibility is the binary control of the valves. Therefore, one of the main goals of the research is the implementation of the results in a commercial actuator control unit. In this case, the article presents the real-time testing of the developed control schemes. The paper summarizes the results of previous work regarding the modeling and model-based LTI control of the actuator, then complements it with testing on the real system. Following the Model-Based Development (MBD) process, in [30], a nonlinear model is developed, which is validated against laboratory measurement in [31], then the model-based controllers have been designed in [32]. Based on the tests on the real system, it becomes clear that to use the developed controllers on the actual system successfully, they must be substantially modified. In the case of the PID controller, the control strategy and the weights of the controlling aims must be changed due to the hysteretic behavior of the actuator. Moreover, in the case of the LQR method, the online calculation of the feedback matrix is not feasible. After essential modifications, the controllers have been implemented and tested on the real system, and their performances have been compared on different supply pressures.
This paper aims to present and compare a PID and an LQR position control of an electro-pneumatic gearbox actuator while finding a trade-off between the high-quality gear change and the limited computational resources of a commercial actuator control unit. The paper is organized as follows. Section 2 introduces the pneumatic actuator and the developed nonlinear model, Section 3 presents the model-based controller development, and Section 4 shows the results achieved on the real system. Section 5 shows some concluding remarks.

Electro-Pneumatic Actuator
The controlled system is the shift actuator of an automated manual transmission (AMT) of a heavy-duty vehicle. To optimize the fuel consumption of these vehicles with a relatively low number of gear pairs, heavy-duty gearboxes usually have three gearbox stages: split gear, range gear, and the main gearbox. Both the split and range gears have two gear pairs, and in most cases, they do not have a neutral position. Thus, the neutral of the whole gearbox is achieved through the main gearbox. The main gearbox has either two or three parallel shift actuators, or a shift and a select actuator. In case of the latter, which is similar to manual transmissions, the gear shift is divided into two parts according to the H-pattern: the first phase is the lane selection along the horizontal axes of the pattern, for example, selecting the lane of 1st-Neutral-2nd gears, or the lane of 3rd-Neutral-4th gears, which is achieved by the select actuator. The second step, the gear shift is the function of the shift actuator: it moves the gear stick along the vertical axes of the shift pattern as it shifts the gearbox to neutral or to a requested gear within a previously selected lane, by using a floating piston actuator to enable three stable positions.
During a gear change, the proper gearwheel must be connected to its shaft in a shape-locking connection by a face-dog clutch to achieve power-flow. Before engaging a gear, the speed difference between the elements must be reduced, which is achieved either by internal or central synchronization. In the case of internal synchronization, a synchromesh mechanism is also the part of the dog clutch. It decreases the speed difference between the shaft and the gear through friction and also prevents the connection until synchronization occurs. In the case of central synchronization, the speed difference is reduced to a partially synchronized state either by the countershaft brake or by modifying the input shaft speed through the engine control. In this paper, central synchronization is assumed. Therefore, there is no need to consider the angular velocities of the shafts and gear wheels.
The pneumatic cylinder is driven by 3-way 2-position solenoid valves, which connect the supply pressure to the chambers in energized state, and in released state, they connect the chambers to the environment. A simplified layout of the system can be seen in Figure 1. The actuator contains two pistons (Main piston and Floating piston), which, together with the step-like change in the internal diameter of the actuator, divide the cylinder into three chambers. Both Chamber 1 and Chamber 2 are connected to a single solenoid valve, which serves both inflow and outflow purposes. In Chamber 3, nearly constant, ambient pressure is guaranteed by an air release port; however, in case of too fast movement, its pressure increases, thus the chamber acts as an air spring between the cylinder housing and the floating piston. The gear shift is achieved by moving the main piston within the cylinder by increasing the corresponding chamber pressures. As the main piston moves, it actuates the connected elements of the gearbox (such as the shift finger and the synchronizer sleeve), therefore it connects the proper gear to the corresponding shaft.
The actuator has three dedicated positions: two gears (the High (H) and Low (L) end-positions of the piston) and the Neutral (N) position. The detent mechanism is used to fixate the pistons in these positions and to prevent their unintentional movement.  The movement of the floating piston is limited to the High-Neutral section of the cylinder. Its function is to either help or act against the movement of the main piston through collision in the upper half of the cylinder. To understand the need for the Floating Piston, typical open-loop control strategies of the actuator must be considered: to shift the actuator to, e.g., High, Solenoid Valve 2 must be activated, which will increase the pressure in Chamber 2, thus the pistons will move towards High. Due to the decreasing volume of Chamber 1, its pressure will increase, which helps to slow down the pistons, this way, it can prevent the high-speed collision. To shift the actuator to Neutral from High, while preventing overshoot, both Chamber 1 and Chamber 2 should be loaded at the same time. To ensure that the pistons will reach Neutral, the cross section area of the pistons connecting to Chamber 1 must be bigger than the area connecting to Chamber 2. As the same logic can be applied to Low-to-Neutral and Neutral-to-Low gear changes, it can be seen that different ratios of the cross sections are ideal in the two sides of the cylinder, which is provided by the Floating Piston with its movement limited to one side of the actuator.

Nonlinear Model of the Actuator
In [33], a nonlinear model is proposed, fitted to a given actuator, and used effectively for controller design. However, the model developed for this research had to be able to predict the effects of constructional changes, thus a more universal model was needed, based on conservation equations, such as the conversation of energy and conservation of momentum. A more detailed description of the model is found in [30], this section only presents the main steps.
In order to find a trade-off between the model accuracy and complexity, simplifications have to be taken into account, such as the gas in the chamber is assumed to be perfectly mixed, thus the equations can be written as ordinary differential equations. The system has two main parts: the solenoid valves and the actuator. The solenoid valve models could be further divided into an electric, a magnetic, a mechanical, and a fluid dynamic model. As the electric layout and the magnetic properties of the solenoid valves are not known, a lookup table-based solution is implemented for both the activated and released state of the solenoid valve, determining the magnetic force. The mechanical model of the solenoid valves can be written according to Newton's second law: where a MV is the acceleration of the armature, F MVmagnetic is the magnetic force, F MVspring is the force of the return spring, F MV f riction is the viscous friction, and m MV is the armature mass. In the next step, assuming both the initial position and velocity to be equal to zero at the start of the simulation, the actual armature position is calculated. Once the position of the armature is known, the smallest cross section area of the flow is calculated. As Figure 2 shows, based on the armature position, the cross section area of the flow is limited either by the circular area of the corresponding port or by the area of the cylinder wall between the armature and the port, with its height determined by the armature position: where α MV is the contraction coefficient, D MV is the diameter of the port, and x MV is the armature position. The mass flow rate of Chamber 3 and the solenoid valves, thus the mass flow rates of Chamber 1 and Chamber 2 are derived from the Bernoulli equation for compressible fluids, taking the following form, where κ air is the heat capacity ratio of air, R air is the gas constant for air, T 1 is the source side temperature, p 1 is the source side pressure, and PR is the pressure ratio, which can be determined as where p 2 is the counter side pressure and PR crit is the critical pressure ratio: The 3-way 2-position solenoid valves connect the chamber either to the air supply or to the environment. In this respect, they act like two 2-way 2-position valves with inverse states: one connects the chamber to the air supply and the other one connects it to the environment. Therefore, (3) is written between the supply pressure and the chamber, and between the environment and the chamber, then the total mass flow rate of the solenoid valve is the sum of the two values.
The model of the pneumatic cylinder is divided into two parts: a thermodynamic and a mechanical model. In the thermodynamic model, four state variables should be calculated: the volume of the chamber, the temperature, mass, and pressure of the gas in the chamber. The mass of the air is calculated as the integral of the mass flow rate over time, where the initial mass is calculated from the initial volume of the chamber, assuming ambient pressure and temperature in the chamber. The volume of the chamber comes from the sum of ring and cylinder volumes, with their height calculated from the axial displacement of the pistons. The equation for the pressure gradient is derived from the energy equation and is written as follows, where T inw is the temperature of the flowing air; V ch , p ch , and T ch are the volume, pressure, and temperature of the chamber, respectively;ṁ ch is the mass flow rate of the chamber; k ht ; and A ht are the heat transfer coefficient and heat transfer area and T amb is the ambient temperature. Last, the temperature of the gas is calculated as a function of the other three state variables according to the ideal gas law. In the mechanical model of the cylinder, the movement of each piston is calculated according to Newton's second law: where v p is the piston's speed; F p is the sum of the pressure forces; and F f p and F f c are the friction forces between the two pistons and between the piston and the cylinder, respectively. F cp and F lim are the contact forces between the two pistons and the piston and the cylinder, respectively. F det is the force of the detent mechanism, and m p is the mass of the piston. The implemented friction model contains the Coulomb friction and a viscous term, where the switching characteristic of the Coulomb friction is approximated by a sigmoid-function. Between the pistons it is written as where F µ is the friction force between the elements; v mp and v f p are the speed of the Main Piston and Floating Piston, respectively; f is the gradient of the sigmoid function; and d viscous is the viscous friction coefficient.
The contact forces only emerge in case of collision, and they are modeled as a spring accompanied by a damping effect. Between the pistons it is written as where x p1 and x p2 are the piston positions, s c is the spring stiffness, and d c is the damping coefficient. Both the friction and contact force can be written similarly between the pistons and the housing, and the only difference is that the cylinder's positions are constant, and its velocity equals to zero. The developed model has been verified and validated against laboratory measurements, as it is shown in Table 1 its average accuracy is over 95% for the test cases with the euclidean norm of the errors for all validated outputs were calculated as follows. The test cases are the possible requests of the actuator: Neutral to High, High to Neutral, Neutral to Low, and High to Neutral. Figure 3 shows a Neutral to High gear change as an example. The first diagram shows the solenoid valve commands, the second and third diagrams show Chamber 1 and Chamber 2 pressures, and the fourth diagram shows the Main Piston position. The gear shifts have been performed on the real system with the solenoid valve commands, chamber pressures, and piston position measured, then the measured solenoid valve commands have been added to the input of the nonlinear model, therefore the measured and simulated signals were comparable. A more detailed description of the verification and validation process is presented in [31]. 9

Model-Based Controller Development
The control goal is to achieve gear change by controlling the position of the Main Piston. There are four possible requests: Low to Neutral (L2N), Neutral to Low (N2L), High to Neutral (H2N), and Neutral to High (N2H). Theoretically, High to Low and Low to High requests would also be possible, though this request can be divided into two subsequent requests. As there is no continuous reference signal to follow (the change in the requested position is always a step function), the position control of the actuator could be relatively easy. Yet, the nonlinear behavior of the system and the contradictory requirements make it difficult: The time interval of gear change shall be minimized, as it interrupts the power flow to the wheels; therefore, it negatively affects both the vehicle's performance and the passenger's comfort. A typical gear change contains the disengagement of the clutch, synchronization if needed, gear shift, and the engagement of the clutch, and it takes approximately 0.5-1 s for a human driver, most of which is needed to operate the clutch. As automated transmission systems expected to have at least the same level of performance as a human driver, the shift time must be lower than 80-100 ms. The capacity of the ECU limits the maximum measurement and control frequency. Both the impact velocity and the maximum valve switch constraints aim to increase the expected lifetime of the system. Too high impact velocity (or kinetic energy during a collision) would damage either the housing or the pistons, which is usually determined by finite-element modeling and lifetime calculations. Solenoid valves have a limited lifetime, which, together with the expected lifetime of the actuator and the expected number of gear changes during its lifetime, determines the maximum valve actuations for a gear change. Naturally, this is a less strict criteria, as a slight difference from this limit can be accepted if its average for all gear changes meets the requirements; however, it highly limits the applicable methods. On the other hand, the overshoot limit is a stricter requirement both quantitatively and in importance, as the actuator shall operate on different gearboxes, where the position of the shifted gear can change and accidental gear changes caused by overshoot must be avoided to ensure safe operation.
It is also able to improve a part of performances such as the reduction of shift time or the collision speed; moreover, the overshoot can be eliminated. However, in these cases other performances can be violated as requirements are in contradiction each other. The industrial trade-off prefers low impact in this case, and deals with the wearing of the components through the mechanical design of the elements.
All the requirements and main characteristics of the system has to be taken into consideration to decide which control method to implement. It can be seen that the system is only stable at its fixed positions, where its stability is guaranteed by the housing, floating piston, and detent mechanism. Besides, discrete control signals are required to control the solenoid valves. A Pulse-Width Modulation-based method could be an obvious choice, but it would undoubtedly violate the requirement regarding the maximum number of solenoid valve activations. Another solution could be sliding-mode control or a bang-bang controller. Still, as a consequence of the delayed effect of the control signals, fast system dynamics, and instability, they would either fail the requirements or cause a highly oscillating position. Both memory and computational constraints of the used ECU can also limit the performance of nonlinear controllers. Rule-based methods could also be considered. However, the system shall operate under varying environmental and supply conditions, which have a significant effect on its behavior. Therefore, finding a set of rules to meet the controlling requirements could be complicated, although worth an evaluation in the future.
PID controllers are widely used in industrial applications, mainly because of their simplicity, but their output has to be processed to provide input for both solenoid valves. Linear quadratic methods require a linearized representation of the system, and as it is shown, the state matrix is a function of the actual state, thus the optimal LQR gain also depends on the actual state, which can be critical in the embedded application.
As it is shown, all of the proposed methods have drawbacks, so a trade-off had to be made. The main aspects taken into account were the computing cost, generated code length, and compatibility of the methods with the qualitative requirements; therefore, a PID and an LQR controller are proposed for such an application. According to the principles of model-based development, first, these methods were designed and tested in a MIL environment, presented in detail in [32]. Afterward, they were implemented on the real plant. The controllers were designed with 1 ms sample time and were tuned assuming 9 bar supply pressure and 293 K ambient and supply temperature.

Pid Method
First, a gain-scheduled PID controller has been implemented, using the requested gear change as a scheduling parameter, resulting in four different parameter sets. After investigating the performance and the dynamic properties of the system, the integral term has been omitted. The function of the integral term is to eliminate the residual error of the control. However, the zero residual error is already guaranteed by the detent mechanism, as the force generated by the detent spring always points towards the nearest gear due to its highly nonlinear geometry. In the case of Neutral position, the detent mechanism is supported by the floating piston, as its movement is limited to one side of the cylinder. Therefore, the bigger cross section area always tries to move the main piston towards Neutral. On the other hand, the additional dynamic assured by the integral term can be disadvantageous, as it can cause overshoot and high-speed collision. Therefore, the control function is written as follows, where e(t) is the state error, and K p and K d are the proportional and derivative gains, respectively, which are chosen based on the reference signal. The layout of the PID controller is shown in Figure 4. To prevent the jittering of the control, a still state zone has been implemented around zero error, in which the controller is inactivated. The width of the zone has been determined by the characteristic of the detent mechanism in such a way that within this interval the mechanism should be able to compensate the error: , if e(t) > e th 0, otherwise (12) where e th is the threshold value.
To prevent the back and forth activation between the solenoid valves, a dead-zone is added to the control signal, where both valves are released. Outside of this interval, the activated solenoid valve is chosen based on the sign of the control signal as follows.
Because of the delayed effect of the control signal caused by the system's inertia, short and frequent solenoid valve commands are not effective. Once there is a change in any of the solenoid valve commands, it is forced to stay in its new state for 5ms. Besides greatly reducing the number of solenoid valve activations, this restriction makes it possible to activate both valves at the same time, which can help to stabilize the system, especially in case of Gear (L/H) to Neutral gear changes, as it can prevent overshoot.  The P and D parameters has to be tuned by a generic nonlinear programming solver, as common parameter tuning techniques, such as the Ziegler-Nichols method, could not provide acceptable results. The optimization aims to find those K p and K d parameters, which minimize the following function, where T shi f t is the shift time; v coll is the collision speed; n SV is the number of solenoid valve activations; x overshoot is the maximum overshoot; and w 1 , w 2 , w 3 , and w 4 are the performance weights.
As different requirements are depending on the type of the gear change (Neutral to Gear or Gear to Neutral), the applied weights are different for the various requests. As it has a direct effect on the vehicle's motion, the shift time has the highest performance weight, followed by the weights of overshoot and collision speed, which have the same order of magnitude. Although overshoot is much more critical regarding safety, it is already a strict limit, further increasing its weight significantly increases the gear change time. As it is a less severe requirement, the weight of the number of valve switches is the lowest.
The control parameters have been determined in a simulation environment for both the simulated and measured test cases. While the priority of the different requirements remained the same, the weights have been slightly modified based on the tests performed on the real target.
Regarding the results of the parameter tuning, the following conclusions are made, compared to "Gear to Neutral", "Neutral to Gear" shifts require lower derivative and higher proportional gains due to the pressure increase generated by the significantly decreased chamber volume, which helps dampen the collision. The difference of the control parameters between different directions is more significant between N2H and H2N, as the areas affected by the chamber pressures are more asymmetric at this side of the cylinder. Similarly, comparing N2H to N2L, and L2N to H2N, the P and D parameter values correspond to the affected piston areas.
The impact of components P and D on the control operation is shown in Figure 5. In the case of optimal parameters P and D, the gear change is performed without any overshoot. If the P is increased, while D holds at the optimal value, the movement becomes faster. However, at the same time a significant overshoot also emerges which has to be compensated by the controller. If P is reduced, even a small modification is sufficient to affect significantly the gear change. Halving the parameter means that the piston does not start to move and the short solenoid valve command is caused by the derivative term. Modifying the term D, while P holds at the optimal value, the behavior is the same, although the controller is less sensitive to the term D. Besides, time responses are affected by the discretization of the solenoid valves. The performances of the PID controller after parameter tuning in the MIL environment are summarized in Table 2.

Lqr Method
The LQR design aims to find the feedback control law, which minimizes the quadratic cost function: where Q and R are the weight matrices of the state error and the cost of the control, respectively. By solving the Ricatti equation, P is determined: Then, the feedback matrix is calculated as follows.
To design an LQR controller, a linear model is required, derived from the nonlinear model. However, the nonlinear model contains an unmanageable number of hybrid states, which increases the complexity of the linear state-space representation, therefore the following simplifications are necessary.
• Solenoid valve models are substituted with their mass flow rates, which will serve as the control signals • Chamber 3 pressure is assumed to be constant and equal to the ambient pressure • Heat transfer is neglected • Contact forces are neglected • Coulomb-friction is neglected • Detent mechanism is neglected Disregarding the contact forces was necessary as their derivatives would be discontinuous; therefore, they cannot be linearized, but the contact between the two pistons is not negligible regarding the actuator dynamics, thus it is taken into account as follows, With the given simplifications, the actuator behavior is described by eight hybrid states, the actual state-space representation is determined by the mass flow rates and the Main piston position. For LQR design, the chosen state variables are the pressure of Chamber 1 and Chamber 2, and the speed and position of the main piston, thus the state-space representation is a fourth-order system. The state vector is written as follows.
The control signals are the mass flow rates of the chambers: The output vector consists the chamber pressures and the main piston's position: As the modeled system is input-affine, its state-space representation takes the following form, where the vector functions can be written as follows, After linearization, the state-space representation is further simplified: (29) where the state matrices of can be written as shown in (30)- (32).
It is shown that, due to the applied simplifications, values of A FP , x FP (through them V ch1 and V ch2 ), and m MP depend on the sign of the Main piston's position, whereas T inw1 and T inw2 depend on the signs of the mass flow rates. Assuming the same ambient and supply temperature, the temperature of the flowing air changes as follows.
With the given assumptions and simplifications, the state-space representation describing the actuator's behavior can be written in a single form as (30)- (32), but the values of these matrices depend on the actual states indirectly through (19), (20), (21), and (33), which results in two versions of A and four versions of B matrices; therefore, it has eight hybrid states, where the actual state is determined by the mass flow rates and the Main piston position.
Besides, the state-space representation also depends directly on the state variables, thus the system is a quasi-linear parameter varying (qLPV) system. The given representation is basically a grid-based qLPV model, where the model is given as a set of LTI models defined at fix parameter values. The state-space representation of an LPV system takes the following form, where ρ(t) is a time-dependent vector of the scheduling parameters. Such a system is called a quasi-LPV system if the scheduling parameters depend on the actual states. In the presented model, the scheduling parameter vector contains the four state variables and the temperatures of the flowing air. While the presented state-space model is the continuous-time representation, it must be discretized in time. The linear-quadratic algorithm implemented in the MIL environment performed the linearization in the actual state and calculated the feedback matrix online, which had to be modified for the embedded application, as shown in Section 4.3.
It is conceivable that in case of the state-space representation, the condition of the BIBO stability is not met, while on the real system, only the mechanical constraints can guarantee stability and only in the three dedicated positions (H, L, and N). In H and L positions, the cylinder housing ensures stability. The main piston can be stabilized in N only under low pressure differences and low speed. Figure 6 shows the architecture of the LQR controller. Q matrix is used to weight the state error of the system, while R penalizes the control signal; therefore, it affects the number of solenoid valve switches. Increasing Q matrix weight helps with the shift time, but it increases overshoot and the collision speed due to the delay in the system. To guarantee the stability of the system in the dedicated positions, a relatively expensive control strategy is used. In the case of cheaper control strategies, the controller tries to load the corresponding chamber until it is too close to the request. As the contact is ignored in the state-space representation, it predicts an overshoot and during its compensation yields a highly oscillating piston position. In the case of the expensive control strategy, the controller releases the solenoid valves before reaching the request. Because of the pressure difference, the piston will eventually achieve its requested position. Consequently, the chosen strategy causes slightly longer shift times, but it reduces the number of valve switches and it takes advantage of the natural damping of the system caused by the decreasing volume of the counter-side chamber. The performances of the LQR controller after parameter tuning in the MIL environment are summarized in Table 3. As shown, it performs well in the case of Neutral to Gear gear changes, with similar shift time and collision speed to the PID controller, while it uses a single solenoid valve activation. However, it is not able to achieve Gear to Neutral changes, where the requested position is the switching point between two hybrid states.

Measurement System
As previously mentioned, the main goal is to design a system that can work in real-world conditions. The developed controllers were also tested on the system shown in Figure 7. A more detailed layout of the system is shown in Figure 8. The system contains a heavy-duty gearbox with four actuators (shift, select, split, and range), the corresponding clutch with one actuator, an ECU, and two electric motors to simulate the internal combustion engine and the road resistance. Each actuator includes two pressure sensors and a position sensor. The position sensor of the shift cylinder measures the position of the lower end of the shift finger, thus the reference signal was multiplied by the arm ratio.
While the developed controllers use only the position signal, the supply pressure, chamber pressures, and the solenoid valve commands are also measured to help with the tuning of the controllers. The control-related signals are measured with 1 ms sample time, while the pressure signals are measured with 2 ms sample time via XCP protocol. The measurement configuration is summarized in Table 4. In each test case, only a requested position (L/N/H) was given to the controller as input, thus similar to the simulations, the position request in the measurements was also a step function. The signals were measured with a Vector VN1630A device [34] and processed in CANape 14 [35]. First, the developed controllers were tested at constant 9 bar pressure; however, they should reliably operate at vehicles with different supply pressures or in the case of a decreased supply pressure due to compressor failure, thus the measurements were extended to pressures between 6 bar and 9 bar with 0.5bar resolution.   Table 4 also shows the limitations of the actuator control unit. Calculating the feedback matrices online requires iterative matrix calculations, which the ECU cannot solve in real-time with 1kHz frequency. It is possible to store the offline precalculated feedback matrices in the memory, as in the case of the LQR controller, though control techniques, such as H∞ controller and MPC controllers use an augmented state-space representation and the order of the control system is higher than that of an LQR controller, resulting in increased number of parameters. As will be shown in Section 4.3, even in the case of the LQR, a parameter sensitivity analysis must be performed to reduce the number of parameters. Higher-order controllers would require more parameters to store in the ECU memory; therefore, as the ECU memory is highly limited, rougher resolution is needed, which neutralizes the possibly better controller performance.
The controllers and the models have been implemented in Matlab/Simulink, then a C-code is generated using Simulink Coder, which is then compiled and downloaded to the ECU.

Pid Controller
After the first tests on the bench, the PID control strategy had to be reconsidered. The threshold limits and the parameters have been modified because keeping their original values could easily lead to an immensely high number of solenoid valve activations. The difference compared to the simulations can be explained by that the developed model-similarly to most of the pneumatic models-performs weakly in modeling the hysteric behavior. The effects of the modification were slightly worse overshoot and impact velocity, but also fewer solenoid valve activations. Figure 9 shows Neutral to High gear changes using the PID controller, performed on the real system. The first and second diagrams show the solenoid valve commands. The third and fourth diagrams show the chamber pressures, and the fifth diagram shows the Main Piston's position. The tests were taken on different supply pressures varying between 6 and 9 bars. It can be seen that the PID controller applies a solenoid valve command to set the piston into motion, then as the piston starts to move toward the requested position, it releases the solenoid valve. The drawback of this control strategy can be seen clearly: if the piston stops or slows down before reaching the request, the controller will not be able to compensate within the given gear change time. However, decreasing the derivative term compared to the proportional term resulted in much higher impact velocity and overshoot, whereas decreasing the still state caused a high amount of solenoid valve activations.

Lqr Controller
Implementing a linear quadratic controller in an embedded environment for the given system is a complex task, as the K feedback matrix is a function of A and B state matrices, which are functions of the system state and the disturbances. There were two possible solutions considered: the first one is to calculate the feedback matrix online; however, this could not be achieved in real-time with the given ECU. The other solution is to calculate the possible values of the feedback matrix K through the calculation of A and B offline, for the finitely many control problems. Therefore, K can be stored in a look-up table.
As taking into account all corresponding variables and storing the values of the whole K matrix would obviously exceed the capacity of the ECU, thus a parameter sensitivity analysis has been performed. As a result, three of the six variables have been neglected, only the temperatures of the flowing air and the main piston position have been taken into account, which also corresponds to the Q and R matrix weights. Due to the parameter sensitivity analysis, it is possible to store K matrix as function of these three variables, therefore there is no need to calculate A and B state matrices online. Besides, the rows of the feedback matrix would be multiplied by the error of the given state, and in this application, there is only a reference position provided to the controller, thus the error of the other states will be zero, which means that these values can be neglected. In this regard, the controller is used as an output feedback controller. Even in case of proper reference signals (which would be complicated to define), the value of the products of the given weights and the neglected errors would be smaller by at least two orders of magnitude, than the products of the position error and its weights, due to the applied Q and R weight matrices. Figure 10 shows Neutral to High gear changes performed by the LQR controller on the same set-up, and under similar conditions, the figure can be interpreted as Figure 9. The strategy of the LQR controller is similar to the PID controller, but it applies slightly longer solenoid valve activations, which helps with the quantitative requirements. Based on the controller testing, it was also seen that it is much less sensitive to the discretization than the PID controller.  Table 5 presents the intervals of the controller performances measured with supply pressure between 6 and 9 bar. Similarly to the simulations, the LQR controller failed in all Gear to Neutral shifts, as it either gets stuck in an intermediate position of the cylinder or clearly exceeds one of the given limits (for instance it achieves 6 mm overshoot or 200 ms shift time); thus, there is no need to analyze these cases, whereas the PID controller meets all the requirements in these test cases. To find the explanation of the failure of the LQR controller is an important task. The linearized models are both controllable and observable, and all individual controllers are stable. The high speed of the system may cause large transients during switching between the controllers around Neutral, which cannot be handled with the given control frequency in practice. However, as the controller achieved Neutral to Gear shifts with acceptable overall performances, it can be used for the high accuracy control of single-piston actuators. Therefore, in the current industrial application, this approach is not applied in this control task.

Discussion on Results
During Neutral to Low gear changes, both controllers performed well, but at first sight, the LQR control slightly exceeded the collision speed in the case of 9 bar supply pressure, while switching the actuator to Low. However, oppositely to the simulations, the exact position of collision is not known, as the movement of the mechanism is limited outside of the cylinder, thus the collision speed was assumed to be equal to the piston velocity at reaching 90% of the reference position. This way, the impact velocity is clearly overestimated, while its direct measurement was also not possible; therefore, against the small excess of the collision speed, the LQR controller shall be accepted. In the case of Low to Neutral and High to Neutral gear changes, only the PID controller were able to meet the requirements. Based on the results, there is a massive difference between the two gear change regarding shift time, which can be explained by the geometry of the cylinder. Due to the Floating Piston, the difference of the piston areas affected by the chamber pressures is much bigger between Neutral and High position of the actuator. Therefore, the High to Neutral gear changes are much faster, which causes overshoot. The last case is the Neutral to High gear change. As it was shown in Figures 9  and 10, there is no significant difference between the controllers, the LQR controller achieves slightly faster gear changes and higher collision speeds.
In industrial application, such systems are often controlled by Open-loop controllers, where the solenoid valve commands are determined as follows.

•
Switching to Neutral is achieved by loading both chambers at the same time. • Switching to Gear is achieved by the asymmetric activation of the solenoid valves, thus the collision speed can be minimized by increasing the opposite chamber's pressure.
Open-loop methods designed along these principles perform well concerning the collision speed and overshoot, as they significantly increase the counter-side chamber's pressure. Although, as this damping effect is applied at the start of the gear change, it will affect the whole movement, instead of only slowing down the piston at a later position, which results in slower overall movement and higher shift time. However, they always use two solenoid valve commands to achieve gear change. However, gear changes can be achieved much faster with a single valve activation due to the natural damping caused by the decreasing counter-side chamber volume and still meeting all of the requirements with the presented closed-loop controllers, while if it is needed they activate the counter-side chamber's valve at later position to prevent overshoot or high collision speed.

Conclusions
In this paper, two different types of position control design methods using electro-pneumatic gearbox actuators have been presented. The controllers are implemented in a MIL environment and tested on a gearbox bench under different supply pressures.
The industrial application raises the trade-off between costs and feasibility. In this case, the sampling time of the sensors and the computational limitations of the automotive ECU requires model reduction. It is also shown that simplifications must be performed during the modeling of double-acting floating piston cylinders to generate an eight-state 4th order qLPV model, which is handled by LTI control design methods.
Using model-based controller development, it is possible to predict the key features of the implemented controllers (e.g., the failed Gear to Neutral shifts with LQR method) and to estimate the performances well. The controlling purpose is to minimize the solenoid valve activations while the inaccurate modeling of the hysteresis is negligible, but, at the same time, the communication delays of the measurement system are taken into consideration.
Experimental results show that a gain-scheduled PID controller with adequate parameters and hysteresis achieves the position control of a pneumatic actuator with fast dynamics and unstable behavior. Although the LQR controller fails to meet the requirements in the case of Gear to Neutral shifts, it can be used effectively in pneumatic actuators without a floating piston.
The main disadvantage of these methods is that the control signals must be converted into solenoid valve commands. In the case of the PID controller, there is only one signal to control both solenoid valves, thus this signal must be discretized to provide four different combinations of solenoid valve states. The LQR controller is slightly easier to adapt as it has two outputs, which are mass flow rates. A possible method to discretize its outputs is to determine the maximum mass flow rates achievable by the solenoid valve. If the control signal exceeds a given percentage of the maximum value, the solenoid valve is activated. Based on the experience it can be declared that this discretization is at least as important as the control algorithm itself.
Further research will focus on LPV control design, which is an efficient method for handling of nonlinear systems and on neural network-based controllers for handling the environmental conditions. Funding: The research reported in this paper was supported by the Higher Education Excellence Program in the frame of Artificial Intelligence research area of Budapest University of Technology and Economics (BME FIKP-MI/FM).

Conflicts of Interest:
The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.

Abbreviations
The