Robotics StackExchange | Archived questions

question related to mavros

Hi I want to ask sometihing. first, I got error when I used this command $ roslaunch px4 mavros_posix_sitl.launch and here is the error

... logging to /home/abdularis/.ros/log/27a0f1d6-ba3a-11e7-bf7a-94e9799ce369/roslaunch-abdularis-9598.log

Checking log directory for disk usage. This may take awhile.

Press Ctrl-C to interrupt

Done checking log file disk usage. Usage is <1GB.

Invalid tag: mavrossitlgazebo

ROS path [0]=/opt/ros/kinetic/share/ros

ROS path [1]=/home/abdularis/catkin_ws/src/mavlink

ROS path [2]=/home/abdularis/catkin_ws/src/mavros/libmavconn

ROS path [3]=/home/abdularis/catkinws/src/mavros/mavrosmsgs

ROS path [4]=/home/abdularis/catkin_ws/src/mavros/mavros

ROS path [5]=/home/abdularis/catkinws/src/mavros/mavrosextras

ROS path [6]=/home/abdularis/catkin_ws/src/Firmware

ROS path [7]=/home/abdularis/catkinws/src/mavros/testmavros

ROS path [8]=/opt/ros/kinetic/share

ROS path [9]=/home/abdularis/catkin_ws/src/Firmware

ROS path [10]=/home/abdularis/catkinws/src/Firmware/Tools/sitlgazebo.

Arg xml is

The traceback for the exception was written to the log file

and the second question is I try another method to run gazebo and ros with mavros with this several command that I got from dev px4 site

$ roslaunch mavros px4.launch fcu_url:="udp://:14540@127.0.0.1:14557"

$ no_sim=1 make posix_sitl_default gazebo

and when I call iris world file with this

$ roslaunch gazebo_ros empty_world.launch world_name:=$(pwd)/Tools/sitl_gazebo/worlds/iris.world

I got this error

INFO [logger] Start file log

INFO [logger] Opened log file: rootfs/fs/microsd/log/2017-10-26/095324.ulg

INFO [mavlink] partner IP: 127.0.0.1

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

INFO [lib__ecl] EKF aligned, (pressure height, IMU buf: 15, OBS buf: 14)

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

INFO [lib__ecl] EKF GPS checks passed (WGS-84 origin set)

INFO [lib__ecl] EKF commencing GPS fusion

INFO [commander] home: 47.3977419, 8.5455938, 488.02

INFO [tonealarm] homeset

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

ERROR [mavlink] [timesync] Hard setting offset.

Asked by abdul.aris on 2017-10-27 02:12:43 UTC

Comments

To your second question. Are you sure the iris model's been spawned in Gazebo? Check your communication with rostopic echo -n 1 /diagnostics.

Asked by l4ncelot on 2017-10-27 03:33:53 UTC

Answers

I'll answer the first part of your question because it's ROS related. The second part should be asked on px4 firmware github here.

Your roslaunch can't find package called mavros_sitl_gazebo. Did you modify this value yourself? If so the package either doesn't exist or you forgot to source it. That's probably why ROS can't find it.

To your second question it's probably problem with connection of MAVROS to px4. I can advice you to take a look at diagnostics topic with rostopic echo -n 1 /diagnostics. It should give you a hint if your px4 is connected to MAVROS or not. But either way you should ask on px4 firmware in my opinion.

Anyway look at those .launch file provided by px4 and try to understand what's going on there. It'll be very hard for you to do something useful with it if you have no idea how the communication is established etc. It also took me a while to figure things out.

Asked by l4ncelot on 2017-10-27 03:20:48 UTC

Comments

no I dont change anything. The code and anything related still the same from the source. Any idea how to fix it? thanks for your advice, I will ask on px4 firmware github

Asked by abdul.aris on 2017-10-27 06:42:32 UTC

Here is the current version of mavros_posix_sitl.launch file. The package is called mavlink_sitl_gazebo. Try to clone the package again with the latest source. Or perhaps change the version to some stable version.

Asked by l4ncelot on 2017-10-27 06:48:05 UTC

You can change to the 1.6.5 stable version with git checkout tags/v1.6.5 command.

Asked by l4ncelot on 2017-10-27 06:49:42 UTC