Rethink Sawyer Setup

Overview

This page contains instructions for setting up the Rethink Sawyer arm with perls2.

perls2 + Rethink Sawyer Infrastructure

To use the Rethink Sawyer arms, we have to use ROS-kinetic. Unfortunately ROS-kinetic only works with python 2.7, which has been outdated for some time. To overcome this limitation, we use Redis, an in-memory database to communicate between the process running on the workstation and the process sending torque commands the sawyer that runs on the NUC.

sawyer_ros_redis

perls2 uses three machines to communicate with the Franka Panda. These machines are connected in a local network. They consist of the:

  1. Sawyer Computer: This is the main control box that comes with the Franka Panda.

  2. Workstation (WS): The workstation hosting the perls2 environment and running any scripts to perform the robot experiment.

  3. Control PC (NUC) or other computer with RT-PREEMPT Kernel: Typically an Intel NUC, is dedicated to running only the processes necessary for torque control.

    Using the Rethink Sawyer arm with torque control requires a consistent control loop frequency for sending torque commands to the arm. In order to acheive this, a separate machine with an RT Kernel sends torques to the Master Controller.

    The following processes run on the NUC:

    1. redis-server: An in-memory database used by perls2 for interprocess communication. Hosted on the NUC and communicated with via tcp. Allows the perls2.SawyerCtrlInterface to bridge the perls2.Env on the WS with intera. See the Redis Help for more on Redis and perls2.

    2. ROSRedisPublisher: Ros node that updates redis with robot state from intera.

    3. perls2 SawyerCtrlInterface: Process that implements the robot controller.

      • Robot commands and controller params are obtained from the WS.

      • Robot state is obtained from the franka-panda-iprl driver.

      • The SaywerCtrlInterface uses these to calculate the torques required to acheive desired robot state, and send them as a ROS JointCommand msg.

    4. JointStatePublisherRate node Node that commands Sawyer to publish its joint state at maximum 800 Hz instead of default 500 Hz.

Setting up a Rethink Sawyer Arm

Set Static IP for a computer / robot

To set static IP for robots / computer:

IP address: <your-static-IP>
Gateway: <your-routing-gateway>
Netmask: 255.255.254.0
DNS nameservers: 171.64.1.234, 171.67.1.234

Find gateway address with netstat -r -n. As of March 2021, all of the sawyers should be accessible by a hostname. You can see a sawyer’s host name by opening the FSM

Set Static IP for Sawyer

  1. Connect a keyboard to Sawyer.

  2. While booting up the Sawyer, repeatedly press Ctrl+F until you see the field service menu (FSM).

  3. Configure the network address with the information above.

  4. Use ROS_IP naming convention.

  5. Reboot into InteraSDK

Find MAC addr for Sawyer

  1. Go to FSM

  2. Plug in a USB driver

  3. Export log

  4. Open up the log in a computer

  5. Navigate to system/upstart/network-interface-net0.log

  6. MAC addr is the string after Listening on ...

Calibrate the Sawyer

From time to time the sawyer’s torque sensors will need to be calibrated. This is particularly important if the robot has been moved. To calibrate the Sawyer follow these instructions

Make sure the arm is not next to a wall as it will move around in all directions. You may have to move it (carefully!) to the middle of the room. Have your hand on the e-stop!

./intera.sh
rosrun intera_interface calibrate_arm.py