Ping Python Library: Ping1D get_distance() ping_number output

I am writing a python script to log data collected from a Ping2 Echosounder, but the script is sampling at a higher frequency than the echosounder, so many duplicates are present in the data. I thought the “ping_number” field of the get_distance() output dictionary would be the answer to my problem, but the field does not increment between new readings as I expected. Is there something I need to do to enable this functionality, or is it not implimented?

1 Like

Hi @MJS_FRF, welcome to the forum :slight_smile:

I’m currently travelling and don’t have access to my Ping Sonar, but I just replayed an old log file and the ping number does increase throughout the log.

When you say the field does not increment as you expected, are you saying it’s not incrementing at all, or that it’s incrementing in a different way to how you expected?

1 Like

Hi @EliotBR. The field does not increase at all, it remains at 0.

Hello again.
@EliotBR Were you able to confirm whether the ping number increments on your Ping sonar?

I finally got around to looking into this today, and it does seem like there’s some unexpected behaviour going on, which I’ve described in this issue.

I’ve asked internally whether there’s a reason for it, and if not hopefully we can release a new firmware version soon that fixes it, since at least conceptually it seems like it should be quite straightforward to implement as it’s described in the docs :slight_smile:

1 Like

Great to hear. Thank you Eliot.

1 Like

Hello again,
I have returned to working on this project and am wondering if there has been any progress on this issue. Re-running my python script with the latest version of the brping library, the behavior appears to be the same. Additionally, there seems to have been no activity on the github issue.