mkeari / mobile_robot

2D Mobile Robot for destination following and obstacle avoidance

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

2D Mobile (Differential-Drive) Robot: Goal following with obstacle avoidance

Installation

In order to run the code,

  1. Install the required packages:
  • matplotlib
  • numpy
  1. Run the main script file
python main.py

Configuration

In the beginning of the main.py, the user can modify some of the environment settings:

p_initial = [12, 4]         #Initial position of the robot
theta_initial = 3           #Initial orientation of the robot

R_initial = 0.2             #Radius of robot wheels
L_initial = 1.5             #Length of robot base
dT_initial = 0.05           #delta Time (the framing frequency for plotting)

robot_speed = 5             #Base speed of the robot
prox_sensor_radius = 0.5    #Radius of proximity sensor domain

p_light = [18, 18]          #Position of light source

obstacle_radius = 1.5       #Radius of the obstacles
p_obstacles = [[6, 7],      # Centre coordinates of the obstacles
               [5, 16],
               [14, 8],
               [18, 3]]

Additional example animations:

About

2D Mobile Robot for destination following and obstacle avoidance

License:MIT License


Languages

Language:Python 100.0%