Giter Club home page Giter Club logo

controlit's Introduction

ControlIt! - A Whole Body Operational Space Control Middleware

Table of Contents

Introduction

This is repository contains ControlIt!, a middleware that supports the Whole Body Operational Space Control algorithm. It employs a plugin-based modular software architecture so other whole body control algorithms could be supported as well.

Installation

Create a ROS Workspace

This step is only necessary if you do not already have a ROS Catkin workspace that you want to use for ControlIt! development. The commands below create a workspace called "controlit_workspace". Feel free to customize it to another name.

$ source /opt/ros/indigo/setup.bash
$ mkdir -p ~/controlit_workspace/src
$ cd ~/controlit_workspace/src
$ catkin_init_workspace
$ cd ..
$ catkin_make

Edit ~/.bashrc and add the following line at the bottom:

# Setup ControlIt! ROS workspace
source $HOME/controlit_workspace/devel/setup.bash
# source `rospack find controlit_environment_config`/setup.sh
# source `rospack find controlit_models`/setup.sh
# source `rospack find controlit_configs`/setup.sh

Note that all but one of the lines above are commented out. The bottom three lines will be uncommented after checking out all of the repositories.

Add ControlIt! to the ROS Workspace

The following instructions assume you are using a ROS workspace located in ~/controlit_workspace.

Using your favorite text editor, create the text file ~/controlit_workspace/.rosinstall containing the following text (Note: to avoid permission errors, you need to upload your public SSH key to your github and bitbucket accounts).

- setup-file: {local-name: /opt/ros/indigo/setup.sh}
- git: {local-name: src/controlit, uri: '[email protected]:liangfok/controlit.git', version: master}
- git: {local-name: src/controlit_models, uri: '[email protected]:liangfok/controlit_models.git', version: master}
- git: {local-name: src/controlit_configs, uri: '[email protected]:liangfok/controlit_configs.git', version: master}
- hg: {local-name: src/rbdl2, uri: 'ssh://[email protected]/cfok/rbdl2'}
- git: {local-name: src/ros_shared_memory_interface, uri: '[email protected]:liangfok/ros_shared_memory_interface.git', version: master}

If you are unable or unwilling to upload your public SSH key to your github and bitbucket accounts, use the following settings to use HTTP rather than SSH to download the software:

- setup-file: {local-name: /opt/ros/indigo/setup.sh}
- git: {local-name: src/controlit, uri: 'https://github.com/liangfok/controlit.git', version: master}
- git: {local-name: src/controlit_models, uri: 'https://github.com/liangfok/controlit_models.git', version: master}
- git: {local-name: src/controlit_configs, uri: 'https://github.com/liangfok/controlit_configs.git', version: master}
- hg: {local-name: src/rbdl2, uri: 'https://bitbucket.org/cfok/rbdl2'}
- git: {local-name: src/ros_shared_memory_interface, uri: 'https://github.com/liangfok/ros_shared_memory_interface.git', version: master}

Exit the text editor and update your workspace:

$ cd ~/controlit_workspace
$ wstool update

You can check the status of your workspace by executing:

$ cd ~/controlit_workspace
$ wstool info

Enable Gazebo Plugins and Models

Now that you have checked out all of the repositories, you can enable the Gazebo plugins and models that are used by ControlIt!. Edit ~/.bashrc and update the section related to ControlIt! to be the following:

# Setup ControlIt! ROS workspace
source $HOME/controlit_workspace/devel/setup.bash
source `rospack find controlit_environment_config`/setup.sh
source `rospack find controlit_models`/setup.sh
source `rospack find controlit_configs`/setup.sh

Close and re-open your terminals for the settings to apply.

Install RBDL

RBDL provides various dynamics and kinematics algorithms that are used by ControlIt! in the robot model. Install it by executing the following commands:

$ cd ~/controlit_workspace/src/rbdl2
$ mkdir build && cd build
$ cmake ../ -DRBDL_STORE_VERSION=ON -DCMAKE_BUILD_TYPE=Release
$ make && sudo make install

Install YAML 0.3.0

ControlIt! currently uses yaml-cpp 0.3.0. If you're using Ubuntu 14.04 or higher, you will need to downgrade to this version. Here's how to do that:

First download yaml-cpp's source code from here: https://code.google.com/p/yaml-cpp/downloads/list

Then install it:

$ tar zxvf yaml-cpp-0.3.0.tar.gz
$ cd yaml-cpp
$ mkdir build
$ cd build
$ cmake -DBUILD_SHARED_LIBS=ON ..
$ make
$ sudo make install

Install Additional Dependencies

There are several additional packages that need to be installed using apt-get:

$ sudo apt-get install python-simplejson libmuparser-dev libzmq-dev libfltk1.1-dev libfltk1.1

Compile ControlIt!

To compile ControlIt!, execute:

$ cd ~/controlit_workspace
$ rm -rf build devel              // optional, for a clean re-compilation of everything
$ catkin_make

Configure Shared Memory

Many of ControlIt!'s demos use shared memory to communicate between the whole body controller and the simulator. To prevent needing to allocate this shared memory each time you restart your computer (and having to type your sudo password), we recommend that you permanently allocate sufficient shared memory by executing the command below:

$ rosrun shared_memory_interface set_shared_memory_size_persistent 536870912

Run Demonstration Simulations

For tutorials on how to use ControlIt!, see: http://robotcontrolit.com/tutorials

controlit's People

Contributors

liangfok avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

controlit's Issues

How to Use Controlit! with stickbot_bipedal_12dof (COM Position)

in the tutorial, we are expecting to move the position of COM with below command:

$ rostopic pub --once /stickbot_bipedal_12dof_controller/COMTask/goalPosition std_msgs/Float64MultiArray '{layout: {dim: [{label: "x", size: 3, stride: 3}], data_offset: 0}, data: [0, -0.3, 0.1]}'

however, there is no /stickbot_bipedal_12dof_controller/COMTask/goalPosition topic generated, in other words, we could not control the COM.

I think there is something wrong in COMControl.yaml.

error in stickbot_bipedal_12dof

Hi,there!
I followed the instruction here.http://robotcontrolit.com/tutorials/stickbot_bipedal_12dof/controlit/compos.
when I tried to activated the controller follow the command below,

roslaunch atlas_legs_plain_controlit start_controlit.launch

error was thrown out like this:

[ WARN] [1433175985.130841888]: [00:26:25] [package: controlit_core] [file: ParameterReflection.cpp] [function: lookupParameter] [line: 191]: Could not find parameter 'converged'

[ERROR] [1433175985.132517001]: [00:26:25] [package: controlit_core] [file: Coordinator.cpp] [function: init] [line: 164]: Exception thrown during initialization: yaml-cpp: error at line 198, column 7: key not found: parameter

controlit_exec: /home/tb/controlit_workspace/src/controlit/controlit_core/src/Coordinator.cpp:165: bool controlit::Coordinator::init(): Assertion `false' failed.
[stickbot_bipedal_12dof_controller/controlit_exec-1] process has died [pid 26653, exit code -6, cmd /home/tb/controlit_workspace/devel/lib/controlit_exec/controlit_exec __name:=controlit_exec __log:=/home/tb/.ros/log/bfa20d9e-0871-11e5-ba2f-74e50b88ced0/stickbot_bipedal_12dof_controller-controlit_exec-1.log].
log file: /home/tb/.ros/log/bfa20d9e-0871-11e5-ba2f-74e50b88ced0/stickbot_bipedal_12dof_controller-controlit_exec-1*.log

Demo stickbot_humanoid_32dof does not stabilize

The torso lowers but then the feet appear to slip. All three demos fail. When I slow down the demo, it looks like the knees bend as expected, but then straighten again causing the feet to loose contact with the ground.

Trikey_pinned demo does not work

When the compiling code is run the terminal, the following errors come up: "the args could not be parsed as stacks or packages" and "No arguments could be parsed into valid package or stack names".

demo simulation tutorial link

The link to the demonstration simulation on the main page seems to be invalid. It would be much appreciated if an updated link could be provided. Thanks so much!

Group demo test fails

the group demo test results in the following:

Started with the following arguments:

  • robotPath:
  • timeOut: 20
  • errorThreshold: 0.05
  • stdOut : True
  • stdErr: True

Traceback (most recent call last):
File "/home/eva/controlit_workspace/src/controlit/controlit_quality_assurance/scripts/groupTest.py", line 381, in
with open(yaml_path, 'r') as testing_list_yaml:
IOError: [Errno 2] No such file or directory: '/controlit/controlit_quality_assurance/scripts/testing_list.yaml'

Remove Singularities from Floating 6 DOF

The current implementation uses 6 serial joints. This suffers from singularities. It should be switched to spherical joints. See controlit_model/src/rbdl_robot_urdfreader.cpp, lines 409-415.

Automatically Test Every ControlIt! Demo

It seems that automatically test mechanism is not working properly. error is thrown out like this:

tb@tb:~/controlit_workspace/src/controlit/controlit_quality_assurance$ rosrun controlit_quality_assurance groupTest.py

Started with the following arguments:

  • haharobotPath:
  • timeOut: 20
  • errorThreshold: 0.05
  • stdOut : True
  • stdErr: True

Traceback (most recent call last):
File "/home/tb/controlit_workspace/src/controlit/controlit_quality_assurance/scripts/groupTest.py", line 381, in
with open(yaml_path, 'r') as testing_list_yaml:
IOError: [Errno 2] No such file or directory: '/controlit/controlit_quality_assurance/scripts/testing_list.yaml'

Update Parameter Declaration API to Include Direction so Default Bindings can be Automated

Currently, default bindings are defined explicitly within a method called addDefaultBindings(). For example, see COMTask.cpp and JointPositionTask.cpp. I believe default bindings can be automatically done once the direction of the parameter is defined, i.e., is it an "input" parameter or an "output" parameter from ControlIt!'s perspective. Once the direction is specified, the user will only need to specify the transport type, which can default to ROS topics.

Gazebo Should be Made an Optional Dependency

Dreamer's control PC does not have a current version of Gazebo installed and thus Gazebo should be made into an optional dependency for ControlIt!. This was not a problem when using rosbuild since we could selectively compile packages. With Catkin, this is a problem because all packages in the workspace need to be compiled.

The following packages have Gazebo dependencies:

  • controlit_models/hcrl_simulator
  • controlit_models/dreamer
  • controlit_configs/controlit_gazebo_plugins

As a temporary workaround, a file called CATKIN_IGNORE can be added to the above packages to prevent them from being compiled.

Improve Reliability of stickbot_humanoid_32dof_controlit by Integrating a Planner

Sometimes stickbot_humanoid_32dof_controlit goes unstable immediately after starting the simulation. A potential cause is the fact that the difference between the robot's initial configuration and desired configuration is too large resulting in excessively high torque commands. Try integrating a planner that gradually moves the robot into its initial desired configuration.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.