This repository has been forked from the following three repositories:
-
Francisco Suárez Ruiz, http://fsuarez6.github.io for the Sensable PHANToM haptic device (https://github.com/fsuarez6/phantom_omni)
-
Bharat Mathur https://github.com/bharatm11
-
By Johns Hopkins University https://github.com/jhu-cisst-external
ROS packages developed by the Group of Robots and Intelligent Machines from the Universidad Politécnica de Madrid. This group is part of the Centre for Automation and Robotics (CAR UPM-CSIC).
The goal of this repository is to facilitate the installation of:
- GeoMagic/3DS Touch hapic device drivers (USB or Ethernet based)
- OpenHaptics SDK (education version)
- ROS Drivers to communcate with the device on Ubuntu 18.04.
This was successfuly tested on Ubuntu 18.04 LTS 64 bits (Both VirtualBox and Bare Metal Installation) with ROS Melodic. (It didn't work for me on Ubuntu 20.04).
The 4 scripts provided in the scripts folder will perform most of the steps required to download/install OR un-install the files required for the Touch drivers as well as the OpenHaptics SDK.
- Install the OpenHaptics SDK using
source scripts/install-3ds-openhaptics-3.4.sh - Install the Touch Drivers using
source scripts/install-3ds-touch-drivers-2019.sh
- The scripts are provided to automate the installation process described in https://support.3dsystems.com/s/article/OpenHaptics-for-Linux-Developer-Edition-v34. The original instructions are given here The install is a bit different from the process described in the 3DS instructions:
- Environment variables are set in
/etc/profile.dinstead of/etc/environment
- Retart the PC after running the scripts
- Install the Dependencies
sudo apt-get install --no-install-recommends freeglut3-dev g++ libdrm-dev libexpat1-dev libglw1-mesa libglw1-mesa-dev libmotif-dev libncurses5-dev libraw1394-dev libx11-dev libxdamage-dev libxext-dev libxt-dev libxxf86vm-dev tcsh unzip x11proto-dri2-dev x11proto-gl-dev x11proto-print-dev
- Device setup
-
The haptic device creates a COM Port as /dev/ttyACM0 and requires admin priviliges
sudo chmod 777 /dev/ttyACM0. It may create a COM port with a diffferent name such as /dev/ttyACM0. Runls /devto check the available ports and change accordingly. -
Now run
Touch_Setupand ensure that the device serial number is displayed. Also click on 'Apply' followed by 'Ok' buttons in the Touch Setup GUI to initialize the device.
-
Run
Touch_Diagnostic. This can be used to calibrate the device, read encoders, apply test forces etc. -
Build the ROS Package by running
catkin_makecommand inside this repo -
Finally, run these commands everytime you need to launch the ROS Node
sudo chmod 777 /dev/ttyACM0 && source devel/setup.bash && roslaunch omni_common omni_state.launch
- Data from the haptic device can be read from the following rostopics (
rostopic list):
/phantom/button
/phantom/force_feedback
/phantom/joint_states
/phantom/pose
/phantom/state
eg: rostopic echo /phantom/pose