Top/ROS/ProgrammingGuide
English | Japanese
English | Japanese

Menu

  • Top
  • Search 検索
  • Writers 著者リスト
  • Online forum フォーラム
↑

Recent

2021-08-17
  • os/Linux
2019-01-17
  • eq/LulzBot
2018-12-10
  • dev/Motoman
2018-07-05
  • tool/Git
2018-05-02
  • lib/Eigen
  • writer/Ilya_Ardakani
2018-04-26
  • lib/Deformable_Simulators
  • Top
2018-04-23
  • writer/Naoya_Chiba
  • MenuBar
  • writer
2018-04-22
  • lang/Python
2018-04-21
  • lang/C++
2018-04-19
  • Editor(editor)/Assignment
  • Editor(editor)
  • lang/C++/Exercise
2018-04-18
  • SandBox2
  • lang/Python/Exercise
  • soft/FreeCAD
  • lib/Chainer
Access: 1/692 - Editor / Admin

Programming Guide

  • ROS developer's guide

Minimize ROS Dependency †

  • The purpose of using ROS is connecting your program to other ROS packages.
  • In general, your code might be used in other situations where ROS is not used.
  • In order to increase the reusability of ROS code, minimize the ROS dependency of your code.
  • Separate ROS dependent code (nodes, publishers, etc.) from ROS independent code as classes, functions, etc.
  • Example of making a node xxx (e.g. face tracking):
    • Create a ROS-independent unit xxx.h and xxx.cpp
    • Create a ROS-dependent code xxx_node.cpp
    • Write main algorithms in xxx.{h,xxx.cpp}
    • Write a ROS interface (node, subscribers, publishers, ...) in xxx_node.cpp where xxx.h is imported to use the main algorithms.



Last-modified:2018-04-18 (Wed) 03:46:18 (2630d)
Link: ROS(2630d)
Site admin: Akihiko Yamaguchi.
Written by: Akihiko Yamaguchi.
System: PukiWiki 1.5.0. PHP 5.2.17. HTML conversion time: 0.007 sec.