simple_script_server::simple_script_server Class Reference

Simple script server class. More...

List of all members.

Public Member Functions

def __init__
 Initializes simple_script_server class.
def add_object
 Add an object to the environment_server.
def attach_object
 Attach a known object to the robot's SDH.
def detach_object
 Detach an attached object from the robot's SDH.
def init
 Initializes different components.
def move
 Deals with all kind of movements for different components.
def move_base
 Deals with movements of the base.
def move_cart
def move_cart_planned
 Move to a simple pose goal - planned.
def move_cart_rel
def move_planned
def move_traj
 Deals with all kind of trajectory movements for different components.
def play
 Play a sound file.
def recover
 Recovers different components.
def remove_object
 Remove an object from the environment_server.
def say
 Say some text.
def set_light
 Set the color of the cob_light component.
def set_operation_mode
 Set the operation mode for different components.
def set_wav_path
def sleep
 Sleep for a certain time.
def stop
 Stops different components.
def trigger
 Deals with all kind of trigger services for different components.
def wait_for_input
 Waits for user input.

Public Attributes

 ns_global_prefix
 parse
 pub_light
 wav_path

Detailed Description

Simple script server class.

Implements the python interface for the script server.

Definition at line 160 of file simple_script_server.py.


Member Function Documentation

def simple_script_server::simple_script_server::__init__ (   self,
  parse = False 
)

Initializes simple_script_server class.

Parameters:
parse Defines wether to run script in simulation for graph generation or not

Definition at line 164 of file simple_script_server.py.

def simple_script_server::simple_script_server::add_object (   self,
  object_name,
  blocking = True 
)

Add an object to the environment_server.

Parameters:
object_name name of the object

Definition at line 1039 of file simple_script_server.py.

def simple_script_server::simple_script_server::attach_object (   self,
  object_name,
  blocking = True 
)

Attach a known object to the robot's SDH.

Parameters:
object_name name of the object

Definition at line 1093 of file simple_script_server.py.

def simple_script_server::simple_script_server::detach_object (   self,
  object_name,
  blocking = True 
)

Detach an attached object from the robot's SDH.

Parameters:
object_name name of the object

Definition at line 1120 of file simple_script_server.py.

def simple_script_server::simple_script_server::init (   self,
  component_name,
  blocking = True 
)

Initializes different components.

Based on the component, the corresponding init service will be called.

Parameters:
component_name Name of the component.

Definition at line 181 of file simple_script_server.py.

def simple_script_server::simple_script_server::move (   self,
  component_name,
  parameter_name,
  blocking = True,
  mode = None 
)

Deals with all kind of movements for different components.

Based on the component, the corresponding move functions will be called.

Parameters:
component_name Name of the component.
parameter_name Name of the parameter on the ROS parameter server.
blocking Bool value to specify blocking behaviour.

Definition at line 257 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_base (   self,
  component_name,
  parameter_name,
  blocking,
  mode 
)

Deals with movements of the base.

A target will be sent to the actionlib interface of the move_base node.

Parameters:
component_name Name of the component.
parameter_name Name of the parameter on the ROS parameter server.
blocking Bool value to specify blocking behaviour.

Definition at line 272 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_cart (   self,
  component_name,
  parameter_name = ["/base_link",
  blocking = True 
)

Definition at line 654 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_cart_planned (   self,
  component_name,
  parameter_name = [[0.0,
  blocking = True 
)

Move to a simple pose goal - planned.

  • recieves a cartesian pose (position, orientation) for 'arm_7_link' given in 'base_footprint' reference coordinate system
  • sends the goal to move_arm
  • move_arm will call the IK-solver
  • if configuration is found, the specified planner is called to find a collision-free trajectory
  • if successful the motion is executed

ADD-ON: use another parameter to specify the reference frame and do transformation in cob_script_server::move_cart_planned

Definition at line 713 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_cart_rel (   self,
  component_name,
  parameter_name = [[0.0,
  blocking = True 
)

Definition at line 700 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_planned (   self,
  component_name,
  parameter_name,
  blocking = True 
)

Definition at line 509 of file simple_script_server.py.

def simple_script_server::simple_script_server::move_traj (   self,
  component_name,
  parameter_name,
  blocking 
)

Deals with all kind of trajectory movements for different components.

A trajectory will be sent to the actionlib interface of the corresponding component.

Parameters:
component_name Name of the component.
parameter_name Name of the parameter on the ROS parameter server.
blocking Bool value to specify blocking behaviour.

Definition at line 375 of file simple_script_server.py.

def simple_script_server::simple_script_server::play (   self,
  parameter_name,
  blocking = True 
)

Play a sound file.

Parameters:
parameter_name Name of the parameter
language Language to use

Definition at line 993 of file simple_script_server.py.

def simple_script_server::simple_script_server::recover (   self,
  component_name 
)

Recovers different components.

Based on the component, the corresponding recover service will be called.

Parameters:
component_name Name of the component.

Definition at line 197 of file simple_script_server.py.

def simple_script_server::simple_script_server::remove_object (   self,
  object_name,
  blocking = True 
)

Remove an object from the environment_server.

Parameters:
object_name name of the object

Definition at line 1066 of file simple_script_server.py.

def simple_script_server::simple_script_server::say (   self,
  parameter_name,
  blocking = True 
)

Say some text.

The text to say may be given by a list of strings or a single string which points to a parameter on the ROS parameter server.

Parameters:
parameter_name Name of the parameter
language Language to use for the TTS system

Definition at line 924 of file simple_script_server.py.

def simple_script_server::simple_script_server::set_light (   self,
  parameter_name,
  blocking = False 
)

Set the color of the cob_light component.

The color is given by a parameter on the parameter server.

Parameters:
parameter_name Name of the parameter on the parameter server which holds the rgb values.

Definition at line 857 of file simple_script_server.py.

def simple_script_server::simple_script_server::set_operation_mode (   self,
  component_name,
  mode,
  blocking = True,
  planning = False 
)

Set the operation mode for different components.

Based on the component, the corresponding set_operation_mode service will be called.

Parameters:
component_name Name of the component.
mode Name of the operation mode to set.
blocking Service calls are always blocking. The parameter is only provided for compatibility with other functions.

Definition at line 837 of file simple_script_server.py.

def simple_script_server::simple_script_server::set_wav_path (   self,
  parameter_name,
  blocking = True 
)

Definition at line 1025 of file simple_script_server.py.

def simple_script_server::simple_script_server::sleep (   self,
  duration 
)

Sleep for a certain time.

Parameters:
duration Duration in seconds to sleep.

Definition at line 1149 of file simple_script_server.py.

def simple_script_server::simple_script_server::stop (   self,
  component_name 
)

Stops different components.

Based on the component, the corresponding stop service will be called.

Parameters:
component_name Name of the component.

Definition at line 189 of file simple_script_server.py.

def simple_script_server::simple_script_server::trigger (   self,
  component_name,
  service_name,
  blocking = True,
  planning = False 
)

Deals with all kind of trigger services for different components.

Based on the component and service name, the corresponding trigger service will be called.

Parameters:
component_name Name of the component.
service_name Name of the trigger service.
blocking Service calls are always blocking. The parameter is only provided for compatibility with other functions.

Definition at line 207 of file simple_script_server.py.

def simple_script_server::simple_script_server::wait_for_input (   self,
  duration = 0 
)

Waits for user input.

Waits either for a user input or until timeout is reached.

Parameters:
duration Duration in seconds for timeout.
Todo:
TODO: implement waiting for timeout

Definition at line 1167 of file simple_script_server.py.


Member Data Documentation

Definition at line 166 of file simple_script_server.py.

Definition at line 168 of file simple_script_server.py.

Definition at line 171 of file simple_script_server.py.

Definition at line 167 of file simple_script_server.py.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerator


cob_script_server
Author(s): Florian Weisshardt
autogenerated on Fri Jan 11 09:35:40 2013