85 [[nodiscard]] std::chrono::milliseconds
nextReadSlice(std::chrono::milliseconds timeout)
const override;
95 bool navigation =
false;
97 bool corrections =
false;
104 bool rtcmActivation =
false;
106 uint16_t disableMessage = 0;
110 enum class RTCMActivation : uint8_t
118 struct RateConfirmation
126 struct LegacyRTCMProgress
129 bool stationPosition =
false;
130 bool observations =
false;
136 void _setMode(
const Mode& mode, GPSStreamDemux& stream);
137 GPSReceiveUpdates _decode(uint16_t message, std::span<const uint8_t> payload, GPSDecodeContext& context);
139 bool _accept(uint16_t message, std::span<const uint8_t> payload);
140 void _decodeEpoch(uint16_t message, std::span<const uint8_t> payload, EpochAssembler::Epoch& epoch);
141 GPSReceiveUpdates _decodeHandled(uint16_t message, std::span<const uint8_t> payload, GPSDecodeContext& context);
142 GPSReceiveUpdates _decodeSurveyIn(std::span<const uint8_t> payload, GPSDecodeContext& context);
143 void _decodeMonVer(std::span<const uint8_t> payload);
144 void _decodeSatellites(uint16_t message, std::span<const uint8_t> payload);
148 [[nodiscard]]
bool _baseStationUnsupported()
const;
149 bool _identify(GPSCommandChannel& channel);
150 bool _setUpPort(GPSCommandChannel& channel,
unsigned detectedBaud,
unsigned desiredBaud);
151 bool _configureDevice(GPSCommandChannel& channel);
152 bool _configureJammingDetection(GPSCommandChannel& channel);
153 bool _configureLegacyDevice(GPSCommandChannel& channel);
154 bool _restartSurveyIn(GPSCommandChannel& channel);
155 bool _restartLegacySurveyIn(GPSCommandChannel& channel);
156 bool _disableTimeMode(GPSCommandChannel& channel);
157 bool _waitForSurveyStop(GPSCommandChannel& channel);
158 RTCMActivation _activateRTCMOutput(GPSCommandChannel& channel);
159 RTCMActivation _activateLegacyRTCMOutput(GPSCommandChannel& channel);
160 void _disableUnexpectedMessage(GPSCommandChannel& channel, uint16_t message);
163 bool _send(GPSCommandChannel& channel, MessageId message, std::span<const uint8_t> payload,
164 GPSConfigurationStep step);
165 bool _sendAcknowledged(GPSCommandChannel& channel, MessageId message, std::span<const uint8_t> payload);
166 GPSConfigurationEvidence _waitForAck(GPSCommandChannel& channel, MessageId message);
167 bool _setMessageRate(GPSCommandChannel& channel, Plan::MessageRate rate);
168 bool _setMessageRateAcknowledged(GPSCommandChannel& channel, Plan::MessageRate rate);
169 GPSCommandOutcome _setMessageRateReply(GPSCommandChannel& channel, Plan::MessageRate rate);
173 RateConfirmation _confirmMessageRate(GPSCommandChannel& channel, Plan::MessageRate rate);
174 bool _runPlan(GPSCommandChannel& channel,
const std::vector<Plan::ValsetBatch>& batches);
176 [[nodiscard]]
bool _valsetsRefused()
const;
177 void _load(
const Plan::ValsetBatch& batch);
178 bool _writeValset(GPSCommandChannel& channel,
const Plan::ValsetBatch& batch);
179 GPSConfigurationEvidence _transactValset(GPSCommandChannel& channel,
const Plan::ValsetBatch& batch);
181 GPSConfigurationEvidence _awaitValsetAck(GPSCommandChannel& channel);
183 GPSConfigurationEvidence _verifyValset(GPSCommandChannel& channel, GPSConfigurationStep step);
186 Identity _identity{};
187 ReceiverController _controller{};
189 Requests _requests{};
191 bool _timeModeReadbackPending =
false;
192 std::optional<uint8_t> _timeModeReadback = std::nullopt;
194 bool _surveyStopped =
false;
197 bool _secSigSeen =
false;
200 EpochAssembler _epochs;
201 GPSDecodedSatellites _satellites;
202 GPSIntegrityReport _integrity;
204 bool _epochStarted =
false;
206 QString _lastWarning;
207 uint64_t _lastWarningUs = 0;
210 GPSBaseStationConfig _base;
211 CheckedValsetBatch<Plan::VALSET_CAPACITY> _valset;
214 bool _valsetAckAmbiguous =
false;
215 LegacyRTCMProgress _legacyRTCM;
216 uint64_t _lastDisableUs = 0;