Public Member Functions | |
def | __init__ |
def | logerr |
def | loginfo |
def | logwarn |
def | shutdown |
def | spawn_robots |
def | spin |
Public Attributes | |
is_disabled | |
Private Member Functions | |
def | _establish_unique_names |
def | _extract_robot_types |
def | _launch_robot_clients |
def | _prepare_rocon_launch_text |
def | _send_flip_rules |
def | _spawn_simulated_robots |
Private Attributes | |
_cached_robot_type_locations | |
_concert_name | |
_gateway_flip_service | |
_invalid_robot_managers | |
_processes | |
_robot_manager | |
_robot_types | |
_robots | |
_temporary_files | |
_terminal | |
_world_name |
Gazebo Robot Manager.
This class contains all the robot-independent functionality to launch robots in gazebo, create concert clients for each robot, and flip necessary information to each concert client, so each robot can truly behave as a concert client.
Definition at line 63 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager.__init__ | ( | self, | |
world_name, | |||
concert_name | |||
) |
:param world_name: Gazebo World name
Definition at line 71 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._establish_unique_names | ( | self, | |
robots | |||
) | [private] |
Make sure robot names don't clash with currently spawned robots, or with other robots in the same list itself. If they do, postfix them with an incrementing counter. :param robots list of dicts[]: The parameter file defining robots and start locations. For a full description, see _spawn_simulated_robots(). :return [dict]: uniquified names for the concert clients.
Definition at line 175 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._extract_robot_types | ( | self | ) | [private] |
Definition at line 98 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._launch_robot_clients | ( | self, | |
robots | |||
) | [private] |
Spawn concert clients for given named robot. :param robot_names str[]: Names of all robots.
Definition at line 133 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._prepare_rocon_launch_text | ( | self, | |
robots | |||
) | [private] |
Definition at line 160 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._send_flip_rules | ( | self, | |
robots, | |||
cancel | |||
) | [private] |
Flip rules from Gazebo to the robot's concert client. :param robot_names str[]: Names of robots to whom information needs to be flipped. :param cancel bool: Cancel existing flips. Used during shutdown.
Definition at line 202 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager._spawn_simulated_robots | ( | self, | |
robots, | |||
robot_managers | |||
) | [private] |
Names and locations of robots to be spawned, read from a parameter file. :param robots list of dicts[]: The parameter file. The parameter file should read into a list of dictionaries, where each dict contains a "name" string, and a "location" tuple. For example: [{'name': 'kobuki', 'location': [0.0, 0.0, 0.0]}, {'name': 'guimul', 'location': [0.0, 2.0, 0.0]}] For a full definition of the location vector, see RobotManager.spawn_robot().
Definition at line 111 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager.logerr | ( | self, | |
msg | |||
) |
Definition at line 279 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager.loginfo | ( | self, | |
msg | |||
) |
Definition at line 276 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager.logwarn | ( | self, | |
msg | |||
) |
Definition at line 282 of file src/concert_service_gazebo/gazebo_robot_manager.py.
- Send unflip requests. - Cleanup robots in gazebo. - Shutdown spawned terminals.
Definition at line 254 of file src/concert_service_gazebo/gazebo_robot_manager.py.
def concert_service_gazebo.gazebo_robot_manager.GazeboRobotManager.spawn_robots | ( | self, | |
robots | |||
) |
Ensure all robots have existing names, spawn robots in gazebo, launch concert clients, and flip necessary information from gazebo to each concert client. :param robots list of dicts[]: The parameter file defining robots, type and start locations. For a full description, see _spawn_simulated_robots(). :type robots: [{name: str, type: str, location: (x,y,theta)}]
Definition at line 229 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 246 of file src/concert_service_gazebo/gazebo_robot_manager.py.
concert_service_gazebo::gazebo_robot_manager.GazeboRobotManager::_cached_robot_type_locations [private] |
Definition at line 98 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 98 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.
Definition at line 73 of file src/concert_service_gazebo/gazebo_robot_manager.py.