Emika Franka Panda Robot
Introduction
The Emika Franka Panda robot is a 7-DOF robot arm with a 3kg max payload and full torque sensing at each joint.
The robot is connected to a workstation computer running the Realtime Linux Kernel. Your laptop connects to the workstation computer.
In general, write software on your laptop and control the robot over the network; however, in more advanced configurations it is possible to run your code directly on the workstation computers.
Layers of Control
- MoveIt: At the highest layer, the robot can be controlled through MoveIt and ROS, provided by franka_ros2
- ros_control: There are several ROS controllers that can be used, written with the ros2_control package. It is also possible to write your own controllers in C++.
- libfranka this is a C++ library provided by Franka. ROS uses this library to communicate with and control the robot, and you can use it also.
- Web interface: a web interface is available that runs on the robot.
- Graphical programming of pre-determined tasks is possible, as is interactively placing the robot and storing its position.
Robot Versions
- MSR has four Franka Emika Panda robots. These robots are now referred to as FER robots.
- There is also a newer (but substantially similar) Franka robot called the FR3, which some research groups have in the lab.
- There is no official ROS 2 support for the FER, but I provide a library that ports the FR3 ROS 2 package to ros2 Jazzy
Software Setup
Create a new ROS 2 workspace:
mkdir -p ws/franka/src cd ws/franka vcs import --input https://nu-msr.github.io/images/franka.repos src rosdep install --from-paths src -y --ignore-src -r colcon build --merge-install --cmake-args -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=OFF
- To use the Franka you will need to have the
franka
workspace sourced.- This workspace underlays whatever workspace you are working on
- You can safely source the
franka
workspace instead of/opt/ros/jazzy/setup.bash
in~/.bashrc
if you would like.
- Install chrony an advanced NTP server and client. We will use
chrony
to synchronize the clocks between thestation
and your laptop= Configure chrony by appending the following lines to
/etc/chrony/chrony.conf
(e.g.,sudoedit /etc/chrony/chrony.conf
)allow 192.168.18/24 local stratum 5
- This configuration allows the robot to connect to the
chrony
NTP server and
- This configuration allows the robot to connect to the
- Restart chrony
sudo systemctl restart chrony
- When on the
station
you can view time synchronization status withchronyc tracking
- You can also view the state of the NTP time sources with
chronyc sources
- You can also view the state of the NTP time sources with
Getting Started
Rules
- Make sure the workspace is clear of people and objects whenever the robot's lights are blue or green.
- Never force the robot to move physically. Always use the guided movement mode (pressing buttons on arm, lights are white).
- Be gentle in the guided movement mode and don't try to force the robot.
- In guided mode the robot should be easy to move. If it is resisting stop and investigate.
- Test actions in MoveIt with the mock hardware before deploying on the robot:
- Make sure that the robot moves as you expect.
- Always have somebody ready to press the enabling device to stop the robot.
- Some projects will require the three-state switch rather than the enabling device (I will let you know).
- Press the device whenever the robot deviates from how you expect it to behave or if it looks like it might crash.
- Follow all power on and power off procedures in this manual.
- If you ever see Red lights, power off the robot and turn it on.
- If they remain red after one complete power cycle, stop working and contact me.
Power On
If the robot is off, you will need to turn it on (obviously!).
- Make sure the e-stop is not pressed (pull up on the red button).
- Turn the power-strip on.
- The workstation PC and Franka Controller should power on automatically
- The Panda lights should flash yellow for a time
- Wait for the yellow lights to stop flashing.
- Yellow lights indicate the robot is locked and cannot move.
The Web Interface
- Plug the ethernet cord from the robot into your computer.
- Your computer should obtain an ip address automatically, but it may take a little while.
- Make sure the enabling device is within reach and pressed down (robot is disabled).
- Navigate in your web browser to
https://panda0.robot
- This is the graphical, non-programmer interface to the robot
- You will get an SSL warning. It is okay to accept the risk and continue (you are not on the internet here this is just the robot and I can't change its SSL certificate).
- Login with the information I have provided
- If somebody has already been using the robot, you will be prompted to request control
- Press request control
- Click enforce
- Click the button labeled with a circle on the top of the robot
- The web interface should now be enabled
- Make sure nobody is in the robot's workspace.
- Unlock the robot by clicking the unlock button. The robot's lights should turn white.
- You can now manually move the robot by pressing the two buttons on the end of the arm
- The web-interface has some options about how this movement works, and you can toggle between them on the robot arm itself by pressing it's buttons
- Two buttons on the top of the head open and close the grippers
- Do not force the robot, it should move freely when pressing the buttons properly
Enabling ROS
- In the hamburger menu in the upper-right corner, select Activate Franka Control Interface (FCI)
- The web interface no longer has control, and you can now use ROS
Using ROS
- ssh into
station
, using the credentials that I provide.- You can also use
ssh-copy-id
to install yourssh
certificate and avoid entering the password each time.
- You can also use
- Release the enabling device, so that the robot lights are blue
- On
station
runros2 launch franka_fer_moveit_config real.launch.py use_rviz:=false robot_ip:=panda0.robot
to start the controllers and moveit - On laptop run
ros2 launch franka_fer_moveit_config moveit_rviz.launch.py robot_ip:=panda0.robot
to launchrviz
- You can also specify the
rviz_config
parameter to load an alternativerviz
file, if you want to customize the visualization
- You can also specify the
- The
move_group
node is running onstation
, but you can communicate with it via itsactions
,services
, andtopics
without worrying about that - Pressing the
enabling
device will stop the robot and cause some nodes to crash - The
ROS_DOMAIN_ID
of the Franka robot is 0 by default. You need yourROS_DOMAIN_ID
to match that of the robot
Enabling Device
- Feel free to press the enabling device at any time to stop the robot
- After pressing, you will need to
- Make sure to terminate the
real.launch.py
launchfile on the station - Release the enabling device (possibly after manually guiding the robot to a new position)
- Re-run the
real.launch.py
launchfile
- Make sure to terminate the
Finished With Robot
Before you step away from the robot:
- Move the robot to a reasonable ready position (either using MoveIt, or by manually moving it)
- Make sure the robot is disabled (press the enabling device so the lights turn white).
- Kill the any launchfiles or nodes that you started on
station
- In the web interface, disable the FCI.
- Lock the robot.
- It is okay to step away from the robot when it is locked.
Power Off
- In the web interface, select shutdown.
- Wait for the robot's lights to turn off and the fans in the control box to stop spinning
- Power off the power strip
Robot Status Lights
- Yellow: Robot is Locked. Do not attempt to move the arm, you can damage it.
- If you leave the robot unattended, put it lock mode.
- White: Robot is disabled. You can physically move the arm by pressing the move buttons near the end-effector
- Do not attempt to force the arm to move in this mode
- The arm cannot undergo a motion initiated from the computer in this mode
- This mode is entered by pressing the enabling device
- Blue: Robot is enabled. It can move due to computer commands.
- No person (including you) should not be in the robot workspace when the robot is blue.
- You must pay attention and be ready to press the enabling device (to disable the robot) if an unexpected movement occurs
- Enter this mode by twisting the enabling device so that the button pops up
- Green:
- This mode is entered when the robot is executing a command from the web interface
- We won't often see this mode
- Red: Error
- You can enter this mode in a number of ways, but one way is if you try to force any of the arm joints to move too much
- You will need to power cycle the robot to remove the error
- If power-cycling does not clear the red lights, contact me and stop using the robot
Red Light Troubleshooting
- If the red lights turn on but then clear after resetting the robot you are likely near a joint limit
- To see if this is the issue, unlock the robot and enable it (Blue Lights)
- In the web interface, under "Robot Status" the robot picture will be blue but there will be a message saying "joint limit exceeded"
- To clear the joint limit exceeded message you need to carefully manipulate each joint (under white lights) so that they are not near the joint limits.
Mechanical
- Franka World provides a full SolidWorks Model of the robot and also CAD for mounting cameras to the arm
Resources
- Software Documentation
- Particular attention to franka_ros
- Franka World (Free signup required): provides access to the manual, and some useful SolidWorks models (for example to attach a realsense to the robot).
- Franka Setup More details on how the workstation was setup.