Design of a Real-Time System of Manual Control of the Simulated Truck Motion
Design and implement a real-time system providing manual control of the simulated motion of a truck. Mathematical model of the dynamics of a truck and necessary parameters are given in Appendix 1 (see (4.1)-(4.4), (4.6)-(4.14), Table 1).
It is necessary to implement a program with the following functionalities:
Provide user interface via which the parameters of the model can be entered and modified (see Table 1, the rows with defined values)
Provide control means for a driver:
Start/stop engine work (“on” corresponds to “power supply on”, and “off” – to “power supply off”. In “on” state, engine torque meets (4.12), (4.13), and in “off”, it is equal to 0. A pressed button may be used for “on”, and depressed – for “off”)
Start/stop engine starter (pressed button may be used for “start”, and depressed – for “stop”, see (4.1), (4.3), (4.4), Table 1, row 22; value of &#957; is controlled by the button)
Connect/disconnect engine from the load using &#956; value (a slider may be used to show the value, see (4.1), (4.2), (4.6) using &#956;)
Increase/decrease engine torque (a slider may be used to show the value, see Figure 3.5, (4.12), (4.13), (4.14))
Increase/decrease brake torque (a slider may be used to show the value, M_(fr:&#969;); see Table 1, row 15, (4.11))
Respective values input by the user must be used in the truck model immediately after they are defined and should affect the next behavior of the truck.
Provide output and log of the following information about the current state of the truck
Angular engine velocity
Speed of the truck
Degree of engine-wheel connection (&#956;)
Current road slope angle
Provide relief of the road (slope angles for different intervals of the road). Total relief length should be 3 (three) km, and it shall have three 1 km parts with different slopes: 0, negative, and positive with angles from the range specified in Appendix 1, Table 1, row 21.
Provide graphical output of the dynamic image of the truck moving along the road with the rate of refreshing of the screen at least 10 times/s
The system of two second order ordinary differential equations solution of which gives engine angular velocity and wheel angular velocity must be solved by any numerical method such as Euler or fourth order Runge-Kutta methods. Time step should be selected so that with twice decreased time step solution is practically the same. There should be at least 10 time steps inside one period of engine revolution.