Skip to content

gen-robot/Teleop-FrankaPy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

franka-control Melodic-Noetic

Initial preparation

sudo apt install ros-melodic-libfranka ros-melodic-franka-ros ros-melodic-control-msgs # you can change to noetic
conda create -n franka-teleop python=3.10 -y # 3.8(stable) / 3.10
conda activate franka-teleop
pip install colcon-common-extensions "empy==3.3.4" lark-parser lxml netifaces pyyaml rosdistro vcstool setuptools
cd frankapy 
pip install -e . # you should run this before installing franka-interface
cd ..

Install franka-interface in control computer [local NUC]

cd franka-interface 

You should follow the instructions in README.md

Install frankapy in command computer [with GPU]

cd frankapy

You should follow the instructions in README.md

You can also follow the instructions in Website

Running the Franka Robot

  1. Make sure that the Franka Robot has been unlocked in the Franka Desk GUI and has blue lights.

  2. Open up a new terminal and go to the frankapy directory.

    cd frankapy
    sudo ufw disable # especially on C19 NUC 

    You should modify control_pc_franka_interface_path in ./bash_scripts/start_control_pc.sh, to find the franka-interface.

    1. If you are running franka-interface and frankapy on the same computer, run the following command:
    bash ./bash_scripts/start_control_pc.sh -i localhost
    1. Otherwise run the following command:
    bash ./bash_scripts/start_control_pc.sh -u [control-pc-username] -i [control-pc-name]

    Please see the start_control_pc.sh bash script for additional arguments, including specifying a custom directory for where franka-interface is installed on the Control PC as well as the username of the account on the Control PC. By default the username is iam-lab.

  3. Open up a new terminal, enter into the same virtual environment and go to the frankapy directory. Do:

    # in ROS 1
    source catkin_ws/devel/setup.bash
    # in ROS 2
    source ros2_ws/install/setup.bash

    Be in the same virtualenv or Conda env that FrankaPy was installed in. Place your hand on top of the e-stop. Reset the robot pose with the following command.

    python scripts/reset_arm.py
  4. Please note that if you are using a custom gripper or no gripper, please set the with_gripper=True flag in frankapy/franka_arm.py to False as well as set the with_gripper=1 flag in bash_scripts/start_control_pc.sh to 0.

Data collection

See example scripts in the examples/ and scripts/ folders to learn how to use the FrankaPy python package.

If you want to use space_mouse to teleop and collect data, you should follow the instruction

frankapy API Documentation

franka-interface API Documentation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •