Design and Implementation of Fuzzy Logic Controller for Online Computer Controlled Steering System for Navigation of a Teleoperated Agricultural Vehicle

This paper describes design,modeling, simulation, control, and implementation of teleoperated agricultural vehicle using intelligent technique. This vehicle can be used for ploughing, sowing, and soil moisture sensing. Online computer controlled steering system for a vehicle utilizing two independent drive wheels can be used to avoid obstacles and to improve the ability to resist external side forces. To control the steer angles of the nondriven wheels, the mathematical relationships between the drive wheel speeds and the steer angles of the nondriven wheels are used. A fuzzy logic controller is designed to change the drive wheel speeds and to achieve the desired steer angles. Online control of the agricultural vehicle is achieved from a remote place bymeans ofWeb Publishing Tool in LabVIEW. IR sensors in the vehicle are used to detect and to avoid the obstacles around. The developed steering angle control algorithm and fuzzy logic controller have been implemented in an agricultural vehicle which depicts that the vehicle performs its operation efficiently and reduces the manpower and becomes advantageous.


Introduction
The diminishing number of agricultural wages in India is a momentous issue for Indian agriculture.Robot tractors have been introduced to replace human labors for field work and for improving work efficiency.However, robot tractor needs safety devices to ensure safe operation when it is not operated by a human.Therefore, the safety issue is an important research topic for agricultural robots when utilized on a farm [1].
Numerous studies on the automation of agricultural machines, particularly on a solution of this problem, have been carried out.Autonomous navigation and vehicle guidance, a global positioning system (GPS), a gyroscope, machine vision, and other sensors have been used in most of those studies [2][3][4].
Sgorbissa and Zaccaria [5] have proposed a navigation subsystem of a mobile robot which operates in human environments to carry out different tasks, such as transporting waste in hospitals or escorting people in exhibitions.This approach integrates prior knowledge of the environment with local perceptions to carry out the given tasks efficiently and safely.They had discussed the properties of their approach and experimental results recorded during real-world experiments.
Murakami et al., [6] have presented a teleoperation system for a hydrostatic transmission drive crawler type robotic vehicle.Their system was developed to satisfy the needs of various farm operations and teleoperation in unknown agricultural fields.
There are two vital issues to be resolved for developing a safety device for a teleoperated agricultural vehicle; one is to detect an obstacle surrounding the vehicle and the other one is to determine the location of the obstacle.The performance of various sensors for detecting obstacles has been investigated in recent studies to improve the safety of an autonomous vehicle or assist human driving.Noguchi et al. [7] have introduced a master-slave robot system in which a wireless local area network was utilized to broadcast the GPS position of a slave robot to a master robot, so that the master and slave robots could work together without collision of two robot tractors but could not detect other objects except the robot.In order to identify general obstacles, radar and stereo vision were used in some studies for automobiles [8,9].A laser scanner was used to identify and locate other vehicles working in the same field with the robot [10].In addition, ultrasonic sensors [11] and a bumper switch were mounted in front of robot tractor as a safety system.In those previous studies, a laser scanner, radar, and an ultrasonic sensor were used as a range finder because these sensors can determine distance to the obstacle with a high accuracy.
Knudson and Tumer [12] have evaluated reactive and learning navigation algorithms for exploration robots that avoid obstacles and reach specific destinations in limited time and with limited observations.This method uses neuroevolutionary based navigation.Neuroevolutionary approach is policy search method where control is achieved through a search across policies.This search through a population of policies allows the discovery of new and robust control strategies.
Direct current (DC) motors are broadly used in conveyors, textile mills, paper mills, position control, and robotic manipulators because they are reliable for an extensive range of operating conditions and their control is fairly simple.Usually DC motors are modeled as linear systems and controlled by linear control approaches.However, most linear controllers give unsatisfactory performance due to changes in the control parameters, loading conditions, and nonlinearities introduced by the armature reaction.When these nonlinearities of the motor are known functions, then adaptive tracking control method can be used [13,14].If these nonlinearities of the motor are unknown, neural or fuzzy control is suitable for ensuing satisfactory performance of the closed loop system [15][16][17][18].Senthil Kumar et al., [19] have designed an artificial neuron controller for chopper fed embedded DC drives.The designed neuron controller reduces the steady state error, overshoot, and settling time.
The objective of this work is to develop a teleoperated agricultural vehicle which can be used for ploughing, sowing, and soil moisture sensing.Online computer controlled steering system for the vehicle is described and a fuzzy logic controller is designed to achieve steering control based on obstacle and boundary information of the agricultural land.The mathematical relationships between the drive wheel speeds and the steer angles of the nondriven wheels are used to calculate and control the steer angles.The developed fuzzy logic controller controls the speeds of DC motors connected with rear wheels of the agricultural vehicle to achieve the desired steer angle.Using the proposed approach, a teleoperated agricultural vehicle is controlled from a remote place.Infrared (IR) sensors are employed to detect the obstacle.The status of IR sensor helps path planning and changing the direction of the vehicle.Data transmission between the agricultural vehicle and the remote client is achieved by means of Web Publishing Tool.To accomplish this goal, a soil moisture sensor, a stepper motor, and

Architecture of the Proposed System
Figure 1 shows the hardware structure of the proposed system.The system consists of DC motors, stepper motor, soil moisture sensor, IR sensors, and a solenoid valve.Soil moisture sensor is used to measure the moisture content of the land.The obstacles around the vehicle are detected using IR sensors.The seed box open and close operation is controlled by solenoid valve during sowing operation.
Stepper motor is used to control the up and down movement of ploughing tool.The depth of ploughing can also be controlled by this stepper motor by varying its step angle.The steer angles of the nondriven wheels are controlled by two DC motors connected with the rear driven wheels of the vehicle.Based on the desired steering angle values, the desired speed values of the DC motors are calculated by using the developed algorithm.The speeds of the DC motors are controlled to the desired value by the designed fuzzy logic controller.
The length and width of the agricultural land are measured.The time taken by the vehicle to travel a particular length is determined.Based on this determined time value and the length of the land, the time taken by the vehicle to reach one end of the land to the other end is calculated.The timer value is set to this calculated time value to navigate the vehicle in forward direction.For this calculated time period, the vehicle moves in forward direction, subsequently turns left, and moves in forward direction for the same period and then it turns right and moves forward.Thus by using the time taken by the vehicle to travel the length once, wheel track, and the width of the land, its navigation and steering control actions are repeated.

Experimental Setup
The hardware prototype set-up of the teleoperated agricultural vehicle is shown in Figures 2 and 3.The developed fuzzy logic controller and the control algorithm for ploughing action and solenoid valve were implemented using ATMEL 89C51 microcontroller.A two-way normally closed electromechanical solenoid valve is used to control the flow of seeds.The solenoid valve is energized by a normally closed relay.When the relay is energized, it comes to normally opened position.In this relay position, the solenoid valve is energized and it opens to drop the seeds.By increasing or decreasing the frequency of energization of relay circuit, the distance between the seeds can be increased or decreased.A 12 V stepper motor is used to adjust the position of ploughing tool.By controlling the stepping angle of the stepper motor, the ploughing tool position is being controlled.The navigation speed and steering angle control are achieved by two 12 V DC motors connected with two independent drive wheels.The stepper motor and DC motors are supplied by a 12 V, 7 Ah sealed lead acid battery.A soil moisture sensor is used to measure the moisture content of the soil.The measured value is displayed using LCD display.

Fuzzy Logic Controller
General proportional integral (PI) and proportional integral derivative (PID) controllers are extensively used for motor control applications.But they do not give satisfactory results when control parameters, loading conditions, and the motor itself are changed.But fuzzy logic controller can be designed without the exact model of the system.This approach of fuzzy logic controller (FLC) design guarantees the stable operation even if there is a change in the parameters and the motor [20].
Fuzzy logic control is derived from fuzzy set theory introduced by Zadeh in 1965.In fuzzy set theory, the transition between membership and nonmembership can be gradual.Therefore, boundaries of fuzzy sets can be vague and ambiguous, making it useful for approximate systems.Fuzzy logic controller (FLC) is an attractive choice when precise mathematical formulations are not possible [21].
The designed fuzzy logic controller has two inputs and one output.The inputs are error value and change in error  and the output is duty cycle.The seven linguistic variables used for "error" and "change in error" are NVB (negative very big), NB (negative big), NM (negative medium), NS (negative small), Z (zero), PS (positive small), PM (positive medium), PB (positive big), and PVB (positive very big).The duty cycle output uses seven linguistic variables like NVB (negative very big), negative big (NB), negative medium (NM), negative small (NS), zero (Z), positive small (PS), positive medium (PM), PB (positive big), and PVB (positive very big).The rule table for the designed fuzzy logic controller is given in Table 1.
From the rule table, the rules are manipulated as follows.
If error is NS and change in error is PB, then output is PM.The symbolic expression of th rule of the designed fuzzy logic controller is given as follows.
The meaning of the above defined th rule in terms of mamdani type implication is given as a fuzzy relation  () as follows   () (, Δ, Δ) =   () () Λ Δ () (Δ) Λ Δ () (Δ) . ( The overall conclusion by combining the outputs of all the fuzzy rules can be written as   (, Δ, Δ) =   (1) (, Δ, Δ)   (2) (, Δ, Δ) The value of   () for each value of  is defined in (2).The crisp value of change in duty cycle is computed using centre of area method as follows: where  * is defuzzified duty cycle,  is duty cycle output, and   () is Union of the clipped control outputs.

Mathematical Model for Steering System
Figure 4 represents kinematic model of the proposed agricultural vehicle with a primary steering system using two independently driven wheels. L and  R are the wheel speeds of the rear left and rear right drive wheels, respectively.Φ L and Φ R are the steer angles of the front left and front right wheels, respectively. is the wheel base.  is the track of the rear wheels and   is the track of the front wheels. is the radius of the turning circle of the vehicle (radius of curvature) [22].
The rate of rotation of the drive axle about the centre of curvature is given by where  is radius of the turning circle of the vehicle (radius of curvature),  L is translational velocity of the left drive wheel,  R is translational velocity of the right drive wheel,   is the track of the rear wheels, and   is the track of the front wheels.
If longitudinal slip is considered, the translational velocities become where  is radius of a drive wheel, and  is longitudinal slip When we substitute (6) in(5) The centre of curvature When the longitudinal slips are equal for left and right drive wheels, as well as equal radius for the drive wheels, then Equal longitudinal slips will occur where traction conditions are the same and under these conditions, slip angles will not be significant.For the front left steerable wheel, Similarly, for the front right steerable wheel, If   =   , ( 9) and ( 10) will be simplified as given in (11), and (12), respectively,

Calculation of Drive Wheel Speed for Steering Control
If both drive wheels turn with same speed, the robot moves in a straight line.If one wheel rotates faster than the other, the robot follows a curved path inward towards the slower wheel.
If the wheels turn at equal speed, but in opposite directions, the robot spins around.Thus, steering the robot is just a matter of varying the speeds of the drive wheels.These drive wheel speeds are calculated from the steer angles Φ L and Φ R .

Calculation of Drive Wheels Speed to Turn the Vehicle Left.
To turn the vehicle left, the left wheel speed should be less than the right wheel speed.Hence the left wheel speed is assigned with some low speed value and the expression for desired right wheel speed  DR is derived from the steering angle Φ L of left steerable wheel.
Let  L = 1 rpm; then, (9) will be tan From ( 13), the desired right wheel speed can be written as

Calculation of Drive Wheels Speed to Turn the Vehicle
Right.To turn the vehicle right, the right wheel speed should be less than the left wheel speed.Hence the right wheel speed is assigned with some low speed value and the expression for desired left wheel speed  DL is derived from the steering angle Φ R of right steerable wheel.Let  R = 1 rpm and then (10) will be From ( 15), the desired right wheel speed can be written as

Computer Simulation and Teleoperation
The simulation of online computer controlled steering system for a teleoperated agricultural vehicle is done based on equation modeling using LabVIEW.Flow chart of the proposed control algorithm is given in Figure 5.The simulated models are shown in Figures 6, 7, and 8.The simulation of computer controlled steering system was done with a fuzzy logic controller.Online control is achieved from remote place using Web Publishing Tool in LabVIEW.This tool is used to create an HTML document and embed static or animated images of the server computer's front panel in an HTML document as shown in Figures 9 and 10.When the HTML document is created, URL is generated as shown in Figure 11.Using this generated URL, a remote user can view and control the front panel remotely by a web browser.

Experimental Results
The developed fuzzy logic controller and the control algorithm for ploughing action and solenoid valve were implemented using ATMEL 89C51 microcontroller.The drive wheels speeds are controlled by two 12 V DC motors.By using the proposed control algorithm, the speeds of these DC motors are controlled and measured values are plotted in the graph.The experimental response of left and right DC motors

Conclusion
In this paper, a teleoperated agricultural vehicle capable of performing ploughing, sowing, and soil moisture sensing was successfully developed.Two independent drive wheels installed on the vehicle are used for motion and steering control.The developed fuzzy logic controller controls the steering angle of the teleoperated vehicle according to the desired steering angle.Using the proposed agricultural vehicle depth of ploughing and the distance between the seeds can be varied.By measuring the moisture content of

Figure 1 :
Figure 1: Hardware structure of the proposed system.

Figure 2 :
Figure 2: Top view of hardware prototype of the developed teleoperated agricultural vehicle.

Figure 3 :
Figure 3: Elevation of hardware prototype of the developed teleoperated agricultural vehicle. b

Figure 4 :
Figure 4: Kinematic model of the proposed agricultural vehicle.

Figure 5 :
Figure 5: Flow chart of the control algorithm.

Figure 6 :
Figure 6: Block diagram of the simulated fuzzy logic control system for a teleoperated agricultural vehicle.

Figure 7 :
Figure 7: Block diagram of the simulated steering angle control system to turn the vehicle left.

Figure 8 :
Figure 8: Block diagram of the simulated steering angle control system to turn the vehicle right.

Figure 9 :
Figure 9: Configuration of server computer for remote clients using Web Publishing Tool in LabVIEW.

Figure 10 :
Figure 10: Configuration of server computer for remote clients using Web Publishing Tool in LabVIEW with header and footer details.

Figure 11 :
Figure 11: URL generation by the HTML document.

Figure 12 :Figure 13 :
Figure 12: Graph of actual speed values of left motor and right motor when the agricultural vehicle moves in forward direction with the set speed value of 10 rpm.

Figure 14 :Figure 15 :
Figure 14: Graph of actual speed values of left motor and right motor when the agricultural vehicle turns in left direction.