ROS + Morse launch error 8
Hi, I just picked up ROS and Morse and I'm trying to follow the Morse's tutorial on ROS Navigation. The tutorial can be found here. On the part that say to edit the file nav.launch, I followed what is said there, but when I run the command roslaunch morse_2dnav nav.launch
I get a error OSError: [Errno 8] Exec format error and I'm having a hard time solving this issue. Any help? I'm using Ubuntu 16.04.3, Morse Simulator v 1.2, ROS Lunar.
Edit:
Traceback (most recent call last):
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/__init__.py", line 318, in main
p.start()
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/parent.py", line 271, in start
self._start_infrastructure()
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/parent.py", line 220, in _start_infrastructure
self._load_config()
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/parent.py", line 135, in _load_config
roslaunch_strs=self.roslaunch_strs, verbose=self.verbose)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/config.py", line 451, in load_config_default
loader.load(f, config, verbose=verbose)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/xmlloader.py", line 750, in load
self._load_launch(launch, ros_config, is_core=core, filename=filename, argv=argv, verbose=verbose)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/xmlloader.py", line 722, in _load_launch
self._recurse_load(ros_config, launch.childNodes, self.root_context, None, is_core, verbose)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/xmlloader.py", line 666, in _recurse_load
self._param_tag(tag, context, ros_config, verbose=verbose)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/xmlloader.py", line 95, in call
return f(*args, **kwds)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/xmlloader.py", line 266, in _param_tag
value = self.param_value(verbose, name, ptype, *vals)
File "/opt/ros/lunar/lib/python2.7/dist-packages/roslaunch/loader.py", line 492, in param_value
p = subprocess.Popen(shlex.split(command), stdout=subprocess.PIPE)
File "/usr/lib/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1343, in _execute_child
raise child_exception
OSError: [Errno 8] Exec format error
My launch file, as described on the tutorial:
<launch>
<param name="robot_description" command="$(find morse_mcl)/robot.urdf" />
<node name="robot_state_publisher" pkg="robot_state_publisher" type="state_publisher" />
</launch>
The lsb_release -a
output is:
No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04.3 LTS Release: 16.04 Codename: xenial
Can you please be a bit more specific? What exactly are you changing, and please copy-paste the entire error message (including the stack trace) into your question. Use the
edit
button/link.Know that ROS+Morse is not a frequently used combination, so getting answers may take a while.
The changes are the one the tutorial specify (create the launch file and write the launch tags). I'll edit my question and post the exact launch file and the trace of the error. I'm trying to implement Monte Carlo Localization, do you know a better/easier combination to use?
Don't use
<pre>
tags for code, but indent it by 4 spaces. Use the Preformatted Text button for that (the one with101010
on it). Select the code, press the button (orctrl+k
).Were you instructed to create any Python scripts? If so: are they executable? Do they start with
#!/usr/bin/env python
?If not: how did you install ROS? Where did the
robot_state_publisher
come from?(also:
state_publisher
is deprecated, please userobot_state_publisher
)To run the simulation only on Morse it's needed a Python script, but it already have the
#!/usr/bin/env python
. I followed the instructions on ROS wiki to install ROS. I'll look if can be an error with thestate_publisher
being deprecated.no, that shouldn't be the problem.
The
Exec format error
is typically seen if you try to start a script (withbash
or another shell) and that doesn't specify which interpreter should be used. RSP is a C++ program.I see. The files listed on the error (
__init__.py
,parent.py
,config.py
,xmlloader.py
,loader.py
andsubprocess.py
) don't have that. Could that be it?No. They are all Python modules, not top-level scripts.
The problem is most likely with something that the launch file is trying to start (ie: a
node
or a script started as anode
). You could remove and add single lines to see which one is causing the problem.