To initialize the global egomotion module, certain configuration parameters can be set, for example the position of the GNSS antenna in the rig coordinate system. Other parameters include noise and drift characteristics, or the size of the internal history storing state estimates. A typical initialization code sequence will look like this:
At run-time the global egomotion filter has to be filled with measurements from the GNSS sensor, as well as motion estimates from a relative egomotion module. The following example assumes that such a relative egomotion module with handle relativeEgomotion
has been initialized and is being updated elsewhere; see Relative Egomotion Workflow for more details.
Before using any state estimates, always verify their validity by inspecting the return codes of the various APIs as well as the flags contained within the state and uncertainty structures.
This workflow is demonstrated in the following sample: Egomotion Sample