Skip to main content
GNSS Documentation
GitHub Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

Time Base

Configure the TIME HAT for improved time accuracy using Survey-In or Fixed Position mode.

Source: examples/CPP/TimeBase/, examples/C/TimeBase/, examples/Python/time_base.py

Note
HAT Compatibility — Time base is available only on the L1/L5 TIME HAT (NEO-F10T).

Survey-In Example

GnssConfig config {
    .measurementRate_Hz = 1,
    .dynamicModel = EDynamicModel::Stationary,
    .timepulsePinConfig = { .active = true, .fixedPulse = { 1, 0.1 },
        .pulseWhenNoFix = std::nullopt,
        .polarity = ETimepulsePinPolarity::RisingEdgeAtTopOfSecond },
    .geofencing = std::nullopt,
    .rtk = std::nullopt,
    .timing = TimingConfig {
        .enableTimeMark = false,
        .timeBase = BaseConfig {
            .mode = BaseConfig::SurveyIn {
                .minimumObservationTime_s = 120,
                .requiredPositionAccuracy_m = 50.0
            }
        }
    }
};
config = {
    'measurement_rate_hz': 1,
    'dynamic_model': gnsshat.DynamicModel.STATIONARY,
    'timepulse_pin_config': {
        'active': True,
        'fixed_pulse': {'frequency': 1, 'pulse_width': 0.1},
        'polarity': gnsshat.TimepulsePolarity.RISING_EDGE
    },
    'timing': {
        'enable_time_mark': False,
        'time_base': {
            'base_mode': gnsshat.BaseMode.SURVEY_IN,
            'survey_in': {
                'minimum_observation_time_s': 120,
                'required_position_accuracy_m': 50.0
            }
        }
    }
}

Running

python3 examples/Python/time_base.py

The fix type changes from 3D to TimeOnlyFix once Survey-In completes.