I’ve been creating a controller on Webots and wanted to use SITL and Mission Planner to help with the simulation.
I looked up the provided examples for SITL-Webots integration, and found that while the copter examples seem to function well, the rover example has difficulty getting to its goal. Rather than moving straight, it often turns too much and spins in circles. Sometimes it just stops moving, other times it moves in reverse.
I’ve followed the tutorial in https://ardupilot.org/dev/docs/sitl-with-webots.html
The exact steps I’ve followed were:
-Start up Webots, load ardupilot/libraries/SITL/examples/Webots/worlds/webots_rover.wbt
-Compile the controller and run the simulation
-Run SITL with the command: ./Tools/autotest/sim_vehicle.py -v Rover -w --model webots-rover --add-param-file=libraries/SITL/examples/Webots/rover.parm --map --console
-Set ARMING_CHECK to 0, as I was getting an error related to the compass
-Set mode to GUIDED
-Arm the throttle
-Create a waypoint directly in front of the rover
At this point, the rover behaves as previously described. It does, in fact, eventually reach the destination, but it uses pretty nonsensical paths to do so.
Is there anything I might be doing wrong? I haven’t found much info regarding rover simulation with SITL on Webots, so I’m not certain if this is an issue with my methodology, or the implementation of the integration.