====== Lab02 - Exteroceptive sensing: Reactive-based Obstacle Avoidance and Map Building ====== ^ Motivations and Goals ^ | Become familiar with direct sensory-motor control of the robot | | Become familiar with collision-avoidance and be aware of robot sensors | | Be able to implement reactive based control of mobile robot | | Learn principle of the occupancy grid map construction | ^ Tasks ([[courses:b4m36uir:internal:instructions:lab02|teacher]]) ^ | [[courses:b4m36uir:hw:t1b-react|T1b-react]] **(3 Points)** Implement collision avoidance system for autonomous reactive-based navigation of hexapod walking robot | | [[courses:b4m36uir:hw:t1c-map|T1c-map]] **(2 Points)**Implement function for updating the occupancy grid map using sensory data | ^ Lab resources ^ | TBD | ===== Reactive Navigation and Obstacle Avoidance Using Sensory-Motor Feedback ===== Reactive navigation assumes only a local knowledge about the environment. For the obstacle avoidance it uses only two motion primitives: * Follow a wall (i.e. avoid the obstacle) * Move towards the goal Well-known example of reactive obstacle avoidance is the [[http://www.cs.cmu.edu/~./motionplanning/lecture/Chap2-Bug-Alg_howie.pdf| bug algorithm]], which has three variants * **Tangent bug algorithm** * Head towards the goal * Follow obstacles until you can head to the goal again * Repeat * [[https://www.youtube.com/watch?v=SKelVC02S-U]] * {{:courses:b4m36uir:labs:tan_bug.png?150|}} * **Bug algorithm 1** * Head towards the goal * Circumnavigate obstacles and remember how close you get to the goal * Return to the point which was closest to the goal and head to the goal * Repeat * [[https://www.youtube.com/watch?v=Vm37TRRJAjc]] * {{:courses:b4m36uir:labs:bug1.png?150|}} * **Bug algorithm 2** * Head towards the goal along the straight line $m$ connecting start and goal * Circumnavigate obstacles until you encounter the $m$ line again * Continue towards the goal along the $m$ line * Repeat * [[https://www.youtube.com/watch?v=5MdKaZuXdfY]] * {{:courses:b4m36uir:labs:bug2.png?150|}} ===== AI Model of Braitenberg Vehicles ====== Braitenberg vehicles are very simple autonomous agents that use basic sensory-motor connections to produce seemingly cognitive behaviors (( [[https://mitpress.mit.edu/books/vehicles | V. Braitenberg, Vehicles: Experiments in synthetic psychology. MIT press, 1986.]] )). By adjusting the sensory-motor connections, the robots exhibit different behavior. The vehicle has a differential steering and two sensors at the front of the robot capable of sensing the quantity of a stimuli. Each sensor is directly connected to the actuator using sensory-motor connections based either on inhibition or excitation, which gives four basic behaviors. ^ ^ Vehicle 2a ^ Vehicle 2b ^ Vehicle 3a ^ Vehicle 3b ^ | | {{:courses:b4m36uir:labs:breitenberg_2a.jpg?direct&100}} | {{:courses:b4m36uir:labs:breitenberg_2b.jpg?direct&100}} | {{:courses:b4m36uir:labs:breitenberg_3a.jpg?direct&100}} | {{:courses:b4m36uir:labs:breitenberg_3b.jpg?direct&100}} | | **Connection** | excitatory | excitatory | inhibitory | inhibitory | | **Nick** | Fear | Aggression | Love | Explorer | | **Properties** | Avoids the stimuli | Intercepts the stimuli | Come to rest facing the stimuli | Come to rest facing away from the stimuli | A combination of individual vehicle types is referred to as **Vehicle 3c** that exhibit in a complex environment with several sources of stimulus complex and dynamic behavior that resemble a system of values (( [[http://users.sussex.ac.uk/~christ/crs/kr-ist/lecx1a.html|AI Lecture on Braitenberg vehicles]] )) Adding non-linear activation function to the sensors in **Vehicle 4** may produce even more sophisticated behaviors. ===== AI Model of Braitenberg Vehicles in Collision Avoidance ====== The robot senses the distance to the obstacles in front of it. Let the distance to the closest obstacle at the left and right halfplanes of the field of view represent the robot stimuli. Using Braitenberg vehicle model, this sensing can be directly translated into the control command. E.g., using **Vehicle 2a** the robot will avoid obstacles as it turns away of the stimuli, i.e., it fears the obstacles.