tu-darmstadt-ros-pkg / hector_quadrotor

hector_quadrotor contains packages related to modeling, control and simulation of quadrotor UAV systems.
Other
381 stars 276 forks source link

What is the state of the Kinetic release? #68

Closed mathiasimmer closed 7 years ago

mathiasimmer commented 7 years ago

I tried to pull the source using

wstool init src https://raw.github.com/tu-darmstadt-ros-pkg/hector_quadrotor/kinetic-devel/tutorials.rosinstall

and after building the workspace I ran the command to start the demo:

roslaunch hector_quadrotor_demo indoor_slam_gazebo.launch

I have a Xbox 360 Controller connected to my PC and verified using jstest that the controller works. I can also see that messages are published on the /joy topic. However I cannot get the quadcopter to move when using the joystick.

Here is the terminal output and everything seems to be okay except for the "No command received" that occurs after a while.

$ roslaunch hector_quadrotor_demo indoor_slam_gazebo.launch
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://LAPTOP:35741/

SUMMARY
========

PARAMETERS
 * /action_timeout: 30.0
 * /base_footprint_frame: /base_footprint
 * /base_link_frame: /base_link
 * /base_stabilized_frame: /base_stabilized
 * /command_timeout: 0.5
 * /connection_timeout: 10.0
 * /controller/attitude/max_roll_pitch: 0.785398163
 * /controller/attitude/pitch/d: 20.0
 * /controller/attitude/pitch/i: 0.0
 * /controller/attitude/pitch/p: 100.0
 * /controller/attitude/pitch/publish_state: True
 * /controller/attitude/roll/d: 20.0
 * /controller/attitude/roll/i: 0.0
 * /controller/attitude/roll/p: 100.0
 * /controller/attitude/roll/publish_state: True
 * /controller/attitude/type: hector_quadrotor_...
 * /controller/attitude/yawrate/d: 0.5
 * /controller/attitude/yawrate/i: 0.0
 * /controller/attitude/yawrate/max: 3.14
 * /controller/attitude/yawrate/p: 5.0
 * /controller/attitude/yawrate/publish_state: True
 * /controller/position/type: hector_quadrotor_...
 * /controller/position/x/d: 0.0
 * /controller/position/x/i: 0.0
 * /controller/position/x/p: 2.0
 * /controller/position/y/d: 0.0
 * /controller/position/y/i: 0.0
 * /controller/position/y/p: 2.0
 * /controller/position/yaw/d: 0.0
 * /controller/position/yaw/i: 0.0
 * /controller/position/yaw/p: 2.0
 * /controller/position/z/d: 0.0
 * /controller/position/z/i: 0.0
 * /controller/position/z/p: 2.0
 * /controller/velocity/max_xy: 10.0
 * /controller/velocity/type: hector_quadrotor_...
 * /controller/velocity/x/antiwindup: True
 * /controller/velocity/x/d: 0.0
 * /controller/velocity/x/i: 1.0
 * /controller/velocity/x/i_clamp: 5.0
 * /controller/velocity/x/p: 2.0
 * /controller/velocity/x/publish_state: True
 * /controller/velocity/y/antiwindup: True
 * /controller/velocity/y/d: 0.0
 * /controller/velocity/y/i: 1.0
 * /controller/velocity/y/i_clamp: 5.0
 * /controller/velocity/y/p: 2.0
 * /controller/velocity/y/publish_state: True
 * /controller/velocity/z/antiwindup: True
 * /controller/velocity/z/d: 0.0
 * /controller/velocity/z/i: 1.0
 * /controller/velocity/z/i_clamp: 5.0
 * /controller/velocity/z/max: 5.0
 * /controller/velocity/z/p: 5.0
 * /controller/velocity/z/publish_state: True
 * /dist_tolerance: 0.1
 * /estop_deceleration: 1.0
 * /estop_relay/lazy: True
 * /ground_truth_to_tf/frame_id: world
 * /ground_truth_to_tf/odometry_topic: ground_truth/state
 * /ground_truth_to_tf/tf_prefix: 
 * /hector_geotiff_node/draw_background_checkerboard: True
 * /hector_geotiff_node/draw_free_space_grid: True
 * /hector_geotiff_node/geotiff_save_period: 0.0
 * /hector_geotiff_node/map_file_base_name: hector_slam_map
 * /hector_geotiff_node/map_file_path: /home/mathias/Skr...
 * /hector_geotiff_node/plugins: hector_geotiff_pl...
 * /hector_mapping/advertise_map_service: True
 * /hector_mapping/base_frame: base_footprint
 * /hector_mapping/laser_z_max_value: 1.0
 * /hector_mapping/laser_z_min_value: -1.0
 * /hector_mapping/map_frame: map
 * /hector_mapping/map_multi_res_levels: 2
 * /hector_mapping/map_resolution: 0.05
 * /hector_mapping/map_size: 2048
 * /hector_mapping/map_start_x: 0.5
 * /hector_mapping/map_start_y: 0.5
 * /hector_mapping/map_update_angle_thresh: 0.06
 * /hector_mapping/map_update_distance_thresh: 0.4
 * /hector_mapping/odom_frame: world
 * /hector_mapping/pub_map_odom_transform: True
 * /hector_mapping/scan_subscriber_queue_size: 5
 * /hector_mapping/scan_topic: scan
 * /hector_mapping/tf_map_scanmatch_transform_frame_name: scanmatcher_frame
 * /hector_mapping/update_factor_free: 0.4
 * /hector_mapping/update_factor_occupied: 0.9
 * /hector_mapping/use_tf_pose_start_estimate: False
 * /hector_mapping/use_tf_scan_transformation: True
 * /hector_trajectory_server/source_frame_name: /base_link
 * /hector_trajectory_server/target_frame_name: /map
 * /hector_trajectory_server/trajectory_publish_rate: 4.0
 * /hector_trajectory_server/trajectory_update_rate: 4.0
 * /imu_topic: 
 * /joy/autorepeat_rate: 10
 * /joy/coalesce_interval: 0.01
 * /joy/dev: /dev/input/js0
 * /landing_height: 0.1
 * /quadrotor_aerodynamics/C_mxy: 0.074156208
 * /quadrotor_aerodynamics/C_mz: 0.050643264
 * /quadrotor_aerodynamics/C_wxy: 0.12
 * /quadrotor_aerodynamics/C_wz: 0.1
 * /quadrotor_propulsion/CT0s: 1.53819048398e-05
 * /quadrotor_propulsion/CT1s: -0.00025224
 * /quadrotor_propulsion/CT2s: 0.0
 * /quadrotor_propulsion/J_M: 2.5730480633e-05
 * /quadrotor_propulsion/Psi: 0.00724217982751
 * /quadrotor_propulsion/R_A: 0.201084219222
 * /quadrotor_propulsion/alpha_m: 0.104863758314
 * /quadrotor_propulsion/beta_m: 0.549262344778
 * /quadrotor_propulsion/k_m: -7.01163190977e-05
 * /quadrotor_propulsion/k_t: 0.0153368647144
 * /quadrotor_propulsion/l_m: 0.275
 * /robot_description: <?xml version="1....
 * /robot_state_publisher/publish_frequency: 50.0
 * /rosdistro: kinetic
 * /rosversion: 1.12.7
 * /state_timeout: 0.5
 * /state_topic: 
 * /takeoff_height: 0.1
 * /teleop/control_mode: position
 * /teleop/go_button: 6
 * /teleop/slow_button: 4
 * /teleop/stop_button: 2
 * /teleop/thrust_axis: -3
 * /teleop/x_axis: 5
 * /teleop/y_axis: 4
 * /teleop/yaw_axis: 1
 * /teleop/z_axis: 2
 * /tf_prefix: 
 * /time_in_tolerance: 1.0
 * /use_sim_time: True
 * /world_frame: world
 * /wrench_limits/force/z/max: 30.0
 * /wrench_limits/force/z/min: 0.0
 * /wrench_limits/torque/x/max: 10.0
 * /wrench_limits/torque/y/max: 10.0
 * /wrench_limits/torque/z/max: 1.0
 * /yaw_tolerance: 0.35

NODES
  /
    controller_spawner (controller_manager/spawner)
    estop_relay (topic_tools/relay)
    gazebo (gazebo_ros/gzserver)
    gazebo_gui (gazebo_ros/gzclient)
    ground_truth_to_tf (message_to_tf/message_to_tf)
    hector_geotiff_node (hector_geotiff/geotiff_node)
    hector_mapping (hector_mapping/hector_mapping)
    hector_trajectory_server (hector_trajectory_server/hector_trajectory_server)
    joy (joy/joy_node)
    landing_action (hector_quadrotor_actions/landing_action)
    pose_action (hector_quadrotor_actions/pose_action)
    robot_state_publisher (robot_state_publisher/robot_state_publisher)
    rviz (rviz/rviz)
    spawn_robot (gazebo_ros/spawn_model)
    takeoff_action (hector_quadrotor_actions/takeoff_action)
    teleop (hector_quadrotor_teleop/quadrotor_teleop)

auto-starting new master
process[master]: started with pid [10236]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to 70b85d1a-0576-11e7-8a03-c485085c36f4
process[rosout-1]: started with pid [10249]
started core service [/rosout]
process[gazebo-2]: started with pid [10273]
process[gazebo_gui-3]: started with pid [10278]
process[robot_state_publisher-4]: started with pid [10283]
process[ground_truth_to_tf-5]: started with pid [10284]
process[controller_spawner-6]: started with pid [10285]
process[estop_relay-7]: started with pid [10294]
process[pose_action-8]: started with pid [10296]
process[landing_action-9]: started with pid [10301]
process[takeoff_action-10]: started with pid [10304]
process[spawn_robot-11]: started with pid [10312]
process[hector_mapping-12]: started with pid [10331]
process[hector_trajectory_server-13]: started with pid [10336]
process[hector_geotiff_node-14]: started with pid [10339]
process[rviz-15]: started with pid [10344]
process[joy-16]: started with pid [10347]
process[teleop-17]: started with pid [10352]
[ WARN] [1489139192.646654122]: The root link base_link has an inertia specified in the URDF, but KDL does not support a root link with an inertia.  As a workaround, you can add an extra dummy link to your URDF.
SpawnModel script started
[ INFO] [1489139193.057176667]: waitForService: Service [/enable_motors] has not been advertised, waiting...
[INFO] [1489139193.168022, 0.000000]: Loading model XML from ros parameter
[INFO] [1489139193.179690, 0.000000]: Waiting for service /gazebo/spawn_urdf_model
[ INFO] [1489139193.204367958]: Opened joystick: /dev/input/js0. deadzone_: 0.050000.
[ INFO] [1489139193.211239701]: Waiting for tf transform data between frames /map and /base_link to become available
[ INFO] [1489139193.248154579]: waitForService: Service [/enable_motors] has not been advertised, waiting...
[ INFO] [1489139193.257335582]: waitForService: Service [/enable_motors] has not been advertised, waiting...
[INFO] [1489139193.281005, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
[ INFO] [1489139193.306776629]: Finished loading Gazebo ROS API Plugin.
[ INFO] [1489139193.313508463]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
[ERROR] [1489139193.352567946]: Skipping XML Document "/opt/ros/kinetic/share/hector_worldmodel_geotiff_plugins/hector_geotiff_plugins.xml" which had no Root Element.  This likely means the XML is malformed or missing.
HectorSM map lvl 0: cellLength: 0.05 res x:2048 res y: 2048
[ INFO] [1489139193.438051658]: Successfully initialized hector_geotiff MapWriter plugin TrajectoryMapWriter.
[ INFO] [1489139193.438126839]: Geotiff node started
HectorSM map lvl 1: cellLength: 0.1 res x:1024 res y: 1024
[ INFO] [1489139193.518336015]: HectorSM p_base_frame_: base_footprint
[ INFO] [1489139193.519155701]: HectorSM p_map_frame_: map
[ INFO] [1489139193.519178735]: HectorSM p_odom_frame_: world
[ INFO] [1489139193.519198425]: HectorSM p_scan_topic_: scan
[ INFO] [1489139193.519215201]: HectorSM p_use_tf_scan_transformation_: true
[ INFO] [1489139193.519231583]: HectorSM p_pub_map_odom_transform_: true
[ INFO] [1489139193.519248704]: HectorSM p_scan_subscriber_queue_size_: 5
[ INFO] [1489139193.519267620]: HectorSM p_map_pub_period_: 2.000000
[ INFO] [1489139193.519284555]: HectorSM p_update_factor_free_: 0.400000
[ INFO] [1489139193.519300937]: HectorSM p_update_factor_occupied_: 0.900000
[ INFO] [1489139193.519317377]: HectorSM p_map_update_distance_threshold_: 0.400000 
[ INFO] [1489139193.519334324]: HectorSM p_map_update_angle_threshold_: 0.060000
[ INFO] [1489139193.519355830]: HectorSM p_laser_z_min_value_: -1.000000
[ INFO] [1489139193.519371821]: HectorSM p_laser_z_max_value_: 1.000000
[INFO] [1489139194.099464, 0.000000]: Calling service /gazebo/spawn_urdf_model
[ INFO] [1489139194.804122904, 0.001000000]: Camera Plugin: Using the 'robotNamespace' param: '/'
[ INFO] [1489139194.809711603, 0.001000000]: Camera Plugin (ns = /)  <tf_prefix_>, set to ""
[ INFO] [1489139195.908883783, 0.001000000]: Laser Plugin: Using the 'robotNamespace' param: '/'
[ INFO] [1489139195.909042652, 0.001000000]: Starting Laser Plugin (ns = /)!
[ INFO] [1489139195.912582321, 0.001000000]: Laser Plugin (ns = /)  <tf_prefix_>, set to ""
[INFO] [1489139195.922520, 0.001000]: Spawn status: SpawnModel: Successfully spawned model
[ INFO] [1489139196.039083897, 0.001000000]: imu plugin missing <xyzOffset>, defaults to 0s
[spawn_robot-11] process has finished cleanly
log file: /home/mathias/.ros/log/70b85d1a-0576-11e7-8a03-c485085c36f4/spawn_robot-11*.log
[ INFO] [1489139196.290092969, 0.001000000]: Loading gazebo_ros_control plugin
[ WARN] [1489139196.290270775, 0.001000000]: Desired controller update period (0.010000000 s) is slower than the gazebo simulation period (0.001000000 s).
[ INFO] [1489139196.290363475, 0.001000000]: Starting gazebo_ros_control plugin in namespace: /
[ INFO] [1489139196.291564625, 0.001000000]: gazebo_ros_control plugin is waiting for model URDF in parameter [robot_description] on the ROS param server.
[ INFO] [1489139196.456025245, 0.001000000]: Limits /wrench_limits/force/z initialized z with min 0 and max 30
[ INFO] [1489139196.460452127, 0.001000000]: Limits /wrench_limits/torque/x initialized x with min -10 and max 10
[ INFO] [1489139196.463020542, 0.001000000]: Limits /wrench_limits/torque/y initialized y with min -10 and max 10
[ INFO] [1489139196.465609115, 0.001000000]: Limits /wrench_limits/torque/z initialized z with min -1 and max 1
[ INFO] [1489139196.476497956, 0.001000000]: Loaded gazebo_ros_control.
Loaded the following quadrotor propulsion model parameters from namespace /quadrotor_propulsion:
k_m     = -7.01163e-05
k_t     = 0.0153369
CT2s    = 0
CT1s    = -0.00025224
CT0s    = 1.53819e-05
Psi     = 0.00724218
J_M     = 2.57305e-05
R_A     = 0.201084
l_m     = 0.275
alpha_m = 0.104864
beta_m  = 0.549262
Loaded the following quadrotor drag model parameters from namespace /quadrotor_aerodynamics:
C_wxy = 0.12
C_wz = 0.1
C_mxy = 0.0741562
C_mz = 0.0506433
[ INFO] [1489139196.558293430, 0.033000000]: waitForService: Service [/enable_motors] is now available.
[ INFO] [1489139196.560103616, 0.033000000]: waitForService: Service [/gazebo/set_physics_properties] is now available.
[ INFO] [1489139196.562055853, 0.033000000]: waitForService: Service [/enable_motors] is now available.
[ INFO] [1489139196.564285137, 0.034000000]: waitForService: Service [/enable_motors] is now available.
[INFO] [1489139196.644061, 0.079000]: Controller Spawner: Waiting for service controller_manager/switch_controller
[INFO] [1489139196.652188, 0.085000]: Controller Spawner: Waiting for service controller_manager/unload_controller
[INFO] [1489139196.660117, 0.088000]: Loading controller: controller/attitude
[ INFO] [1489139196.884373061, 0.203000000]: Physics dynamic reconfigure ready.
[ INFO] [1489139196.962929250, 0.239000000]: Server /action/pose started
[ INFO] [1489139197.486118593, 0.525000000]: Server /action/landing started
[ INFO] [1489139197.522931314, 0.541000000]: Server /action/takeoff started
[ INFO] [1489139197.551529474, 0.565000000]: lookupTransform base_footprint to laser0_frame timed out. Could not transform laser scan into base_frame.
[ INFO] [1489139198.169717477, 0.846000000]: Limits /controller/attitude/yawrate initialized yawrate with min -3.14 and max 3.14
[INFO] [1489139198.196780, 0.860000]: Loading controller: controller/velocity
[ INFO] [1489139198.212254113, 0.870000000]: Finished waiting for tf, waited 0.870000 seconds
[ INFO] [1489139199.415055860, 1.526000000]: Limits /controller/velocity/z initialized z with min -5 and max 5
[INFO] [1489139199.469027, 1.550000]: Loading controller: controller/position
[INFO] [1489139200.525994, 2.140000]: Controller Spawner: Loaded controllers: controller/attitude, controller/velocity, controller/position
[ INFO] [1489139200.549393861, 2.150000000]: Enabled wrench output
[INFO] [1489139200.551340, 2.150000]: Started controllers: controller/attitude, controller/velocity, controller/position
[ INFO] [1489139200.581150902, 2.159000000]: Enabled attitude output
[ INFO] [1489139200.582307278, 2.160000000]: Enabled yawrate output
[ INFO] [1489139200.582628328, 2.160000000]: Enabled thrust output
[ WARN] [1489139222.024206023, 13.930000000]: No command received for 13.93s, triggering estop
[ INFO] [1489139222.024530826, 13.930000000]: Enabled twist output
[ WARN] [1489139223.835947583, 15.042000000]: Landing succeeded
[ INFO] [1489139223.849535378, 15.048000000]: Disabled position control while motors are not running.
[ INFO] [1489139223.849928807, 15.050000000]: Disabled twist control
[ WARN] [1489139226.249531528, 16.389000000]: No command received for 16.39s, triggering estop
[ INFO] [1489139226.250238322, 16.390000000]: Enabled twist output
[ WARN] [1489139228.429194004, 17.401000000]: Landing succeeded
[ INFO] [1489139228.442473618, 17.410000000]: Disabled position control while motors are not running.
[ INFO] [1489139228.442615241, 17.410000000]: Disabled twist control
[ WARN] [1489139252.970414402, 31.020000000]: No command received for 31.02s, triggering estop
[ INFO] [1489139252.970810398, 31.020000000]: Enabled twist output
[ WARN] [1489139254.970727051, 32.134000000]: Landing succeeded
[ INFO] [1489139254.978446760, 32.140000000]: Disabled position control while motors are not running.
[ INFO] [1489139254.978830125, 32.140000000]: Disabled twist control
[ WARN] [1489139254.996300765, 32.150000000]: No command received for 32.15s, triggering estop
[ INFO] [1489139254.998258974, 32.150000000]: Enabled twist output
[ WARN] [1489139256.963473924, 33.247000000]: Landing succeeded
[ INFO] [1489139256.980008264, 33.249000000]: Disabled position control while motors are not running.
[ INFO] [1489139256.980109532, 33.249000000]: Disabled twist control
mathiasimmer commented 7 years ago

I found #66 however calling the enable_motors service does not appear to make a difference.

mathiasimmer commented 7 years ago

So after digging around the source could I discovered what I was missing. I did not know that you have to hold down RB on the Xbox controller for the joystick input to register. Also calling enable_motors turned out to be necessary.