Autonomous Bathymetry: Dynamic Path Generation and Object Avoidance

Hello everyone! I’ve been tasked with building an ASV for my school, to be used for bathymetry studies. It will replace an ASV that was built over a decade ago. I have a couple of questions related to the new system’s requirements, and I’m hoping to tap into the wealth of knowledge on this forum.

The old system required the operator to determine and upload path waypoints prior to launch using Mission Planner, and was prone to collisions. Ideally, the new system will be fully autonomous and require minimal operator input, if any at all. The ASV should traverse an entire body of water (or a geofenced area defined in Mission Planner) automatically such that the entire area is mapped and obstacles are automatically avoided. Then it should return to the launch site for retrieval.

First, using Mission Planner, is this behavior possible? In other words, could the ASV be instructed to automatically cover an entire body of water, using either the shoreline or a preset geofence as a boundary?

Second, what would be the best approach for avoiding obstacles both above and below the water line? We were thinking about using LiDAR above water and forward-facing SONAR below water. However, the SONAR seems like niche hardware that might be out of our budget.

If it’s relevant, we’re using a HEX Cube Orange for the build.

Thank you,

It is possible to retrieve a shoreline polygon from services like nominatim. And somehow use that as the boundary (not sure if any sohas that built in ability, but certainly doable). However, I find water bodies and the shoreline retrieved from vector maps are usually very inaccurate. Easy to see if you put a full fledged bathymetric map over, let’s say, Google Streets. Accurate maps are obviously the satellite raster type maps. To my best knowledge you cannot retrieve the shoreline from such a resource. If it is possible I would certainly be interested in how.
My experience with lidar on boats (to avoid running into an island) is also a mixed bag. The shore is not always a vertical wall that is easily measured. Not tested very much, though.
To have a forward facing echo sounder seems a good idea, probably someone here have tested use of sonar values for object avoidance. But you could probably get away using values from the sonar value you will anyway need to gather the bathymetric data. Stop before too late is not a bad idea. I ran a boat on top of a shallow area and parked the boat on top of a bed of small rocks this summer. Motors where partly lifted out of the water, it could not move anywhere. Had to find a boat and row out to retrieve it…

You can process data from a satellite tile set to get shoreline but it won’t account for minimum depth required and variability due to tides and other factors


I don’t think we have a ready-to-use way to just tell a board to autonomous map the lake that it is currently in although I created a similar to-do item here.

By the way, Peter Hall (aka “iampete1”) created a web application that creates ArduPilot compatible polygon fences for shorelines using Open Street Map data. The code is here although I think it would be difficult for anyone besides PeterH to get it working robustly.

Thank you all for your responses!

@oaamaas and @LupusTheCanine the idea behind the geofencing was not to provide a precise boundary, but rather to “lock” the boat into a general region and allow obstacle avoidance to prevent the boat from running aground. Basically, a failsafe that stops the boat from riding off into the sunset (never to be seen again) on very large bodies of water.

Also, we had hoped that the LiDAR would prevent collisions with obstacles like overhanging branches, low pedestrian bridges, etc. Detection of things like the shoreline, islands, and submerged rocks would ideally be handled by the forward SONAR.

@rmackay9 we’re actually using your Boogie Board Boat as the basis for our build! Thank you for sharing the to-do item; I’m sorry I missed it. This may be outside the scope of our project, but hypothetically would it possible for us to develop our own script or module to implement this functionality?

This wouldn’t solve the issue of “double obstacle avoidance” (combining above-water input with below-water input), but it would be a step in the right direction for us.

Peter Hall’s app does give me an idea that could serve as an alternative to trying to write our own mapping mode. I think it would be acceptable in terms of our outcomes if we could just automate the process of creating waypoints.

So maybe we could develop a tool that, given a geofence polygon, automatically generates mapping waypoints within that polygon. This wouldn’t solve the issue of shoreline “guestimation”, but we might be able to work with that.

Obstacle avoidance would still need to be considered, but automatic mission planning would satisfy one of our requirements.

You can use lua for basic avoidance, im just setting the vehicle to loiter if it gets too shallow, to stop it getting further into trouble but it wouldn’t take much to add more complex behaviour.
its a modification of the terrain avoidance script in the examples but using the downwards facing rangefinder rather than the terrain database.

You can use QGroundControl for polygon => path conversion.