Difference between revisions of "Modules - Standard v0.1"

From Asibot & HOAP3 & TEO Wiki
Jump to navigation Jump to search
 
(16 intermediate revisions by the same user not shown)
Line 1: Line 1:
This page should contain guidelines for designing new modules for the software architecture. The intention of this is to keep internal coherence and compatability with RoboticsLab robot modules who follow this standard. A list of available modules can be found at the [http://163.117.150.71/w/index.php/A_Description_of_Modules description of modules] page.
+
'''<u>Important Notice</u>: This standard has been replaced by [[Modules - Standard v0.2]].'''
 +
Most prominent changes are the use of tags in commands, and dropping _io, _i, _o suffixes.
  
* Each directory in the trunk folder structure should contains modules that represent the same single block in the control block diagram.
+
The intention of this standard is to keep internal coherence and compatability with RoboticsLab robot Modules which follow this standard. It is intended to be a description of existing and future modules, their interfaces and data flow representation. For a debate on open issues, go to the [http://roborepo.uc3m.es/w/index.php/Talk:A_Standard_for_Modules discussion tab]. Port interface is referred to TCP/UDP/MCAST/SHMEM ''cloud'' side, not CAN or USB (that can coexist in hardware-related modules).
* Interfaces should be the same throughout all the modules in the same directory, to assure interchangability.
 
* When the module is a hardware interface, it is recommended to create a dummy (fake) module too for debugging purposes of other modules in absence of hardware component or simulator equivalent.
 
* Each module name should contain (in order, lower-cased, and separated by underscores):
 
** A three letter prefix that represents the name of the parent directory.
 
** A description of its implementation.
 
* Each port should contain:
 
** The description of the module implementation.
 
** The short-nomenclature data type identifier.
 
* Each internal variable related with communication (bottle, int...) should contain:
 
** The descriptor such as 'bottle', 'int'...
 
** The short-nomenclature data type identifier.
 
** The I/O identifier: 'i' for input, 'o' for output, 'io' for input/output.
 
  
\** Example **\
+
Nomenclature: D for double, I for integer, S for string.
Parent Directory: drivers
 
  Module: drv_fake
 
  Ports: fake_q
 
  Internal Parameters: bottle_q_i, bottle_q_o, double_q_i[], double_q_o[]...
 
  
== Recommended module folder structure ==
+
== drivers ==
 +
These modules should recieve joint position commands, in relative and absolute degrees.
 +
Module: drv_''name''
 +
Ports: ''name''_q_io
 +
  - Data: bottle_q_i "I:code D:Q1pos ... D:Q''n''pos D:Qgenvel"
 +
  - Data: bottle_q_i "I:code D:Q1vel ... D:Q''n''vel"
 +
  - Data: bottle_q_o "I:code D:Q1pos ... D:Q''n''pos"
  
The intention of defining this should be for each project to be self-contained. Each module directory should contain the following structure (full implementation is not necessary):
+
Code:
* doc/
+
  - -1: Stop
* extern/
+
  - 0: Encoder read
** bin/
+
  - 1: Relative position with wait
*** linux-x86/
+
  - 2: Absolute position with wait
*** win32/
+
  - 3: Relative position without wait
*** ...
+
  - 4: Absolute position without wait
** include/
+
  - 5: Velocity without wait
** lib/
+
  - 5''x'': Syncronize motor ''x''
*** linux-x86/
 
*** win32/
 
*** ...
 
* mk/
 
** msvc9/
 
** linux-x86/
 
** ...
 
* out/
 
** data/
 
** win32/
 
** linux-x86/
 
** ...
 
* src/
 
* AUTHORS
 
* INSTALL
 
* install-win32.txt
 
  
Notes:
+
* svn co http://roborepo.uc3m.es/svn/ASIBOTcoderepo/trunk/drivers/drv_can
* A project generating shell script has been developed for this purpose.
+
<!-- ** TODO: Must adapt to this new standard. -->
** svn co http://163.117.201.41/svn/ASIBOTcoderepo/trunk/tools/mkproy
+
** TODO: 5: Velocity without wait
* extern/ is intended for 3rd party libraries.
+
 
* data/ is intended for inclusion of multiplatform (shared) data for execution of the program, such as 3d models, etc...
+
 
* out/win32/, out/linux-x86, etc, must contain the platform-specific shared libraries and other complements necesary for the execution of the resulting application or library.
+
* svn co http://roborepo.uc3m.es/svn/ASIBOTcoderepo/trunk/drivers/drv_marilou
 +
<!-- ** TODO: Must adapt to this new standard. -->
 +
 
 +
== dynamics ==
 +
Module: dyn_''name''
 +
Ports:
 +
 
 +
== hmi ==
 +
This groups GUIs, voice recognition modules...
 +
Module: hmi_''name''
 +
Ports: ''any input and output from other modules''
 +
 
 +
* svn co http://roborepo.uc3m.es/svn/ASIBOTcoderepo/trunk/hmi/hmi_3d
 +
** TODO: Must adapt to this new standard.
 +
 
 +
== kinematics/trajectory ==
 +
This module should be able to take the description from a file and generate joint solutions for proposed cartesian goal.
 +
Module: kin/trj_''name''
 +
Port: ''name''_xi_io
 +
  - Data: bottle_xi_io "I:code D:X D:Y D:Z D:ROLL D:PITCH D:YAW D:genvel"
 +
Port: ''name''_q_io
 +
  - Data: bottle_q_o "I:code D:Q1pos ... D:Q''n''pos D:Qgenvel"
 +
  - Data: bottle_q_o "I:code D:Q1vel ... D:Q''n''vel"
 +
  - Data: bottle_q_i "I:code D:Q1pos ... D:Qnpos"
 +
 
 +
Code:
 +
  - 10: Read absolute position, base coordinate
 +
  - 11: Absolute position with wait, base coordinate
 +
  - 12: Relative position with wait, base coordinate
 +
  - 13: Relative position with wait, tool coordinate
 +
  - 14: Absolute position without wait, base coordinate
 +
  - 15: Relative position without wait, base coordinate
 +
  - 16: Relative position without wait, tool coordinate
 +
 
 +
* svn co http://roborepo.uc3m.es/svn/ASIBOTcoderepo/trunk/kinematics/kin_pos_based
 +
<!-- ** TODO: Must adapt to this new standard. -->
 +
 
 +
== planning ==
 +
Module: pln_''name''
 +
Ports:
 +
 
 +
== stabilizer ==
 +
Module: stb_''name''
 +
Ports:
 +
 
 +
== tools ==
 +
Module: tol_''name''
 +
Ports:
 +
 
 +
* svn co http://roborepo.uc3m.es/svn/ASIBOTcoderepo/trunk/tools/tol_file
 +
<!-- ** TODO: Must adapt to this new standard. -->
 +
 
 +
== vision ==
 +
The output of this module is a cartesian goal (derived from a distance and orientation).
 +
Module: vis_''name''
 +
Ports: ''name''_xg_o
 +
  - Data: bottle_xg_o "D:X D:Y D:Z D:ROLL D:PITCH D:YAW"

Latest revision as of 10:20, 2 June 2010

Important Notice: This standard has been replaced by Modules - Standard v0.2.
Most prominent changes are the use of tags in commands, and dropping _io, _i, _o suffixes.

The intention of this standard is to keep internal coherence and compatability with RoboticsLab robot Modules which follow this standard. It is intended to be a description of existing and future modules, their interfaces and data flow representation. For a debate on open issues, go to the discussion tab. Port interface is referred to TCP/UDP/MCAST/SHMEM cloud side, not CAN or USB (that can coexist in hardware-related modules).

Nomenclature: D for double, I for integer, S for string.

drivers

These modules should recieve joint position commands, in relative and absolute degrees.

Module: drv_name
Ports: name_q_io 
 - Data: bottle_q_i "I:code D:Q1pos ... D:Qnpos D:Qgenvel"
 - Data: bottle_q_i "I:code D:Q1vel ... D:Qnvel"
 - Data: bottle_q_o "I:code D:Q1pos ... D:Qnpos"
Code:
 - -1: Stop
 - 0: Encoder read
 - 1: Relative position with wait
 - 2: Absolute position with wait
 - 3: Relative position without wait
 - 4: Absolute position without wait
 - 5: Velocity without wait
 - 5x: Syncronize motor x


dynamics

Module: dyn_name
Ports:

hmi

This groups GUIs, voice recognition modules...

Module: hmi_name
Ports: any input and output from other modules

kinematics/trajectory

This module should be able to take the description from a file and generate joint solutions for proposed cartesian goal.

Module: kin/trj_name
Port: name_xi_io
 - Data: bottle_xi_io "I:code D:X D:Y D:Z D:ROLL D:PITCH D:YAW D:genvel"
Port: name_q_io
 - Data: bottle_q_o "I:code D:Q1pos ... D:Qnpos D:Qgenvel"
 - Data: bottle_q_o "I:code D:Q1vel ... D:Qnvel"
 - Data: bottle_q_i "I:code D:Q1pos ... D:Qnpos"
Code:
 - 10: Read absolute position, base coordinate
 - 11: Absolute position with wait, base coordinate
 - 12: Relative position with wait, base coordinate
 - 13: Relative position with wait, tool coordinate
 - 14: Absolute position without wait, base coordinate
 - 15: Relative position without wait, base coordinate
 - 16: Relative position without wait, tool coordinate

planning

Module: pln_name
Ports:

stabilizer

Module: stb_name
Ports:

tools

Module: tol_name
Ports:

vision

The output of this module is a cartesian goal (derived from a distance and orientation).

Module: vis_name
Ports: name_xg_o
 - Data: bottle_xg_o "D:X D:Y D:Z D:ROLL D:PITCH D:YAW"