Ping360 how to detect walls

Hey, I’m receiving data from the Ping360 and putting it into a 2D array. I was wondering if anyone would know how to approach using this data to detect where a wall is?

Hi @purplegator, welcome to the forum! :slight_smile:

Viable approaches to this likely depend on the technology stack you have available. As a starting point, you may wish to consider line/arc segment finders and/or simple blob detection algorithms using a library like OpenCV.

In terms of implementation it’s likely simplest if you can find an algorithm that’s not constrained to finding flat walls (so you don’t need to straighten out / render the radial data), but if you’re able to do that kind of pre-processing then it may make the wall-finding aspect easier

Note that if you’re in a confined area (like a swimming pool), you may get ghost walls from multi-bounced echos between sets of walls, so if you’re trying to do analysis or obstacle avoidance or similar then you may need to filter things down to just the initial significant response at any given angle.

@EliotBR The Ping1D sonar comes with an excellent built-in signal processing method that reports the exact range. In my testing, I was able to confirm that it’s accurate to within 3 cm of the true distance

I understand the sonar firmware isn’t open source, but would it be possible to get any guidance on how one might implement a similar method for the Ping360? I know there’s an open-source version of the Ping1D firmware, but I’m wondering if this kind of processing could also be done on the topside using data from ping-python.

There’s some discussion in this post that may be of interest, but I suppose the most obvious factor to consider is response intensity peaks (which can be found using common peak finding algorithms).

The Ping Sonar has some extra coherence filtering by just smoothing results over time, but that doesn’t necessarily work well for a scanning sonar like the Ping360 because the angle changes. That said, you could still do some coherence detection by finding multiple subsequent peaks in a similar region across profiles, and if you’re able to track the vehicle’s location then you could also have spatial correlation of objects each time the sonar passes over the same region.

Yes, although it may not be feasible in real-time, depending on the data rate in question, and desired accuracy.

Gotcha, thanks for the quick response, @EliotBR ^-^