Closed FantasyWilly closed 11 months ago
Hi @FantasyWilly - looks like a connection problem. Can you provide some more info about your system:
gz sim --version
).And can you also post the full logs of:
gz sim
sim_vehicle.py
sim_vehicle.py
)Please post console outputs as formatted text, not screenshots.
Thank you for your response.
SITL log : Set parameter SIM_SPEEDUP to 1.000000 Starting sketch 'ArduCopter' Starting SITL input Using Irlock at port : 9005 bind port 5760 for 0 Serial port 0 on TCP port 5760 Waiting for connection .... Connection on serial port 0 Loaded defaults from /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm Home: -35.363262 149.165237 alt=584.000000m hdg=353.000000 Smoothing reset at 0.001 bind port 5762 for 2 Serial port 2 on TCP port 5762 bind port 5763 for 3 Serial port 3 on TCP port 5763 validate_structures:411: Validating structures Loaded defaults from /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm
Also need the output from Gazebo. I suspect the plugin is not being found / loaded. So there will be no connection, but need the gz sim
log to confirm.
I entered the following command : gz sim -v4 -r iris_runway.sdf
Gazebo terminal :
[Msg] Gazebo Sim GUI v7.5.0
[Dbg] [gz.cc:163] Subscribing to [/gazebo/starting_world].
[Dbg] [gz.cc:165] Waiting for a world to be set from the GUI...
[Dbg] [Gui.cc:260] Waiting for subscribers to [/gazebo/starting_world]...
[Msg] Received world [iris_runway.sdf] from the GUI.
[Dbg] [gz.cc:169] Unsubscribing from [/gazebo/starting_world].
[Msg] Gazebo Sim Server v7.5.0
[Msg] Loading SDF world file[/home/fantasywilly/ardupilot_gazebo/worlds/iris_runway.sdf].
[Dbg] [Application.cc:96] Initializing application.
[Dbg] [Application.cc:128] Qt using OpenGL graphics interface
[GUI] [Dbg] [Application.cc:607] Create main window
[Msg] Serving entity system service on [/entity/system/add]
[Dbg] [Physics.cc:870] Loaded [gz::physics::dartsim::Plugin] from library [/usr/lib/x86_64-linux-gnu/gz-physics-6/engine-plugins/libgz-physics-dartsim-plugin.so]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::Physics] for entity [1]
[Dbg] [Sensors.cc:501] Configuring Sensors system
[Dbg] [Sensors.cc:420] SensorsPrivate::Run
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::Sensors] for entity [1]
[Dbg] [Sensors.cc:397] SensorsPrivate::RenderThread started
[Dbg] [Sensors.cc:243] Waiting for init
[Msg] Create service on [/world/iris_runway/create]
[Msg] Remove service on [/world/iris_runway/remove]
[Msg] Pose service on [/world/iris_runway/set_pose]
[Msg] Pose service on [/world/iris_runway/set_pose_vector]
[Msg] Light configuration service on [/world/iris_runway/light_config]
[Msg] Physics service on [/world/iris_runway/set_physics]
[Msg] SphericalCoordinates service on [/world/iris_runway/set_spherical_coordinates]
[Msg] Enable collision service on [/world/iris_runway/enable_collision]
[Msg] Disable collision service on [/world/iris_runway/disable_collision]
[Msg] Material service on [/world/iris_runway/visual_config]
[Msg] Material service on [/world/iris_runway/wheel_slip]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::UserCommands] for entity [1]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::SceneBroadcaster] for entity [1]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::Imu] for entity [1]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::NavSat] for entity [1]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::JointStatePublisher] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::LiftDrag] for entity [15]
[Msg] ApplyJointForce subscribing to Double messages on [/model/iris_with_ardupilot/joint/iris_with_standoffs::rotor_0_joint/cmd_force]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::ApplyJointForce] for entity [15]
[Msg] ApplyJointForce subscribing to Double messages on [/model/iris_with_ardupilot/joint/iris_with_standoffs::rotor_1_joint/cmd_force]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::ApplyJointForce] for entity [15]
[Msg] ApplyJointForce subscribing to Double messages on [/model/iris_with_ardupilot/joint/iris_with_standoffs::rotor_2_joint/cmd_force]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::ApplyJointForce] for entity [15]
[Msg] ApplyJointForce subscribing to Double messages on [/model/iris_with_ardupilot/joint/iris_with_standoffs::rotor_3_joint/cmd_force]
[Dbg] [SystemManager.cc:74] Loaded system [gz::sim::systems::ApplyJointForce] for entity [15]
[Dbg] [SystemManager.cc:74] Loaded system [ArduPilotPlugin] for entity [15]
[Msg] Loaded level [3]
[Msg] Serving world controls on [/world/iris_runway/control], [/world/iris_runway/control/state] and [/world/iris_runway/playback/control]
[Msg] Serving GUI information on [/world/iris_runway/gui/info]
[Msg] World [iris_runway] initialized with [1ms] physics profile.
[Msg] Serving world SDF generation service on [/world/iris_runway/generate_world_sdf]
[Msg] Serving world names on [/gazebo/worlds]
[Msg] Resource path add service on [/gazebo/resource_paths/add].
[Msg] Resource path get service on [/gazebo/resource_paths/get].
[Msg] Resource path resolve service on [/gazebo/resource_paths/resolve].
[Msg] Resource paths published on [/gazebo/resource_paths].
[Msg] Server control service on [/server_control].
[GUI] [Dbg] [PathManager.cc:67] Requesting resource paths through [/gazebo/resource_paths/get]
[GUI] [Dbg] [Gui.cc:340] GUI requesting list of world names. The server may be busy downloading resources. Please be patient.
[GUI] [Dbg] [PathManager.cc:56] Received resource paths.
[GUI] [Dbg] [Gui.cc:398] Requesting GUI from [/world/iris_runway/gui/info]...
[GUI] [Dbg] [GuiRunner.cc:149] Requesting initial state from [/world/iris_runway/state]...
[GUI] [Msg] Loading config [/home/fantasywilly/.gz/sim/7/gui.config]
[GUI] [Dbg] [Application.cc:459] Loading plugin [MinimalScene]
[GUI] [Dbg] [MinimalScene.cc:657] Creating gz-rendering interface for OpenGL
[GUI] [Dbg] [MinimalScene.cc:657] Creating gz-rendering interface for OpenGL
[GUI] [Dbg] [MinimalScene.cc:813] Creating render thread interface for OpenGL
[GUI] [Msg] Added plugin [3D View] to main window
[GUI] [Msg] Loaded plugin [MinimalScene] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libMinimalScene.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [EntityContextMenuPlugin]
[GUI] [Wrn] [Application.cc:859] [QT] file::/EntityContextMenuPlugin/EntityContextMenuPlugin.qml:52:3: QML RenderWindowOverlay: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
[GUI] [Wrn] [Application.cc:859] [QT] file::/EntityContextMenuPlugin/EntityContextMenuPlugin.qml:67:3: QML EntityContextMenu: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
[GUI] [Msg] Added plugin [Entity Context Menu] to main window
[GUI] [Msg] Loaded plugin [EntityContextMenuPlugin] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libEntityContextMenuPlugin.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [GzSceneManager]
[GUI] [Msg] Added plugin [Scene Manager] to main window
[GUI] [Msg] Loaded plugin [GzSceneManager] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libGzSceneManager.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [InteractiveViewControl]
[GUI] [Msg] Camera view controller topic advertised on [/gui/camera/view_control]
[GUI] [Msg] Camera reference visual topic advertised on [/gui/camera/view_control/reference_visual]
[GUI] [Msg] Camera view control sensitivity advertised on [/gui/camera/view_control/sensitivity]
[GUI] [Msg] Added plugin [Interactive view control] to main window
[GUI] [Msg] Loaded plugin [InteractiveViewControl] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libInteractiveViewControl.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [CameraTracking]
[GUI] [Msg] Added plugin [Camera tracking] to main window
[GUI] [Msg] Loaded plugin [CameraTracking] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libCameraTracking.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [MarkerManager]
[GUI] [Msg] Listening to stats on [/world/iris_runway/stats]
[GUI] [Msg] Added plugin [Marker Manager] to main window
[GUI] [Msg] Loaded plugin [MarkerManager] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libMarkerManager.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [SelectEntities]
[GUI] [Msg] Added plugin [Select entities] to main window
[GUI] [Msg] Loaded plugin [SelectEntities] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libSelectEntities.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [Spawn]
[GUI] [Msg] Added plugin [Spawn] to main window
[GUI] [Msg] Loaded plugin [Spawn] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libSpawn.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [VisualizationCapabilities]
[GUI] [Msg] View as transparent service on [/gui/view/transparent]
[GUI] [Msg] View as wireframes service on [/gui/view/wireframes]
[GUI] [Msg] View center of mass service on [/gui/view/com]
[GUI] [Msg] View inertia service on [/gui/view/inertia]
[GUI] [Msg] View collisions service on [/gui/view/collisions]
[GUI] [Msg] View joints service on [/gui/view/joints]
[GUI] [Msg] View frames service on [/gui/view/frames]
[GUI] [Msg] Added plugin [Visualization capabilities] to main window
[GUI] [Msg] Loaded plugin [VisualizationCapabilities] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libVisualizationCapabilities.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [WorldControl]
[GUI] [Msg] Using world control service [/world/iris_runway/control]
[GUI] [Msg] Listening to stats on [/world/iris_runway/stats]
[GUI] [Dbg] [WorldControl.cc:250] Using an event to share WorldControl msgs with the server
[GUI] [Msg] Added plugin [World control] to main window
[GUI] [Msg] Loaded plugin [WorldControl] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libWorldControl.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [WorldStats]
[GUI] [Msg] Listening to stats on [/world/iris_runway/stats]
[GUI] [Msg] Added plugin [World stats] to main window
[GUI] [Msg] Loaded plugin [WorldStats] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libWorldStats.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [Shapes]
[GUI] [Msg] Added plugin [Shapes] to main window
[GUI] [Msg] Loaded plugin [Shapes] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libShapes.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [Lights]
[GUI] [Msg] Added plugin [Lights] to main window
[GUI] [Msg] Loaded plugin [Lights] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libLights.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [TransformControl]
[GUI] [Msg] Added plugin [Transform control] to main window
[GUI] [Msg] Loaded plugin [TransformControl] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libTransformControl.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [Screenshot]
[GUI] [Msg] Screenshot service on [/gui/screenshot]
[GUI] [Msg] Added plugin [Screenshot] to main window
[GUI] [Msg] Loaded plugin [Screenshot] from path [/usr/lib/x86_64-linux-gnu/gz-gui-7/plugins/libScreenshot.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [CopyPaste]
[GUI] [Msg] Added plugin [Copy/Paste] to main window
[GUI] [Msg] Loaded plugin [CopyPaste] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libCopyPaste.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [ComponentInspector]
[GUI] [Msg] Added plugin [Component inspector] to main window
[GUI] [Msg] Loaded plugin [ComponentInspector] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libComponentInspector.so]
[GUI] [Dbg] [Application.cc:459] Loading plugin [EntityTree]
[GUI] [Wrn] [Application.cc:859] [QT] file::/EntityTree/EntityTree.qml:148:7: QML ToolButton: Detected anchors on an item that is managed by a layout. This is undefined behavior; use Layout.alignment instead.
[GUI] [Msg] Added plugin [Entity tree] to main window
[GUI] [Msg] Loaded plugin [EntityTree] from path [/usr/lib/x86_64-linux-gnu/gz-sim-7/plugins/gui/libEntityTree.so]
[GUI] [Dbg] [Application.cc:329] Loading window config
[GUI] [Msg] Using server control service [/server_control]
[GUI] [Dbg] [Application.cc:621] Applying config
[GUI] [Dbg] [MinimalScene.cc:657] Creating gz-rendering interface for OpenGL
[GUI] [Dbg] [MinimalScene.cc:813] Creating render thread interface for OpenGL
[Msg] Found no publishers on /stats, adding root stats topic
[Msg] Found no publishers on /clock, adding root clock topic
[Dbg] [SimulationRunner.cc:493] Creating PostUpdate worker threads: 7
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (0)
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (1)
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (2)
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (3)
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (4)
[Dbg] [SimulationRunner.cc:504] Creating postupdate worker thread (5)
[Msg] Found IMU sensor with name [iris_with_standoffs::imu_link::imu_sensor]
[Dbg] [ArduPilotPlugin.cc:1154] Computed IMU topic to be: world/iris_runway/model/iris_with_ardupilot/model/iris_with_standoffs/link/imu_link/sensor/imu_sensor/imu
[Dbg] [ImuSensor.cc:149] IMU data for [iris_with_ardupilot::iris_with_standoffs::imu_link::imu_sensor] advertised on [world/iris_runway/model/iris_with_ardupilot/model/iris_with_standoffs/link/imu_link/sensor/imu_sensor/imu]
[Msg] Serving scene information on [/world/iris_runway/scene/info]
[Msg] Serving graph information on [/world/iris_runway/scene/graph]
[Msg] Serving full state on [/world/iris_runway/state]
[Msg] Serving full state (async) on [/world/iris_runway/state_async]
[Msg] Publishing scene information on [/world/iris_runway/scene/info]
[Msg] Publishing entity deletions on [/world/iris_runway/scene/deletion]
[Msg] Publishing state changes on [/world/iris_runway/state]
[Msg] Publishing pose messages on [/world/iris_runway/pose/info]
[Msg] Publishing dynamic pose messages on [/world/iris_runway/dynamic_pose/info]
[Wrn] [Model.hh:69] Skipping serialization / deserialization for models with //pose/@relative_to attribute.
[Wrn] [Component.hh:144] Trying to serialize component with data type [N3sdf3v135WorldE], which doesn't have operator<<
. Component will not be serialized.
[Dbg] [EntityComponentManager.cc:1619] Updated state thread iterators: 20 threads processing around 3 entities each.
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
libEGL warning: DRI2: failed to create dri screen
libEGL warning: DRI2: failed to create dri screen
[GUI] [Dbg] [MinimalScene.cc:606] Create scene [scene]
[GUI] [Wrn] [Component.hh:189] Trying to deserialize component with data type [N3sdf3v135WorldE], which doesn't have operator>>
. Component will not be deserialized.
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Wrn] [Model.hh:98] Unable to deserialize sdf::Model
[GUI] [Dbg] [MinimalScene.cc:845] Creating texture node render interface for OpenGL
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [TransformControl.cc:450] TransformControl plugin is using camera [scene::Camera(65527)]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [Spawn.cc:308] Spawn plugin is using camera [scene::Camera(65527)]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [SelectEntities.cc:452] SelectEntities plugin is using camera [scene::Camera(65527)]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [MarkerManager.cc:171] Advertise /marker/list service.
[GUI] [Dbg] [MarkerManager.cc:181] Advertise /marker/list.
[GUI] [Dbg] [MarkerManager.cc:191] Advertise /marker_array.
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [CameraTracking.cc:171] CameraTrackingPrivate plugin is moving camera [scene::Camera(65527)]
[GUI] [Msg] Move to service on [/gui/move_to]
[GUI] [Msg] Follow service on [/gui/follow]
[GUI] [Msg] Move to pose service on [/gui/move_to/pose]
[GUI] [Msg] Camera pose topic advertised on [/gui/camera/pose]
[GUI] [Msg] Follow offset service on [/gui/follow/offset]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [InteractiveViewControl.cc:178] InteractiveViewControl plugin is moving camera [scene::Camera(65527)]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Msg] Loading plugin [gz-rendering-ogre2]
[GUI] [Dbg] [EntityContextMenuPlugin.cc:79] Entity context menu plugin is using camera [scene::Camera(65527)]
I entered the following command : sim_vehicle.py -v ArduCopter -f gazebo-iris --model JSON --map --console
SITL terminal :
SIM_VEHICLE: Start
SIM_VEHICLE: Killing tasks
SIM_VEHICLE: Starting up at SITL location
SIM_VEHICLE: WAF build
SIM_VEHICLE: Configure waf
SIM_VEHICLE: "/home/fantasywilly/ardupilot/modules/waf/waf-light" "configure" "--board" "sitl"
Setting top to : /home/fantasywilly/ardupilot
Setting out to : /home/fantasywilly/ardupilot/build
Autoconfiguration : enabled
Setting board to : sitl
Using toolchain : native
Checking for 'g++' (C++ compiler) : /usr/lib/ccache/g++
Checking for 'gcc' (C compiler) : /usr/lib/ccache/gcc
Checking for c flags '-MMD' : yes
Checking for cxx flags '-MMD' : yes
Checking for need to link with librt : not necessary
Checking for feenableexcept : yes
Checking for HAVE_CMATH_ISFINITE : yes
Checking for HAVE_CMATH_ISINF : yes
Checking for HAVE_CMATH_ISNAN : yes
Checking for NEED_CMATH_ISFINITE_STD_NAMESPACE : yes
Checking for NEED_CMATH_ISINF_STD_NAMESPACE : yes
Checking for NEED_CMATH_ISNAN_STD_NAMESPACE : yes
Checking for header endian.h : yes
Checking for header byteswap.h : yes
Checking for HAVE_MEMRCHR : yes
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Source is git repository : yes
Update submodules : yes
Checking for program 'git' : /usr/bin/git
Checking for program 'size' : /usr/bin/size
Benchmarks : disabled
Unit tests : enabled
Scripting : enabled
Scripting runtime checks : enabled
Checking for program 'rsync' : /usr/bin/rsync
'configure' finished successfully (0.366s)
SIM_VEHICLE: Building
SIM_VEHICLE: "/home/fantasywilly/ardupilot/modules/waf/waf-light" "build" "--target" "bin/arducopter"
Waf: Entering directory /home/fantasywilly/ardupilot/build/sitl' Embedding file sandbox.lua:libraries/AP_Scripting/scripts/sandbox.lua Waf: Leaving directory
/home/fantasywilly/ardupilot/build/sitl'
bin/arducopter 2403210 102224 73344 2578778
Build commands will be stored in build/sitl/compile_commands.json 'build' finished successfully (0.436s) SIM_VEHICLE: Using defaults from (/home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm,/home/fantasywilly/ardupilot/Tools/autotest/default_params/gazebo-iris.parm) SIM_VEHICLE: Run ArduCopter SIM_VEHICLE: "/home/fantasywilly/ardupilot/Tools/autotest/run_in_terminal_window.sh" "ArduCopter" "/home/fantasywilly/ardupilot/build/sitl/bin/arducopter" "-S" "-I0" "--model" "JSON" "--speedup" "1" "--defaults" "/home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm,/home/fantasywilly/ardupilot/Tools/autotest/default_params/gazebo-iris.parm" SIM_VEHICLE: Run MavProxy SIM_VEHICLE: "mavproxy.py" "--master" "tcp:127.0.0.1:5760" "--sitl" "127.0.0.1:5501" "--out" "127.0.0.1:14550" "--out" "127.0.0.1:14551" "--map" "--console" RiTW: Starting ArduCopter : /home/fantasywilly/ardupilot/build/sitl/bin/arducopter -S -I0 --model JSON --speedup 1 --defaults /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm,/home/fantasywilly/ardupilot/Tools/autotest/default_params/gazebo-iris.parm Connect tcp:127.0.0.1:5760 source_system=255 [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping Failed to connect to tcp:127.0.0.1:5760 : [Errno 111] Connection refused SIM_VEHICLE: MAVProxy exited SIM_VEHICLE: Killing tasks
ArduCopter terminal :
I'm sorry for bothering you all the time. I'm not sure if this information meets your requirements.
I entered the following command : gz sim , and open a blank world.
Gazebo terminal :
Xlib: extension "NV-GLX" missing on display ":1". libEGL warning: DRI2: failed to create dri screen libEGL warning: DRI2: failed to create dri screen
I entered the following command : sim_vehicle.py
SITL terminal :
SIM_VEHICLE: Start
SIM_VEHICLE: Killing tasks
SIM_VEHICLE: Starting up at SITL location
SIM_VEHICLE: WAF build
SIM_VEHICLE: Configure waf
SIM_VEHICLE: "/home/fantasywilly/ardupilot/modules/waf/waf-light" "configure" "--board" "sitl"
Setting top to : /home/fantasywilly/ardupilot
Setting out to : /home/fantasywilly/ardupilot/build
Autoconfiguration : enabled
Setting board to : sitl
Using toolchain : native
Checking for 'g++' (C++ compiler) : /usr/lib/ccache/g++
Checking for 'gcc' (C compiler) : /usr/lib/ccache/gcc
Checking for c flags '-MMD' : yes
Checking for cxx flags '-MMD' : yes
Checking for need to link with librt : not necessary
Checking for feenableexcept : yes
Checking for HAVE_CMATH_ISFINITE : yes
Checking for HAVE_CMATH_ISINF : yes
Checking for HAVE_CMATH_ISNAN : yes
Checking for NEED_CMATH_ISFINITE_STD_NAMESPACE : yes
Checking for NEED_CMATH_ISINF_STD_NAMESPACE : yes
Checking for NEED_CMATH_ISNAN_STD_NAMESPACE : yes
Checking for header endian.h : yes
Checking for header byteswap.h : yes
Checking for HAVE_MEMRCHR : yes
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Source is git repository : yes
Update submodules : yes
Checking for program 'git' : /usr/bin/git
Checking for program 'size' : /usr/bin/size
Benchmarks : disabled
Unit tests : enabled
Scripting : enabled
Scripting runtime checks : enabled
Checking for program 'rsync' : /usr/bin/rsync
'configure' finished successfully (0.369s)
SIM_VEHICLE: Building
SIM_VEHICLE: "/home/fantasywilly/ardupilot/modules/waf/waf-light" "build" "--target" "bin/arducopter"
Waf: Entering directory /home/fantasywilly/ardupilot/build/sitl' Embedding file sandbox.lua:libraries/AP_Scripting/scripts/sandbox.lua Waf: Leaving directory
/home/fantasywilly/ardupilot/build/sitl'
bin/arducopter 2403210 102224 73344 2578778
Build commands will be stored in build/sitl/compile_commands.json 'build' finished successfully (0.440s) SIM_VEHICLE: Using defaults from (/home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm) SIM_VEHICLE: Run ArduCopter SIM_VEHICLE: "/home/fantasywilly/ardupilot/Tools/autotest/run_in_terminal_window.sh" "ArduCopter" "/home/fantasywilly/ardupilot/build/sitl/bin/arducopter" "-S" "-I0" "--model" "+" "--speedup" "1" "--defaults" "/home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm" SIM_VEHICLE: Run MavProxy SIM_VEHICLE: "mavproxy.py" "--master" "tcp:127.0.0.1:5760" "--sitl" "127.0.0.1:5501" "--out" "127.0.0.1:14550" "--out" "127.0.0.1:14551" RiTW: Starting ArduCopter : /home/fantasywilly/ardupilot/build/sitl/bin/arducopter -S -I0 --model + --speedup 1 --defaults /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm Connect tcp:127.0.0.1:5760 source_system=255 Log Directory: Telemetry log: mav.tlog Waiting for heartbeat from tcp:127.0.0.1:5760 MAV> AP: Calibrating barometer Detected vehicle 1:1 on link 0 online system 1 STABILIZE> Mode STABILIZE
ArduCopter terminal :
Set parameter SIM_SPEEDUP to 1.000000 Starting sketch 'ArduCopter' Starting SITL input Using Irlock at port : 9005 bind port 5760 for 0 Serial port 0 on TCP port 5760 Waiting for connection .... Connection on serial port 0 Loaded defaults from /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm Home: -35.363262 149.165237 alt=584.000000m hdg=353.000000 Smoothing reset at 0.001 bind port 5762 for 2 Serial port 2 on TCP port 5762 bind port 5763 for 3 Serial port 3 on TCP port 5763 validate_structures:411: Validating structures Loaded defaults from /home/fantasywilly/ardupilot/Tools/autotest/default_params/copter.parm
The ArduPilotPlugin
appears to be loading correctly, indicating the plugin search paths etc are set up correctly:
[Dbg] [SystemManager.cc:74] Loaded system [ArduPilotPlugin] for entity [15] [Dbg] [SystemManager.cc:74] Loaded system [ArduPilotPlugin] for entity [15]
It's not clear why SITL is not connecting to the simulation. The only thing I can think of is that there is a stray SITL or Gazebo process running that is blocking the port? Check that all gz
and ardupilot processes are killed and restart each of the processes in clean terminal.
Closing as no further activity.
I successfully opened Gazebo using the command "gz sim -v4 -r iris_runway.sdf". However, when I tried to open SITL by entering the command : "sim_vehicle.py -v ArduCopter -f gazebo-iris --model JSON --map --console", I encountered the following error:
Connect tcp:127.0.0.1:5760 source_system=255 [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping [Errno 111] Connection refused sleeping Failed to connect to tcp:127.0.0.1:5760 : [Errno 111] Connection refused SIM_VEHICLE: MAVProxy exited SIM_VEHICLE: Killing tasks