Auto Survey Command code

34 views
Skip to first unread message

Lukas Ohlendorf

unread,
Oct 10, 2018, 12:56:40 PM10/10/18
to swiftnav-discuss
Hello,
as part of an academic project we are using a piksi evaluation kit to get detect the exact position of a rc modelship.
Therefore we have to implement a micro controller to the board which has to run the "auto survey" command automatically by pressing a button. To accomplish this, we need to get the right 
code to execute the "auto survey" on a arduino micro controller. We already tried to find the right line of code out of the protocol.

Thanks in advance

Dennis Zollo

unread,
Oct 11, 2018, 12:29:45 PM10/11/18
to swiftnav-discuss
Lukas,

There is no "Auto Survey" command for Piksi v2.3.1 or Piksi multi.  For Piksi Multi, we recommend using our Rinex converter and a 3rd party service per this article: https://support.swiftnav.com/customer/en/portal/articles/2804367-sbp-to-rinex-converter-and-data-post-processing in order to determine the location of the base station in the reference frame you require for position.

In our console software, we have the simple implementation of averaging the last 1000 position solutions and sending the MSG_SETTINGS_WRITE (id 160 or hex 0x00A0) over the SBP protocol in order to set all of the settings in the "surveyed_position" grouping.  You can read more about the "surveyed_position" settings in the settings documents we publish on this page (https://support.swiftnav.com/customer/en/portal/articles/2628580-piksi-multi-specifications).  The settings_write message use null terminations in their payload to encode the group, name, and value of settings as strings.  For example, the following value of the "setting" field in the message will set the surveyed latitude on the wire, where the \0 character represents the null character in an ascii style string.

"surveyed_position\0surveyed_lat\037.1233445\0"

On Piksi Multi, you will receive a MSG_SETTINGS_WRITE_RESP (id 175 or hex 0x00AF) after confirming that your write was successful.

For your application, you could take a similar approach as the console with your micro controller and average some set of positions.  If you would like the surveyed position to persist in memory after power cycle, send the "settings_save" message (id 161 or hex 0x00A1) after setting and confirming the value of the surveyed position.  Note, rover positioning will be repeatable and precise with this method, but the accuracy with respect to some global reference frame will be limited by the accuracy for which you were able to determine the position of the base station.

Best,
Dennis
Reply all
Reply to author
Forward
0 new messages