Giter Club home page Giter Club logo

rtt-franka-hardware-integration's Introduction

rtt-franka-hardware-integration

Integration of Franka Panda arm into Orocos

Installation

Besides an Orocos toolchain, this project requires libfranka built from source for compilation. Installation instructions can be found at https://frankaemika.github.io/docs/installation.html. libfranka apparently needs a kernel compiled with the PREEMPT_RT patchset, so you can either build your own kernel as stated in the official documentation or simply install one of the lowlatency kernels included with recent versions of Ubuntu:

sudo apt install linux-image-lowlatency

With <libfranka> as your location of the libfranka sources, use

mkdir build && cd build
cmake -DFranka_DIR=<libfranka>/build ..
cmake --build .

to build an Orocos component from the code.

Usage

To control the Franka Panda arm from Orocos, make sure your machine booted a kernel including the PREMPT_RT patch and is connected to the controller hardware as written in the official documentation. Additional, you will need the URDF and SRDF of the manipulator (available for example here, originally taken from the franka_ros package).

If those prerequisites are fulfilled, you can load and use a component called franka::franka_robot from the deployer:

# Import typekits and OS library for convenience
import("eigen_typekit")
import("rst-rt_typekit")
require("os")
    
# Import rtt-franka-hardware-integration
import("rtt-franka-hardware-integration")

# Assume URDF and SRDF files are in $GAZEBO_MODEL_PATH/franka
var string model_path = os.getenv("GAZEBO_MODEL_PATH") + "/franka"

# Load component and schedule it really fast (event driven) with high priority
loadComponent("franka", "franka::franka_robot")
setActivity("franka", 0, 90, ORO_SCHED_RT)

# Initialize kinematic chain using URDF and SRDF files
franka.addChain("franka", "172.16.0.2", model_path + "model.urdf", model_path + "model.srdf")

# Set control mode and start component!
franka.setControlMode("franka", "JointTorqueCtrl")
franka.configure()
franka.start()

# TODO
# Connect your own component to the feedback and command ports of franka and control the robot!

Features

Working

  • Control modes
    • Joint velocity (JointVelocityCtrl)
    • Joint torque (JointTorqueCtrl)
    • Joint impedance (JointIpedanceCtrl)
  • Joint state feedback
    • Position
    • Velocity
    • Torque
  • Dynamic feedback
    • Manipulator jacobian
    • Inertia/mass matrix
    • Gravity vector
    • Coriolis vector

Not working

  • Joint position control (JointPositionCtrl)
    Robot reports errors due to joint velocity and acceleration discontinuities even in case clearly smooth trajectories are commanded and handed to libfranka. Root cause of this problem is unkown up to now.

Source code

See HACKING.md for information about code structure and implementation details.

rtt-franka-hardware-integration's People

Watchers

James Cloos avatar Julian avatar

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.