MARIE 0.5 splitter

From MARIEWiki

Jump to: navigation, search

Contents

Version

0.5

Description

This adapter is used to transmit data coming from port in one group to each port in the other group. It is typically used to send data from one source to multiple sources without having the sender knowing each receivers.

It is important to note that incoming data are repeated in connection registration order and that new incoming data will be send only after having completed last transmission. This can lead to data being lost or communication jam if repeating frequency is too slow for new data frequency.

splitter.jpg


Requirements

None

Modes

This adapters defines inputs and outputs depending on which group ports are assigned (groupA or groupB) and the data flow mode.

Data flow modes :

  • AB : one way, GroupA to GroupB
  • BA : one way, GroupB to GroupA
  • ABBA : bi-dir

Configuration

Note : see Configuration Description Language for syntax details.


# C splitter
   # KV mode 
   
   # Q groupA
      1-N T port
   
   # Q groupB
      1-N T port
       
  • mode : Splitter mode (AB, BA, ABBA)

Note : splitter doesn't check data integrity unless ports are configured to use data parser.

See available Ports for port configuration details.

Usage

usage :  splitter -n component_name [-t component_type] [-d director_port_number] [-c configurator_port_number] 

      -n     #Specify component's name
              
      -t     #Specify component's control type :
             #  DEFAULT - use when controlled by appman Application Manager (default)
             #  MPI     - use when controlled by ammpi Application Manager
              
      -d     #Specify director server socket port number (mandatory in DEFAULT component's control type)
      -c     #Specify configurator server socket port number (mandatory in DEFAULT component's control type)


Executing aacarmen in project

This section shows how to use splitter in Project..

In .setup file, add the following processes :

# T process
   # KV name
   # KV type = MARIE:MPI
   # KV executableName = splitter
   
   # KV configFile 

  • name : Specify a reference name for the process
  • type : Specify component's control type
  • executableName : Specify the executable name
  • configFile : Specify path to aafd configuration file (see Configuration)


Executing aacarmen with appman [deprecated]

This section shows how to use splitter with appman Application Manager from a terminal script.


Start component

splitter -n component_name -t MARIE -d director_port_number -c configurator_port_number
sleep 4    # Sleep time (plateform specific)

appman -p configurator_port_number -c sxml:PathToConfigFile
sleep 1    # Sleep time (plateform specific)

appman -p director_port_number -c init
sleep 1    # Sleep time (plateform specific)

appman -p director_port_number -c start

Component can take couple of seconds to boot, configure and initialize before being ready to receive requests on director and configurator ports. Delays are required and must be adjusted depending on the running platform.


Stop component

appman -p director_port_number -c stop
sleep 1    # Sleep time (plateform specific)

Component can take couple of seconds to stop before being ready to receive requests on director and configurator ports. Delay is required and must be adjusted depending on the running platform.


Quit component

appman -p director_port_number -c quit


Authors

  • Carle Cote
  • Martin Guillemette


Contributors

License

MARIE - Mobile and Autonomous Robotics Integration Environment Copyright (C) 2004-2006 Carle Cote, Martin Guillemette

This library and its documentation are free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

This library and documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You can contact MARIE development team at http://marie.sourceforge.net.


Personal tools