[Documentation] [TitleIndex] [WordIndex

(!) Please ask about problems and questions regarding this tutorial on answers.ros.org. Don't forget to include in your question the link to this page, the versions of your OS & ROS, and also add appropriate tags.

Advanced installation Hironx/NEXTAGE OPEN API software

Description: Advanced installation for HiroNXO robots users. You usually don't need any from here.

Keywords: Hiro, Hironx, NEXTAGE OPEN, Shadow Repository

Tutorial Level: ADVANCED

Next Tutorial: Adding feedback control

NOTE: All the tutorials available under the URL http://wiki.ros.org/rtmros_nextage/Tutorials are applicable to the multiple products of Kawada Industries; Hiro (only with the one that opensource software is installed) and NEXTAGE OPEN. To simplify the notation in the rest of the tutorials, we use HiroNXO to appoint the aforementioned robots.

Introduction

/!\ To install Hironx / NEXTAGE OPEN software, please first follow the normal tutorial.

This page should be reserved only for who need advanced way of installation.

For Advanced Purposes

Get preliminarilly built ROS binary

NOTE: This section is advanced. Please move on only at your own risk or when you're advised to do so. Otherwise skip to the next section.

In ROS it takes a little awhile, normally two or three weeks, before the new version of binary files with updates applied becomes available (due to a number of checkings happening on ROS "buildfarm" to maintain software quality). If you're in hurry, however, to obtain newer versions, there's a way to do as follows.

  1. Switch your apt repository to so-called Shadow repository. Follow ShadowRepository#Usage up to $ sudo apt-get update.

  2. Install what you need. E.g.:
      $ sudo apt-get install --reinstall ros-%ROS_DISTRO%-nextage-ros-bridge
    
      $ sudo apt-get install --reinstall ros-indigo-nextage-ros-bridge    (example in ROS Indigo)

    This way, binaries that are already built but have not yet been officially released by ROS team can get installed. This does not necessarily mean that those binaries are unstable; instead, you're just fetching the binaries that are being tested and awaiting to be released; this is based on the release cycle of ROS debian binary (cf. this discussion).

  3. As noted in ShadowRepository#Usage, do not forget to revert back the change you just made in ros-latest.list once you're done with the newest binary.

WARNING because of the nature of the process mentioned above, you should do this only for development purpose and never ever use this method on production systems. And as described in the step above, you're encouraged to set back the apt-get configuration (ie. comment in the change you made in the step 2 above).

  • If you're interested in what is the repository we just used above, read ShadowRepository.

Install via source

NOTE: Unless you're a developer who needs to write and build codes for NEXTAGE OPEN, you're advised to install via binary.

Create directory under your catkin workspace.

$ mkdir -p catkin_ws/src; cd catkin_ws/src

You may notice that we are naming a source folder as catkin_ws. Besides that this is just a naming build tool does not care, catkin as a convention prefers its work folder as to be called something like "catkin workspace". If you're building with rosbuild in the following subsection, this folder name is still valid (but if you think confusing then feel free to change it).

The following subsections are separated for you per build tool you use. All ROS Fuerte users use rosbuild. The Groovy users who never used or even heard of a word catkin but still have some experience in ROS, you're likely a rosbuild user. All ROS Hydro or newer distro users should use catkin.

Source build by rosbuild (rosmake)

If you're on ROS Groovy or newer, skip this subsection and goto build by catkin subsection (rosbuild still sticks around without any problem for backward compatibility purpose; it's just not recommended).

First setup a workspace at src dir.

$ rosws init

Then open with your favorite editor .rosinstall file that should be created by the previous command. Then add ROS environment info (as noted in tutorial):

- setup-file:
    local-name: /opt/ros/%YOUR_ROS_DISTRO%/setup.*sh

Then update the same file, obtain the source, and setup ROS environment by following:

$ rosws merge https://rtm-ros-robotics.googlecode.com/svn/trunk/rtm-ros-robotics.rosinstall
$ rosws update
$ source setup.*sh     (choose either script file that suits your needs)

Now you're ready to build by:

$ rosmake hironx_ros_bridge

Here, if you see rosmake stops with error at a particular package,

$ cd %PKG_THAT_CAUSED_ERR%
$ make

If this passed then do the same rosmake again. Packages that are reported to cause error: hrpsys_ros_bridge, hironx_moveit_config

To verify that it runs, go on to next section to run simulator.

Source build by Catkin

*NOTE*: You're encouraged to use binary (instruction) for many reasons unless you have specific reasons (e.g. If you're on an old OS such as Ubuntu 12.04, then you need to source build) to build from source.

First obtain source. In src folder,

$ wstool init
$ wstool merge https://raw.githubusercontent.com/start-jsk/rtmros_hironx/hydro-devel/.rosinstall_min
$ wstool update
$ catkin_init_workspace

The above commands downloads necessary codes.

Before you become able to build your catkin workspace, you need to make sure that you have all the required dependencies. We use rosdep for this:

$ cd ..     (moving back to catkin_ws)
$ rosdep install --from-paths src --ignore-src --rosdistro hydro -y -r

This will look at all of the packages in the src directory and find all of the dependencies they have. Then it will recursively install the dependencies, without stopping at any errors that may or may not occur.

*NOTE*: it's known that the above command using rosdep doesn't install all dependency for wet packages (ie. packages that are built using catkin) due to the spec of current rosdep (Oct 2013, Related thread). gm130s is writing a patch for it.

Now you're ready to start building:

$ catkin_make
$ source devel/setup.bash   (or any shell script you would prefer under `/devel`)

In addition, only if you're building both rosbuild and catkin for whatever purpose, it's necessary for rtm-ros-robotics that enables "hybrid" build of both rosbuild and catkin and thus uses source folders for building work (cleaning your source folder is unusual usage in catkin workspace in general).

$ catkin_make clean

Install ROS from source (both build system)

If you dare to, or have a reason to install not just hironx but the entire ROS too from source (eg. if you have a reason to run on Mac OSX etc. where ROS binary isn't available), you can still take advantage of .rosinstall to manage all the source repositories you need to obtain sources from. Use rosinstall_generator.

$ rosinstall_generator hironx_ros_bridge --rosdistro hydro --deps --wet-only > hydro-hironx-wet.rosinstall

Simple this command creates a .rosintall file that has a long list of all source repos.


2019-10-12 13:06