Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spacenav Error while using moveit servo tutorial #754

Open
Akumar201 opened this issue Feb 2, 2023 · 9 comments · Fixed by ros-drivers/joystick_drivers#250
Open

Spacenav Error while using moveit servo tutorial #754

Akumar201 opened this issue Feb 2, 2023 · 9 comments · Fixed by ros-drivers/joystick_drivers#250

Comments

@Akumar201
Copy link
Contributor

Background

I am following the (moveit servoing tutorial)[https://ros-planning.github.io/moveit_tutorials/doc/realtime_servo/realtime_servo_tutorial.html], however I am getting the following error related to spacenavd

[ERROR] [1669672889.199512421]: Could not open the space navigator device. Did you remember to run spacenavd (as root)?
[spacenav_node_abc_ThinkPad_P17_Gen_2i_29034_5978491666214438105-1] process has died [pid 29049, exit code 1, cmd /home/abc/ws_moveit/devel/lib/spacenav_node/spacenav_node __name:=spacenav_node_abc_ThinkPad_P17_Gen_2i_29034_5978491666214438105 __log:=/home/abc/.ros/log/7bcc805e-6f61-11ed-8cc6-fb1b3c97baa8/spacenav_node_abc_ThinkPad_P17_Gen_2i_29034_5978491666214438105-1.log].
log file: /home/abc/.ros/log/7bcc805e-6f61-11ed-8cc6-fb1b3c97baa8/spacenav_node_abc_ThinkPad_P17_Gen_2i_29034_5978491666214438105-1*.log

Instructions

I did git clone UR Repo.
Run the following command

  1. roslaunch ur5_bringup.launch
  2. roslaunch moveit_planning_execution.launch sim:=true
  3. roslaunch move_group.launch

However, after the roslaunch move_group.launch I am getting the above error.
I tried to fix the the code using the following site http://wiki.ros.org/spacenav_node/Troubleshooting

I am using Ubuntu 20.04 and ROS Noetic

@AndyZe
Copy link
Member

AndyZe commented Feb 2, 2023

It sounds like this is not a MoveIt question but it's really about getting the SpaceNav input device to work on Linux. But if you learn something useful, it might be nice to add to the tutorial!

If you plug the SpaceNav in, do you see a new entry in the /dev/input folder? Does it go away when you unplug it? That's a basic first test.

Here's a Google search that will probably help: https://www.google.com/search?channel=fs&client=ubuntu&q=linux+spacenavd

@rhaschke
Copy link
Contributor

rhaschke commented Feb 3, 2023

Try installing the spacenav daemon: sudo apt install spacenavd. Looks like this dependency is missing in spacenav_node.

@gavanderhoorn
Copy link
Member

Afaik the daemon is not needed on recent Linux kernels. It's also deprecated I believe.

The "only" thing you'll miss are some configuration options.

@rhaschke
Copy link
Contributor

rhaschke commented Feb 3, 2023

The spacenav_node explicitly asked for the daemon: Did you remember to run spacenavd (as root)?
Sure, one doesn't need the daemon to access the input device directly, but the spacenav_node still relies on spacenavd, calling spnav_open(), which is linked to spacenavd.

@gavanderhoorn
Copy link
Member

gavanderhoorn commented Feb 3, 2023

You don't even need the spacenav_node. A spacenav registers as a generic joystick HID device on recent kernels. You can just use joy and a suitable node to convert that to Twist or Wrench (fi).

I've never missed the daemon.

@rhaschke
Copy link
Contributor

rhaschke commented Feb 3, 2023

So, we should cleanup moveit_servo to not use spacenav_node anymore...

@gavanderhoorn
Copy link
Member

I don't know. I just wanted to report my experiences with spacenavs and ROS and whether the spacenav_node is still needed.

@Akumar201
Copy link
Contributor Author

I guess , yes cleaning up the spacenav_node would be good Idea. @rhaschke I am working on making a easy example using with detail pose_tracking_example.launch , I would love to share it with the community.

@AndyZe
Copy link
Member

AndyZe commented Feb 15, 2023

Noting that there currently is no dependency on spacenav in MoveIt2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants