Ask Your Question
0

mavros, sitl, gazebo not working topics

asked 2019-06-07 04:44:39 -0500

sergioma gravatar image

updated 2019-06-07 05:40:21 -0500

gvdhoorn gravatar image

I need some help. I'm doing the offboard tutorial explained in https://dev.px4.io/en/ros/mavros_offboard.html. I have followed all the steps and finally when I launch the node no topic publishes anything. I have installed and deleted the packages 6 times, I have tried to install from source or binary. I have consulted many forums and I can not know what is the problem I have and because my drone does not take off. Please, I need someone's help because I'm desperate.

I have uploaded all my configuration of both ros, catkin workspace and PX4/Firmware in my github repository because I don't find the problem https://github.com/sergioma295/Drone_Ros

I explain the most important steps I have taken below:

For "make px4_sitl gazebo" work fine and Iris in Gazebo simulator is armed and take off correctly.

After that:

cd ~/src/Firmware
make px4_sitl_default gazebo/
source Tools/setup_gazebo.bash $(pwd) $(pwd)/build/px4_sitl_default
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:$(pwd)
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:$(pwd)/Tools/sitl_gazebo
roslaunch px4 posix_sitl.launch

And finally, I launch the scripts:

sergio@sergio-ing:~/catkin_ws$ ./launch-offb.sh 
GAZEBO_PLUGIN_PATH :/home/sergio/src/Firmware/build/posix_sitl_default/build_gazebo
GAZEBO_MODEL_PATH :/home/sergio/src/Firmware/Tools/sitl_gazebo/models
LD_LIBRARY_PATH /home/sergio/catkin_ws/devel/lib:/opt/ros/kinetic/lib:/opt/ros/kinetic/lib/x86_64-linux-gnu:/usr/local/cuda-9.0/lib64:/home/sergio/src/Firmware/build/posix_sitl_default/build_gazebo
... logging to /home/sergio/.ros/log/08d278c6-8903-11e9-bdb6-309c23913dfd/roslaunch-sergio-ing-7231.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.

started roslaunch server http://localhost:36531/

SUMMARY
========

CLEAR PARAMETERS
 * /mavros/

PARAMETERS
 * /mavros/cmd/use_comp_id_system_control: False
 * /mavros/conn/heartbeat_rate: 1.0
 * /mavros/conn/system_time_rate: 1.0
 * /mavros/conn/timeout: 10.0
 * /mavros/conn/timesync_rate: 10.0
 * /mavros/distance_sensor/hrlv_ez4_pub/field_of_view: 0.0
 * /mavros/distance_sensor/hrlv_ez4_pub/frame_id: hrlv_ez4_sonar
 * /mavros/distance_sensor/hrlv_ez4_pub/id: 0
 * /mavros/distance_sensor/hrlv_ez4_pub/orientation: PITCH_270
 * /mavros/distance_sensor/hrlv_ez4_pub/send_tf: True
 * /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/x: 0.0
 * /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/y: 0.0
 * /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/z: -0.1
 * /mavros/distance_sensor/laser_1_sub/id: 3
 * /mavros/distance_sensor/laser_1_sub/orientation: PITCH_270
 * /mavros/distance_sensor/laser_1_sub/subscriber: True
 * /mavros/distance_sensor/lidarlite_pub/field_of_view: 0.0
 * /mavros/distance_sensor/lidarlite_pub/frame_id: lidarlite_laser
 * /mavros/distance_sensor/lidarlite_pub/id: 1
 * /mavros/distance_sensor/lidarlite_pub/orientation: PITCH_270
 * /mavros/distance_sensor/lidarlite_pub/send_tf: True
 * /mavros/distance_sensor/lidarlite_pub/sensor_position/x: 0.0
 * /mavros/distance_sensor/lidarlite_pub/sensor_position/y: 0.0
 * /mavros/distance_sensor/lidarlite_pub/sensor_position/z: -0.1
 * /mavros/distance_sensor/sonar_1_sub/id: 2
 * /mavros/distance_sensor/sonar_1_sub/orientation: PITCH_270
 * /mavros/distance_sensor/sonar_1_sub/subscriber: True
 * /mavros/fake_gps/eph: 2.0
 * /mavros/fake_gps/epv: 2.0
 * /mavros/fake_gps/fix_type: 3
 * /mavros/fake_gps/geo_origin/alt: 408.0
 * /mavros/fake_gps/geo_origin/lat: 47.3667
 * /mavros/fake_gps/geo_origin/lon: 8.55
 * /mavros/fake_gps/gps_rate: 5.0
 * /mavros/fake_gps/mocap_transform: True
 * /mavros/fake_gps/satellites_visible: 5
 * /mavros/fake_gps/tf/child_frame_id: fix
 * /mavros/fake_gps/tf/frame_id: map
 * /mavros/fake_gps/tf/listen: False
 * /mavros/fake_gps/tf/rate_limit: 10.0
 * /mavros/fake_gps/tf/send: False
 * /mavros/fake_gps/use_mocap: True
 * /mavros/fake_gps/use_vision: False ...
(more)
edit retag flag offensive close merge delete

Comments

Please check your formatting next time. Askbot does not support markdown, so backticks do not work.

gvdhoorn gravatar imagegvdhoorn ( 2019-06-07 05:40:42 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-09-20 01:39:14 -0500

Apurv15101 gravatar image

As shown in Rqt_Graph there is /offb is being published I am not able to get the error correctly.

I will suggest you to use shell scripts to launch the Firmware It will definitely work.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2019-06-07 04:44:39 -0500

Seen: 288 times

Last updated: Jun 07