NEO-M9N how to not get stale PVT data at 20hz

Hi, I’m using the U-blox GNSS library version 2.0.15 with the Artemis chip and am trying to avoid any stale PVT data when my navigation frequency is set to 20hz. Currently I get at least a couple stale lat/long points every second. Here is how I have it configured currently:

sensor->setUART1Output(0);
sensor->setUART2Output(0);
sensor->setUSBOutput(0);
sensor->setSPIOutput(0);
sensor->setI2COutput(COM_TYPE_UBX); //Set the I2C port to output UBX only (turn off NMEA noise)
sensor->setAutoPVT(true);/
sensor->setAutoDOP(false);
sensor->powerSaveMode(false);
sensor->saveConfiguration(); //Save to flash and BBR
sensor->setDynamicModel(DYN_MODEL_AUTOMOTIVE);
sensor->setNavigationFrequency(20);

Are there any other settings that could give me additional advantage? For my application I would prefer a consistent 20hz cadence over accuracy and a stale coordinate is less ideal. Is there a configuration I can use that would just give me the best it can come up with at 20hz always? Is there anything I can do for example with setMeasurementRate() to eliminate stale PVT readings at 20hz?

Thanks

Hi @ricozinn,

I would recommend using callbacks.

Have a look at this example for more information. With callbacks, you will get fresh data as soon as it arrives. No more stale data…

https://github.com/sparkfun/SparkFun_u- … AV_PVT.ino

You should be able to push the NEO-M9N to 25Hz if you need to.

Best wishes,

Paul

Thank you Paul! That does look promising. I’ve got it running, but it is hard to tell at my desk if the values are stale or not. We’ll field test soon.