Tele-operation of Spot Robot arm using Hololens 2
spot_rosat https://github.com/willat343/spot_ros.
Make sure that the estop gentle command is in the terminal, ready to be called when the robot starts working improperly:
rosservice call /spot/estop/gentleClone this repository to your catkin_ws:
cd ~/catkin_ws/src
git clone git@github.com:MixedRealityETHZ/spot_arm.git
cd ~/catkin_ws
catkin buildThis is a ROS package for controlling the Spot arm from a stream of geometry_msgs/PoseStamped messages, such as from a Hololens 2 or published by the user.
First the spot_ros driver must be running on the robot, replacing PASSWORD with the spot password. Source the correct workspace and run the roslaunch.
source ws/devel/setup.bash
roslaunch spot_driver driver.launch hostname:=192.168.50.3 username:=admin password:=PASSWORD max_linear_velocity_x:=1.0 max_linear_velocity_y:=1.0 max_angular_velocity_z:=1.0Also launch the tcp endpoint with default args:
source ws/devel/setup.bash
roslaunch ros_tcp_endpoint endpoint.launchTo configure your local machine to see Spot as the ROS master. Run hostname -I to get your ip address (e.g. <local_ip_address> = 192.168.1.28):
export ROS_MASTER_URI=http://192.168.1.243:11311
export ROS_IP=<local_ip_address>To launch the camera compressed stream, run the following commands:
source ws/devel/setup.bash
roslaunch spot_arm_interface spot_arm_camera_republish.launchTo launch the arm interface, optionally turning rviz on:
source ws/devel/setup.bash
roslaunch spot_arm_interface spot_arm_interface.launch rviz:=falseTo launch the Unity to ROS pose transformation node:
source ws/devel/setup.bash
rosrun unity_transform unity_to_ros_pose.py- Make sure you are launching with the max linear and max angular velocity variables set to non-zero values, such as 1.0.
- Check that
move_spot_body_enabledis set totrueindefault.yaml - Try
rosrun spot_move_interface spot_move_clientand publish a pose to/spot_move_client/pose. - If any of the cameras are not working (error messages in driver terminal), then this may stop spot movement
sudo apt install ros-noetic-moveitcd ~/catkin_ws/src
git clone git@github.com:estherRay/Spot-Arm.git
cd ~/catkin_ws
catkin buildWe are still working out the usage for this package. To launch the demo with gazebo + rviz:
roslaunch spot_moveit_config demo_gazebo.launchTo launch with without gazebo:
roslaunch spot_moveit_config demo.launchKnown Issue: in the Gazebo version, executation fails with an error like:
[ERROR] [1666736964.727028347, 25.118000000]: Unable to identify any set of controllers that can actuate the specified joints: [ Rev10 Rev11 Rev3 Rev6 Rev8 Rev9 ]
[ERROR] [1666736964.727042432, 25.118000000]: Known controllers and their joints:
[ INFO] [1666736964.738207870, 25.130000000]: ABORTED: Solution found but controller failed during execution
This repository contains a Spot gazebo simulation. Before using it, make sure that you have necessary packages installed:
sudo apt install ros-$(rosversion -d)-effort-controllers \
ros-$(rosversion -d)-joint-state-controller \
ros-$(rosversion -d)-joint-state-publisher-gui \
ros-$(rosversion -d)-interactive-marker-twist-server \
ros-$(rosversion -d)-robot-state-publisher \
ros-$(rosversion -d)-teleop-legged-robotsClone the repository to your catkin workspace:
cd ~/catkin_ws/src
git clone git@github.com:SoftServeSAG/spot_simulation.git
cd spot_simulation
git checkout spot_control
cd ~/catkin_ws
catkin buildIf you work with Noetic ROS distro, you need to patch the spot_simulation/rs_description/launch/description.launch file by replacing type="state_publisher" with type="robot_state_publisher".
To launch the simulation environment:
roslaunch rs_gazebo HQ.launchOnce HQ is ready, spawn robot with:
roslaunch rs_gazebo robot.launchFor various control operations, consult the Control README Section. For example:
roslaunch rs_control talker.launch If you work on Windows with WSL2, make sure to follow this tutorial to have GUI apps (e.g. Gazebo, RVIZ) running. Also see this video.
Synopsis:
- Install X-Launch from https://github.com/microsoft/mixed-reality-robot-interaction-demo/wiki/BuildingDemoFromSource#for-windows-installing-xserver
- Run X-Launch.
- Run the following lines in WSL2:
export GAZEBO_IP=127.0.0.1
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}'):0
export LIBGL_ALWAYS_INDIRECT=0