Skip to content
This repository was archived by the owner on Mar 17, 2020. It is now read-only.

Architecture

Diogo Cruz edited this page Nov 16, 2018 · 3 revisions

The robot has a minimalist design. It uses only five sensors to track the wall and only allows rotations and forward movement.

As the environment is static, the sensors were mounted to detect the wall on the front and on the sides. To simulate real sensors, the implemented sensors have a minimal range that is 25% of the diagonal distance to the wall that it can detect.

Lateral movement was not implemented since it would make the task easier but, in real-life, would mean a higher cost.

Per the intended design of ROS, the system works in a set of distributed nodes and channels (ROS Topics). The STDR server alongside ROS itself are the core nodes of operation, to the server, we assign it a map and how many instances of the robot will be spawned within, outside of STDR, we attach a processing node to each one of the robots, namely the script “avoid_wall” from our source package, which performs the analysis of the data obtained by the robot's sensors and tells it the movement it should perform in response.

How the system nodes interact with each other

The robots have a laser sensor with 5 beams spanning over a 180º angle, effectively giving it 5 proximity sensors.

The robot as seen in the STDR graphical interface

Each beam of the laser is labeled according to its direction when compared against a compass, from West to East in a clockwise direction. The robot operates on the concept of a state of “Orbit”. Namely, before reaching close to a wall, it will act as “Out of Orbit” and will move forward until it reaches a wall. Upon reaching a wall, it will then assume an orbit either to it’s left or right, moving counterclockwise or clockwise around the wall respectively, based on which of it’s west or east side is closer.

The robot operates on the following premises, considering a preset range of which a reading will track an obstacle if it is close:

  1. If not orbiting, it will move forward until any of it’s sensors detect the presence of a wall.
  2. After detecting a wall, it will try to check if either the “W” or “E” sensors are within range of it. If so, it assumes the respective orbiting mode.
  3. If a orbiting mode is unassigned, it will rotate towards the way either the “NW” or “NE” sensors point a wall is closer, and then repeat step 2.
  4. When on orbit it will move on the following circumstances:
    • If “N” doesn’t signal a wall, it will move forward.
    • If “NW/NE” and “W/E” signal a wall, it will rotate away from it.
    • If “W” and “E” both signal a wall, it will rotate again away from it. This happens when stuck between two walls and it no longer has space to move safely.
    • If no sensors capture a wall, it will maintain the rotation.

Clone this wiki locally