Logitech G29 steering wheel controller as a signal source for the power steering model
In this example, we continue to consider the operation of the Engee power steering model. At the next stage, we are qualitatively moving to a new level of model-oriented development: instead of idealized source data - turn angle signals, we use data coming from the human-machine interface (steering wheel controller) in pseudo-real time mode.
Introduction
The power steering system converts the driver's force into hydraulic pressure, making it easier to turn the wheels. It is used in cars for comfort and to reduce the load on the driver. Besides the fact that the steering wheel reduces the physical effort when turning the steering wheel, this system also improves the accuracy and smoothness of control.
At the first stage of the development and debugging of the power steering model in Engee, we recreated the transmission contours of mechanical and hydraulic influences, investigated the operation of the model with the power steering on and off using idealized input values. At the current stage of development, by connecting external equipment to Engee, we use data coming from the human-machine interface (steering wheel controller).
Preparation for work
Before launching the model in Engee, several preparatory steps must be performed, as described in the manual.
In addition, similar preparation steps can be found in an example of working with COM-портом. After successfully connecting to Engee, you can proceed to connecting the equipment.
Connecting equipment
The Logitech G29 Racing Steering wheel controller** connects directly to the computer and is identified by the system. For most modern operating systems, it is detected and installed automatically.
If the device is successfully connected, you can proceed to running the sample model.
The example model
The principles of operation of the initial model are described in example.
The model of the current example - logitech_g29_power_steering.engee. Unlike the original one, it gets the real values of the steering wheel angle (variable steering) and enabling/disabling the power steering (variable button_enter). Their source is the Logitech G29 Wheel unit from the [Hardware] section (https://engee.com/helpcenter/stable/ru/engee-hardware.html ) -> Wheel of the Engee block library.
Additional subsystems are used to process incoming signals.:
- "Steering wheel rotation speed" - the value of the steering wheel rotation speed is calculated and filtered from the steering angle signal, as required for the initial model. The filter type is continuous, low-pass of the 1st order with a time constant .
- "Power steering shutdown" - upon the active signal of pressing the "Enter" button on the steering wheel, switches the value of the feedback amplifier coefficient from the previously defined value to "0". This helps to disable the power steering. For the stability of the model, this feedback is also equipped with a filter similar to the previous subsystem, but with .
The model runs in [pseudo-real-time] mode (https://engee.com/helpcenter/stable/ru/tutorial/settings-engee.html#features ) - we control the simulation speed of the model by a factor of 1.0 using the appropriate setting. This setting simulates the real-time operation of the model. To test the model in hard real-time mode, you should use the real-time test bench времени based on the KPM RHYTHM semi-natural modeling complex
Simulation results
After starting the model and changing the rotation of the steering wheel controller, you can observe a change in the angle of rotation of the car's wheels (blue graph) similar to that set on the G29 controller (red graph). When you press the "Enter" button, you can observe how the angle of rotation of the wheels begins to lag relative to the set rotation. This indicates that the power steering is disabled during the simulation process.
For further development of the model, additional control channels can be added, for example, for the speed of rotation of the power steering pump and liquid pressure control.
Conclusion
In this example, we have improved the GUR model by connecting real equipment to transmit the angle of rotation of the wheels directly from the operator. In addition, the connection of the equipment allows you to adjust not only the input values, but also the parameters and structure of the control object - switching on and off the power steering, regulating the pressure of the working fluid. At the next stage, you can proceed to testing the GUR in hard real-time mode.