le_gnss_interface.h

Go to the documentation of this file.
1 
2 
3 /*
4  * ====================== WARNING ======================
5  *
6  * THE CONTENTS OF THIS FILE HAVE BEEN AUTO-GENERATED.
7  * DO NOT MODIFY IN ANY WAY.
8  *
9  * ====================== WARNING ======================
10  */
11 
12 /**
13  * @page c_gnss GNSS
14  *
15  * @ref le_gnss_interface.h "API Reference" <br>
16  * @ref platformConstraintsGnss <br>
17  * @ref howToGNSS "How To Use GNSS" <br>
18  * @ref toolsTarget_gnss "GNSS target tool" <br>
19  *
20  * <HR>
21  *
22  * This API provides access to the GNSS device.
23  *
24  * GNSS or Global Navigation Satellite System is a satellite navigation system with global coverage.
25  *
26  * This API provides function to configure the GNSS device and retrieve position information.
27  *
28  * @section le_gnss_binding IPC interfaces binding
29  *
30  * All the functions of this API are provided by the @b positioningService application service.
31  *
32  * Here's a code sample binding to Positioning services:
33  * @verbatim
34  bindings:
35  {
36  clientExe.clientComponent.le_gnss -> positioningService.le_gnss
37  }
38  @endverbatim
39  *
40  * @section le_gnss_ControlApi GNSS Control API
41  *
42  * @subsection le_gnss_EnableDisable Enable/Disable GNSS device
43  *
44  * The application can enable/disable the GNSS device with the le_gnss_Enable()
45  * / le_gnss_Disable() functions.
46  * By default the GNSS device is enabled for the positioningService application service.
47  * Also see @ref howToGNSS.
48  *
49  * A sample code can be seen in the following page:
50  * - @subpage c_gnssSampleCodeEnableDisable
51  *
52  * @subsection le_gnss_StartStop Start/Stop GNSS device
53  *
54  * The application can start/stop the GNSS device with the le_gnss_Start() / le_gnss_Stop()
55  * functions.
56  * The default "HOT" start condition is applied and all assistance data are used.
57  * Also see @ref howToGNSS.
58  *
59  * A sample code can be seen in the following page:
60  * - @subpage c_gnssSampleCodeStartStop
61  *
62  * @subsubsection le_gnss_StartingMode Starting mode
63  *
64  * Starting modes are used only for test purposes and allow start performance measurement.
65  * @note For more information about start performances, please refer to your specific
66  * platform documentation.
67  *
68  * @subsubsection SettingConfiguration Setting configuration
69  *
70  * @warning The GNSS setting configuration depends on the platform. Please refer to
71  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
72  *
73  * @subsubsection le_gnss_Data GNSS data
74  * The following table describes the <b>minimum</b> required data for those starting modes:
75  *
76  * | GNSS Data / Starting mode | HOT | WARM | COLD | FACTORY |
77  *| -----------------------| -----| ------| ----- | ------- |
78  *| Broadcasted Ephemeris | Used | | | |
79  *| Extended Ephemeris | Used(1) | Used(2) | Used(2) | Removed (3) |
80  *| Approximate Time and Position | Used | Used | | |
81  *| Almanac | Used | Used | Used | Used (Factory) |
82  *
83  * For example, a requested HOT start without valid broadcasted ephemeris will be treated
84  * as a WARM start.
85  *
86  * @note (1) Extended Ephemeris can be used if Broadcasted Ephemeris are not valid.
87  * The Extended Ephemeris could be loaded using the le_gnss_LoadExtendedEphemerisFile()
88  * function.
89  * @note (2) Extended Ephemeris is used if the Extended Ephemeris file is loaded and valid.
90  * @note (3) Extended Ephemeris are removed when a FACTORY start is requested.
91  * The Extended Ephemeris could be loaded again using the le_gnss_LoadExtendedEphemerisFile()
92  * function.
93  *
94  * @subsubsection le_gnss_TTFF Time To First Fix (TTFF)
95  * The le_gnss_GetTtff() function provides the TTFF (first between 2-Dimensional or 3-Dimensional
96  * position fix) of the last position fix.
97  * Please refer to @ref le_gnss_APIcallsRequirements. Also see @ref howToGNSS.
98  *
99  * A sample code can be seen in the following page:
100  * - @subpage c_gnssSampleCodeReStart
101  *
102  * @subsubsection le_gnss_InjectUtcTime Inject UTC time
103  * The le_gnss_InjectUtcTime() function injects the UTC time into the location engine. Providing an
104  * accurate UTC time reduces the time to find the first fix.
105  *
106  * @subsubsection le_gnss_ForceHotRestart Force HOT restart
107  * The le_gnss_ForceHotRestart() function performs a "HOT" restart of the GNSS device. The current
108  * GNSS session is stopped, then started using the available @ref le_gnss_Data.
109  * Please refer to @ref le_gnss_APIcallsRequirements. Also see @ref howToGNSS.
110  *
111  * @subsubsection le_gnss_ForceWarmRestart Force WARM restart
112  * The le_gnss_ForceWarmRestart() function performs a "WARM" restart of the GNSS device. The current
113  * GNSS session is stopped, then started using the available @ref le_gnss_Data.
114  * Please refer to @ref le_gnss_APIcallsRequirements. Also see @ref howToGNSS.
115  *
116  * @subsubsection le_gnss_ForceColdRestart Force COLD restart
117  * The le_gnss_ForceColdRestart() function performs a "COLD" restart of the GNSS device. The current
118  * GNSS session is stopped, then started using the available @ref le_gnss_Data.
119  * Please refer to @ref le_gnss_APIcallsRequirements. Also see @ref howToGNSS.
120  *
121  * @subsubsection le_gnss_ForceFactoryRestart Force FACTORY restart
122  * The le_gnss_ForceFactoryRestart() function performs a "FACTORY" restart of the GNSS device.
123  * The current GNSS session is stopped, then started using the available @ref le_gnss_Data.
124  * Please refer to @ref le_gnss_APIcallsRequirements. Also see @ref howToGNSS.
125  *
126  * @subsection le_gnss_AcquisitionRate Acquisition rate
127  * The GNSS position is computed and delivered each acquisition rate. The acquisition rate defines
128  * the time interval that must elapse between two final GPS positions calculation and reports.
129  * Its default value is 1 second.
130  * The application can configure/retreive the GNSS device acquisition rate with the
131  * le_gnss_SetAcquisitionRate() / le_gnss_GetAcquisitionRate() functions.
132  *
133  * Please refer to @ref le_gnss_APIcallsRequirements.
134  *
135  * A sample code can be seen in the following page:
136  * - @subpage c_gnssSampleCodeAcquisitionRate
137  *
138  * @subsection le_gnss_SetGetConstellation GNSS constellation selection
139  *
140  * The le_gnss_SetConstellation() function selects the GNSS constellation(s) used in solution.
141  * If all GNSS constellations are disabled, the GNSS engine is disabled.
142  *
143  * @warning Your GNSS device may require a restart to take into account this change.
144  * Please refer to your platform documentation @ref platformConstraintsGnss_SettingConfiguration for
145  * further details.
146  *
147  * Combinations of constellation for GPS, GLONASS, BDS, GALILEO and QZSS satellites are currently
148  * supported. Constellation for SBAS satellites is not supported.
149  *
150  * All supported GNSS constellations are enabled by default.
151  * The le_gnss_GetConstellation() function gets the GNSS constellation(s) enabled to be used
152  * in solution.
153  *
154  * A sample code can be seen in the following page:
155  * - @subpage c_gnssSampleCodeConstellation
156  *
157  * @subsection le_gnss_SetGetMinElevation GNSS minimum elevation selection
158  *
159  * The le_gnss_SetMinElevation() function sets the GNSS minimum elevation.
160  * Satellites with elevation lower than the minimum elevation will be ignored.
161  *
162  * The le_gnss_GetMinElevation() function gets the GNSS minimum elevation.
163  *
164  * A sample code can be seen in the following page:
165  * - @subpage c_gnssSampleCodeMinElevation
166  *
167  * @subsection le_gnss_NmeaSentences NMEA sentences selection
168  *
169  * The le_gnss_SetNmeaSentences() function selects the enabled NMEA sentences in the
170  * @ref le_gnss_NMEA with a bit mask. The supported values are listed in @ref le_gnss_NmeaBitMask_t.
171  *
172  * @warning Your GNSS device may require a restart to take into account this change.
173  * Please refer to your platform documentation @ref platformConstraintsGnss_SettingConfiguration for
174  * further details.
175  *
176  * @note All supported NMEA sentences are enabled by default.
177  *
178  * The le_gnss_GetNmeaSentences() function gets the bit mask of the enabled NMEA sentences in the
179  * @ref le_gnss_NMEA.
180  *
181  * Please refer to @ref le_gnss_APIcallsRequirements.
182  *
183  * A sample code can be seen in the following page:
184  * - @subpage c_gnssSampleCodeNmeaSentences
185  *
186  * @subsection le_gnss_APIcallsRequirements API calls Requirements
187  * The following table shows the pre-requisites when using the GNSS service API function set.
188  * ''LE_OK or error code'' means the function is authorized in the corresponding state, the request
189  * is performed and the result is returned; otherwise the returned error is indicated for each state
190  *.
191  * | Function / GNSS state | UNINITIALIZED | READY | ACTIVE | DISABLED |
192  *| ----------------------------- | --------------------------- | -----------------------------| --------------------------- | --------------------------- |
193  *| le_gnss_Start() | LE_NOT_PERMITTED | LE_OK or error code | LE_DUPLICATE | LE_NOT_PERMITTED |
194  *| le_gnss_Stop() | LE_NOT_PERMITTED | LE_DUPLICATE | LE_OK or error code | LE_NOT_PERMITTED |
195  *| le_gnss_ForceHotRestart() | LE_NOT_PERMITTED | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED |
196  *| le_gnss_ForceWarmRestart() | LE_NOT_PERMITTED | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED |
197  *| le_gnss_ForceColdRestart() | LE_NOT_PERMITTED | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED |
198  *| le_gnss_ForceFactoryRestart() | LE_NOT_PERMITTED | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED |
199  *| le_gnss_Disable() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_DUPLICATE |
200  *| le_gnss_Enable() | LE_NOT_PERMITTED | LE_DUPLICATE | LE_DUPLICATE | LE_OK or error code |
201  *| le_gnss_SetConstellation() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
202  *| le_gnss_GetConstellation() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
203  *| le_gnss_GetTtff() | LE_NOT_PERMITTED | LE_OK or error code | LE_OK or error code | LE_NOT_PERMITTED |
204  *| le_gnss_SetAcquisitionRate() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
205  *| le_gnss_GetAcquisitionRate() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
206  *| le_gnss_SetNmeaSentences() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
207  *| le_gnss_GetNmeaSentences() | LE_NOT_PERMITTED | LE_OK or error code | LE_NOT_PERMITTED | LE_NOT_PERMITTED |
208  *
209  * Also see @ref howToGNSS.
210  *
211  * @section le_gnss_Information GNSS position information
212  * @ref le_gnss_NMEA
213  *
214  * @ref le_gnss_GetInfo
215  *
216  * @subsection le_gnss_NMEA NMEA Flow
217  * The National Marine Electronics Association (NMEA) standard defines an electrical interface
218  * and data protocol for communications between marine instrumentation.
219  *
220  * The NMEA-0183, scope of this document, defines a set of frame prefixed by
221  * $GP (concerning Global Positioning System),
222  * $GL (concerning GLONASS)
223  * and $GN (concerning combination of navigation systems).
224  * For more details about NMEA standards, please refer to http://www.nmea.org/.
225  *
226  * That NMEA frames flow can be retrieved from the "/dev/nmea" device folder, using for example
227  * the shell command $<EM> cat /dev/nmea | grep '$G'</EM>
228  *
229  * @subsection le_gnss_GetInfo Get position information
230  * The position information is referenced to a position sample object.
231  *
232  * An application can register a handler to be notified of the
233  * updated position each @ref le_gnss_AcquisitionRate, returning a position sample object.
234  *
235  * The GNSS information commonly used such as
236  * device state, position, time and date, satellites information and accuracy
237  * can be queried using the following functions:
238  * - le_gnss_GetState()
239  * - le_gnss_GetPositionState()
240  * - le_gnss_GetLocation()
241  * - le_gnss_GetAltitude()
242  * - le_gnss_GetDate()
243  * - le_gnss_GetTime()
244  * - le_gnss_GetGpsTime()
245  * - le_gnss_GetGpsLeapSeconds()
246  * - le_gnss_GetEpochTime()
247  * - le_gnss_GetTimeAccuracy()
248  * - le_gnss_GetHorizontalSpeed()
249  * - le_gnss_GetVerticalSpeed()
250  * - le_gnss_GetDirection()
251  * - le_gnss_GetSatellitesInfo()
252  * - le_gnss_GetSbasConstellationCategory()
253  * - le_gnss_GetSatellitesStatus()
254  * - le_gnss_GetDop()
255  * - le_gnss_GetAltitudeOnWgs84()
256  * - le_gnss_GetMagneticDeviation()
257  *
258  * The handler can be managed using le_gnss_AddPositionHandler()
259  * and le_gnss_RemovePositionHandler().
260  * When a position is computed, the handler is called.
261  *
262  * The application has to release each position sample object received by the handler,
263  * using the le_gnss_ReleaseSampleRef().
264  *
265  * A sample code can be seen in the following page:
266  * - @subpage c_gnssSampleCodePosition
267  *
268  * @section le_gnss_Assisted_GNSS Assisted GNSS
269  *
270  * @ref le_gnss_Assisted_GNSS_EE
271  * @ref le_gnss_Assisted_GNSS_UP
272  *
273  * @subsection le_gnss_Assisted_GNSS_EE Server based Extended Ephemeris
274  *
275  * @todo Add detailed documentation.
276  *
277  * With le_gnss_LoadExtendedEphemerisFile() , you can load an 'Extended Ephemeris' file into
278  * the GNSS device from the filesystem.
279  * You have to download the file before loading it.
280  * @warning Ensure to check that the downloaded file is supported for your specific platform.
281  *
282  * With le_gnss_GetExtendedEphemerisValidity(), you will to get the validity of the last injected
283  * Extended Ephemeris.
284  *
285  * You can enable/disable the use of the 'Extended Ephemeris' file into the GNSS device with
286  * le_gnss_EnableExtendedEphemerisFile() / le_gnss_DisableExtendedEphemerisFile() functions.
287  * @warning Ensure to check configuration capabilities for your specific platform.
288  * A reboot must be required if your platform doesn't allow run-time configuration.
289  *
290  * A sample code can be seen in the following page:
291  * - @subpage c_gnssSampleCodeXtra
292  *
293  * @subsection le_gnss_Assisted_GNSS_UP 3GPP User Plane (OMA SUPL)
294  *
295  * That 3GPP User Plane A-GNSS (Assisted GNSS) protocol is defined by two different standardization
296  * bodies, 3GPP and Open Mobile Alliance (OMA). For more information, please refer to the standard.
297  *
298  * Both MS-Assisted and MS-Based position determination methods are supported in the User Plane.
299  *
300  * In MS-Assisted mode, the MS (Mobile Station) measures the signals from the GNSS satellites
301  *, then returns the retrieved GNSS data to the SUPL (Secure User Plan Location) server, where the
302  * position calculation is performed.
303  *
304  * In MS-Based mode, the MS gets the assistance data from the SUPL (Secure User Plan Location)
305  * server. The MS measures the signals from the GNSS satellites and makes the position calculation.
306  *
307  * The data transport over User Plan is done using the TCP/IP protocol.
308  *
309  * The Assisted-GNSS mode can be configured thru the le_gnss_SetSuplAssistedMode() function.
310  *
311  * The supported modes are the following:
312  * - Standalone mode: That 3GPP User Plane A-GNSS feature is deactivated.
313  * - MS-Based mode
314  * - MS-Assisted mode
315  *
316  * Moreover, the le_gnss_GetSuplAssistedMode() function reads the configured Assisted-GNSS mode.
317  *
318  * The SUPL server is configured using the le_gnss_SetSuplServerUrl() function. That function sets
319  * the SUPL server URL and optionally the port number.
320  *
321  * The SUPL certificate to be used in A-GNSS sessions is injected through the
322  * le_gnss_InjectSuplCertificate() function and deleted through the le_gnss_DeleteSuplCertificate()
323  * function.
324  * The SUPL certificate lenght given as parameter to le_gnss_InjectSuplCertificate() must be less
325  * than LE_GNSS_SUPL_CERTIFICATE_MAX_LEN.
326  *
327  * <HR>
328  *
329  * Copyright (C) Sierra Wireless Inc.
330  */
331 /**
332  * @page c_gnssSampleCode Sample code for GNSS device
333  *
334  * @include "apps/test/positioning/gnssTest/gnssTest/gnssTest.c"
335  */
336 /**
337  * @page c_gnssSampleCodeEnableDisable Sample code for Enable/Disable GNSS device
338  *
339  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssEnable
340  */
341 /**
342  * @page c_gnssSampleCodeStartStop Sample code for Start/Stop GNSS device
343  *
344  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssControl
345  */
346 /**
347  * @page c_gnssSampleCodeReStart Sample code for restart GNSS device and get TTFF
348  *
349  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssReStart
350  */
351 /**
352  * @page c_gnssSampleCodeAcquisitionRate Sample code for GNSS acquisition rate configuration
353  *
354  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssControl
355  */
356 /**
357  * @page c_gnssSampleCodeConstellation Sample code for GNSS constellation selection
358  *
359  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssControl
360  */
361 /**
362  * @page c_gnssSampleCodeMinElevation Sample code for GNSS minimum elevation
363  *
364  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssControl
365  */
366 /**
367  * @page c_gnssSampleCodeNmeaSentences Sample code for GNSS NMEA sentences selection
368  *
369  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssControl
370  */
371 /**
372  * @page c_gnssSampleCodePosition Sample code for GNSS position information
373  *
374  * @snippet "apps/test/positioning/gnssTest/gnssTest/gnssTest.c" GnssPosition
375  */
376 /**
377  * @page c_gnssSampleCodeXtra Sample code for GNSS Server based Extended Ephemeris
378  *
379  * @include "apps/test/positioning/gnssXtraTest/gnssXtraTest/xtraTest.c"
380  */
381 /**
382  * @file le_gnss_interface.h
383  *
384  * Legato @ref c_gnss include file.
385  *
386  * Copyright (C) Sierra Wireless Inc.
387  */
388 
389 #ifndef LE_GNSS_INTERFACE_H_INCLUDE_GUARD
390 #define LE_GNSS_INTERFACE_H_INCLUDE_GUARD
391 
392 
393 #include "legato.h"
394 
395 
396 //--------------------------------------------------------------------------------------------------
397 /**
398  * Type for handler called when a server disconnects.
399  */
400 //--------------------------------------------------------------------------------------------------
401 typedef void (*le_gnss_DisconnectHandler_t)(void *);
402 
403 //--------------------------------------------------------------------------------------------------
404 /**
405  *
406  * Connect the current client thread to the service providing this API. Block until the service is
407  * available.
408  *
409  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
410  * called before any other functions in this API. Normally, ConnectService is automatically called
411  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
412  *
413  * This function is created automatically.
414  */
415 //--------------------------------------------------------------------------------------------------
417 (
418  void
419 );
420 
421 //--------------------------------------------------------------------------------------------------
422 /**
423  *
424  * Try to connect the current client thread to the service providing this API. Return with an error
425  * if the service is not available.
426  *
427  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
428  * called before any other functions in this API. Normally, ConnectService is automatically called
429  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
430  *
431  * This function is created automatically.
432  *
433  * @return
434  * - LE_OK if the client connected successfully to the service.
435  * - LE_UNAVAILABLE if the server is not currently offering the service to which the client is
436  * bound.
437  * - LE_NOT_PERMITTED if the client interface is not bound to any service (doesn't have a binding).
438  * - LE_COMM_ERROR if the Service Directory cannot be reached.
439  */
440 //--------------------------------------------------------------------------------------------------
442 (
443  void
444 );
445 
446 //--------------------------------------------------------------------------------------------------
447 /**
448  * Set handler called when server disconnection is detected.
449  *
450  * When a server connection is lost, call this handler then exit with LE_FATAL. If a program wants
451  * to continue without exiting, it should call longjmp() from inside the handler.
452  */
453 //--------------------------------------------------------------------------------------------------
455 (
456  le_gnss_DisconnectHandler_t disconnectHandler,
457  void *contextPtr
458 );
459 
460 //--------------------------------------------------------------------------------------------------
461 /**
462  *
463  * Disconnect the current client thread from the service providing this API.
464  *
465  * Normally, this function doesn't need to be called. After this function is called, there's no
466  * longer a connection to the service, and the functions in this API can't be used. For details, see
467  * @ref apiFilesC_client.
468  *
469  * This function is created automatically.
470  */
471 //--------------------------------------------------------------------------------------------------
473 (
474  void
475 );
476 
477 
478 //--------------------------------------------------------------------------------------------------
479 /**
480  * Maximum length of the SUP Server URL string.
481  */
482 //--------------------------------------------------------------------------------------------------
483 #define LE_GNSS_SUPL_SERVER_URL_MAX_LEN 256
484 
485 //--------------------------------------------------------------------------------------------------
486 /**
487  * Maximum length of the SUP Server URL string.
488  * One extra byte is added for the null character.
489  */
490 //--------------------------------------------------------------------------------------------------
491 #define LE_GNSS_SUPL_SERVER_URL_MAX_BYTES 257
492 
493 //--------------------------------------------------------------------------------------------------
494 /**
495  * Maximum SUPL certificate size.
496  */
497 //--------------------------------------------------------------------------------------------------
498 #define LE_GNSS_SUPL_CERTIFICATE_MAX_LEN 2000
499 
500 //--------------------------------------------------------------------------------------------------
501 /**
502  * Maximum SUPL certificate string size.
503  * One extra byte is added for the null character.
504  */
505 //--------------------------------------------------------------------------------------------------
506 #define LE_GNSS_SUPL_CERTIFICATE_MAX_BYTES 2001
507 
508 //--------------------------------------------------------------------------------------------------
509 /**
510  * Define the maximum length of the Satellites Vehicle information list
511  */
512 //--------------------------------------------------------------------------------------------------
513 #define LE_GNSS_SV_INFO_MAX_LEN 80
514 
515 //--------------------------------------------------------------------------------------------------
516 /**
517  * Define the maximal bit mask for enabled NMEA sentences
518  *
519  * @note This maximal value should be coherent with @ref le_gnss_NmeaBitMask_t
520  */
521 //--------------------------------------------------------------------------------------------------
522 #define LE_GNSS_NMEA_SENTENCES_MAX 32767
523 
524 //--------------------------------------------------------------------------------------------------
525 /**
526  * Define the maximal degree for the minimal elevation
527  */
528 //--------------------------------------------------------------------------------------------------
529 #define LE_GNSS_MIN_ELEVATION_MAX_DEGREE 90
530 
531 //--------------------------------------------------------------------------------------------------
532 /**
533  * Reference type for dealing with GNSS position samples.
534  */
535 //--------------------------------------------------------------------------------------------------
536 typedef struct le_gnss_Sample* le_gnss_SampleRef_t;
537 
538 
539 //--------------------------------------------------------------------------------------------------
540 /**
541  * Enumeration for GNSS device state
542  */
543 //--------------------------------------------------------------------------------------------------
544 typedef enum
545 {
547  ///< The GNSS device is not initialized
549  ///< The GNSS device is ready
551  ///< The GNSS device is active
553  ///< The GNSS device is disabled
555  ///< Do not use
556 }
558 
559 
560 //--------------------------------------------------------------------------------------------------
561 /**
562  * GNSS fix position states.
563  */
564 //--------------------------------------------------------------------------------------------------
565 typedef enum
566 {
568  ///< The GNSS fix position is not fixed.
570  ///< 2-Dimensional position fix.
572  ///< 3-Dimensional position fix.
574  ///< Estimated (i.e. forward predicted) position fix.
575 }
577 
578 
579 //--------------------------------------------------------------------------------------------------
580 /**
581  * SBAS constellation category
582  */
583 //--------------------------------------------------------------------------------------------------
584 typedef enum
585 {
587  ///< Satellite Vehicle of Satellite-based augmentation system
588  ///< (SBAS) EGNOS constellation.
590  ///< Satellite Vehicle of Satellite-based augmentation system
591  ///< (SBAS) WAAS constellation.
593  ///< Satellite Vehicle of Satellite-based augmentation system
594  ///< (SBAS) GAGAN constellation.
596  ///< Satellite Vehicle of Satellite-based augmentation system
597  ///< (SBAS) MSAS constellation.
599  ///< Satellite Vehicle of Satellite-based augmentation system
600  ///< (SBAS) unknown constellation.
601 }
603 
604 
605 //--------------------------------------------------------------------------------------------------
606 /**
607  * GNSS constellation type.
608  */
609 //--------------------------------------------------------------------------------------------------
610 typedef enum
611 {
613  ///< GNSS constellation field not defined.
615  ///< Satellite Vehicle of GPS constellation.
616  ///< North American satellite navigation system
618  ///< Satellite Vehicle of SBAS constellation.
619  ///< Satellite-based augmentation system
621  ///< Satellite Vehicle of Glonass constellation.
622  ///< Russian satellite navigation system
624  ///< Satellite Vehicle of Galileo constellation.
625  ///< European Union satellite navigation system
627  ///< Satellite Vehicle of Beidou constellation.
628  ///< Chinese satellite navigation system
630  ///< Satellite Vehicle of QZSS constellation.
631  ///< Japanese satellite navigation system
633  ///< Maximum value.
634 }
636 
637 
638 //--------------------------------------------------------------------------------------------------
639 /**
640  * Assisted-GNSS mode
641  */
642 //--------------------------------------------------------------------------------------------------
643 typedef enum
644 {
646  ///< Standalone mode
648  ///< MS-Based mode.
650  ///< MS-Assisted mode.
651 }
653 
654 
655 //--------------------------------------------------------------------------------------------------
656 /**
657  * GNSS constellation Bit Mask (8 bits) indicating the GNSS constellation(s)
658  * used in solution.
659  *
660  */
661 //--------------------------------------------------------------------------------------------------
662 typedef enum
663 {
664  LE_GNSS_CONSTELLATION_GPS = 0x1, ///< GPS constellation used in solution.
665  ///< North American satellite navigation system
666  LE_GNSS_CONSTELLATION_GLONASS = 0x2, ///< GLONASS constellation used in solution.
667  ///< Russian satellite navigation system
668  LE_GNSS_CONSTELLATION_BEIDOU = 0x4, ///< BEIDOU constellation used in solution.
669  ///< Chinese satellite navigation system
670  LE_GNSS_CONSTELLATION_GALILEO = 0x8, ///< GALILEO constellation used in solution.
671  ///< European Union satellite navigation system
672  LE_GNSS_CONSTELLATION_SBAS = 0x10, ///< SBAS constellation used in solution.
673  LE_GNSS_CONSTELLATION_QZSS = 0x20 ///< QZSS constellation used in solution.
674  ///< Japanese satellite navigation system
675 }
677 
678 
679 //--------------------------------------------------------------------------------------------------
680 /**
681  * NMEA sentences Bit Mask indicating the NMEA sentences enabled in the NMEA flow.
682  *
683  * @warning The supported NMEA sentences depend on the platform. Please refer to your platform
684  * documentation for further details.
685  *
686  * @note The bit mask values should be coherent with @ref LE_GNSS_NMEA_SENTENCES_MAX
687  */
688 //--------------------------------------------------------------------------------------------------
689 typedef enum
690 {
691  LE_GNSS_NMEA_MASK_GPGGA = 0x1, ///< GPGGA type enabled: GPS fix data.
692  LE_GNSS_NMEA_MASK_GPGSA = 0x2, ///< GPGSA type enabled: GPS DOP and active satellites.
693  LE_GNSS_NMEA_MASK_GPGSV = 0x4, ///< GPGSV type enabled: GPS satellites in view.
694  LE_GNSS_NMEA_MASK_GPRMC = 0x8, ///< GPRMC type enabled: GPS recommended minimum data.
695  LE_GNSS_NMEA_MASK_GPVTG = 0x10, ///< GPVTG type enabled: GPS vector track and speed over the ground.
696  LE_GNSS_NMEA_MASK_GLGSV = 0x20, ///< GLGSV type enabled: GLONASS satellites in view.
697  LE_GNSS_NMEA_MASK_GNGNS = 0x40, ///< GNGNS type enabled: GNSS fix data.
698  LE_GNSS_NMEA_MASK_GNGSA = 0x80, ///< GNGSA type enabled: GNSS DOP and active satellites.
699  LE_GNSS_NMEA_MASK_GAGGA = 0x100, ///< GAGGA type enabled: Galileo fix data.
700  LE_GNSS_NMEA_MASK_GAGSA = 0x200, ///< GAGSA type enabled: Galileo DOP and active satellites.
701  LE_GNSS_NMEA_MASK_GAGSV = 0x400, ///< GAGSV type enabled: Galileo satellites in view.
702  LE_GNSS_NMEA_MASK_GARMC = 0x800, ///< GARMC type enabled: Galileo recommended minimum data.
703  LE_GNSS_NMEA_MASK_GAVTG = 0x1000, ///< GAVTG type enabled: Galileo vector track and speed over the ground.
704  LE_GNSS_NMEA_MASK_PSTIS = 0x2000, ///< PSTIS type enabled: GPS session start indication.
705  LE_GNSS_NMEA_MASK_PQXFI = 0x4000 ///< PQXFI type enabled: Proprietary Qualcomm eXtended Fix Information.
706 }
708 
709 
710 //--------------------------------------------------------------------------------------------------
711 /**
712  * Reference type used by Add/Remove functions for EVENT 'le_gnss_Position'
713  */
714 //--------------------------------------------------------------------------------------------------
715 typedef struct le_gnss_PositionHandler* le_gnss_PositionHandlerRef_t;
716 
717 
718 //--------------------------------------------------------------------------------------------------
719 /**
720  * Handler for position information.
721  *
722  */
723 //--------------------------------------------------------------------------------------------------
724 typedef void (*le_gnss_PositionHandlerFunc_t)
725 (
726  le_gnss_SampleRef_t positionSampleRef,
727  ///< Position's sample reference
728  void* contextPtr
729  ///<
730 );
731 
732 //--------------------------------------------------------------------------------------------------
733 /**
734  * Set the GNSS constellation bit mask
735  *
736  * @return
737  * - LE_FAULT The function failed.
738  * - LE_UNSUPPORTED If the request is not supported.
739  * - LE_NOT_PERMITTED If the GNSS device is not initialized, disabled or active.
740  * - LE_OK The function succeeded.
741  *
742  * @warning The settings are platform dependent. Please refer to
743  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
744  */
745 //--------------------------------------------------------------------------------------------------
747 (
748  le_gnss_ConstellationBitMask_t constellationMask
749  ///< [IN] GNSS constellation used in solution.
750 );
751 
752 //--------------------------------------------------------------------------------------------------
753 /**
754  * Get the GNSS constellation bit mask
755  *
756  * @return
757  * - LE_OK on success
758  * - LE_FAULT on failure
759  */
760 //--------------------------------------------------------------------------------------------------
762 (
763  le_gnss_ConstellationBitMask_t* constellationMaskPtr
764  ///< [OUT] GNSS constellation used in solution.
765 );
766 
767 //--------------------------------------------------------------------------------------------------
768 /**
769  * This function enables the use of the 'Extended Ephemeris' file into the GNSS device.
770  *
771  * @return
772  * - LE_FAULT The function failed.
773  * - LE_OK The function succeeded.
774  *
775  * @warning The settings are platform dependent. Please refer to
776  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
777  */
778 //--------------------------------------------------------------------------------------------------
780 (
781  void
782 );
783 
784 //--------------------------------------------------------------------------------------------------
785 /**
786  * This function disables the use of the 'Extended Ephemeris' file into the GNSS device.
787  *
788  * @return
789  * - LE_FAULT The function failed.
790  * - LE_OK The function succeeded.
791  *
792  * @warning The settings are platform dependent. Please refer to
793  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
794  */
795 //--------------------------------------------------------------------------------------------------
797 (
798  void
799 );
800 
801 //--------------------------------------------------------------------------------------------------
802 /**
803  * This function must be called to load an 'Extended Ephemeris' file into the GNSS device.
804  *
805  * @return
806  * - LE_FAULT The function failed to inject the 'Extended Ephemeris' file.
807  * - LE_TIMEOUT A time-out occurred.
808  * - LE_FORMAT_ERROR 'Extended Ephemeris' file format error.
809  * - LE_OK The function succeeded.
810  *
811  */
812 //--------------------------------------------------------------------------------------------------
814 (
815  int fd
816  ///< [IN] Extended ephemeris file descriptor
817 );
818 
819 //--------------------------------------------------------------------------------------------------
820 /**
821  * This function must be called to get the validity of the last injected Extended Ephemeris.
822  *
823  * @return
824  * - LE_FAULT The function failed to get the validity
825  * - LE_OK The function succeeded.
826  *
827  */
828 //--------------------------------------------------------------------------------------------------
830 (
831  uint64_t* startTimePtr,
832  ///< [OUT] Start time in seconds (since Jan. 1, 1970)
833  uint64_t* stopTimePtr
834  ///< [OUT] Stop time in seconds (since Jan. 1, 1970)
835 );
836 
837 //--------------------------------------------------------------------------------------------------
838 /**
839  * This function must be called to inject the UTC time into the GNSS device.
840  *
841  * @return
842  * - LE_OK The function succeeded.
843  * - LE_FAULT The function failed to inject the UTC time.
844  * - LE_TIMEOUT A time-out occurred.
845  *
846  */
847 //--------------------------------------------------------------------------------------------------
849 (
850  uint64_t timeUtc,
851  ///< [IN] [IN] UTC time since Jan. 1, 1970 in milliseconds
852  uint32_t timeUnc
853  ///< [IN] [IN] Time uncertainty in milliseconds
854 );
855 
856 //--------------------------------------------------------------------------------------------------
857 /**
858  * This function starts the GNSS device.
859  *
860  * @return
861  * - LE_FAULT The function failed.
862  * - LE_DUPLICATE If the GNSS device is already started.
863  * - LE_NOT_PERMITTED If the GNSS device is not initialized or disabled.
864  * - LE_OK The function succeeded.
865  *
866  */
867 //--------------------------------------------------------------------------------------------------
869 (
870  void
871 );
872 
873 //--------------------------------------------------------------------------------------------------
874 /**
875  * This function stops the GNSS device.
876  *
877  * @return
878  * - LE_FAULT The function failed.
879  * - LE_DUPLICATE If the GNSS device is already stopped.
880  * - LE_NOT_PERMITTED If the GNSS device is not initialized or disabled.
881  * - LE_OK The function succeeded.
882  *
883  */
884 //--------------------------------------------------------------------------------------------------
886 (
887  void
888 );
889 
890 //--------------------------------------------------------------------------------------------------
891 /**
892  * This function performs a "HOT" restart of the GNSS device.
893  *
894  * @return
895  * - LE_FAULT The function failed.
896  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
897  * - LE_OK The function succeeded.
898  *
899  */
900 //--------------------------------------------------------------------------------------------------
902 (
903  void
904 );
905 
906 //--------------------------------------------------------------------------------------------------
907 /**
908  * This function performs a "WARM" restart of the GNSS device.
909  *
910  * @return
911  * - LE_FAULT The function failed.
912  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
913  * - LE_OK The function succeeded.
914  *
915  */
916 //--------------------------------------------------------------------------------------------------
918 (
919  void
920 );
921 
922 //--------------------------------------------------------------------------------------------------
923 /**
924  * This function performs a "COLD" restart of the GNSS device.
925  *
926  * @return
927  * - LE_FAULT The function failed.
928  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
929  * - LE_OK The function succeeded.
930  *
931  */
932 //--------------------------------------------------------------------------------------------------
934 (
935  void
936 );
937 
938 //--------------------------------------------------------------------------------------------------
939 /**
940  * This function performs a "FACTORY" restart of the GNSS device.
941  *
942  * @return
943  * - LE_FAULT The function failed.
944  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
945  * - LE_OK The function succeeded.
946  *
947  */
948 //--------------------------------------------------------------------------------------------------
950 (
951  void
952 );
953 
954 //--------------------------------------------------------------------------------------------------
955 /**
956  * Get the TTFF in milliseconds
957  *
958  * @return
959  * - LE_BUSY The position is not fixed and TTFF can't be measured.
960  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
961  * - LE_OK Function succeeded.
962  *
963  */
964 //--------------------------------------------------------------------------------------------------
966 (
967  uint32_t* ttffPtr
968  ///< [OUT] TTFF in milliseconds
969 );
970 
971 //--------------------------------------------------------------------------------------------------
972 /**
973  * This function enables the GNSS device.
974  *
975  * @return
976  * - LE_FAULT The function failed.
977  * - LE_DUPLICATE If the GNSS device is already enabled.
978  * - LE_NOT_PERMITTED If the GNSS device is not initialized.
979  * - LE_OK The function succeeded.
980  *
981  * @warning The settings are platform dependent. Please refer to
982  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
983  */
984 //--------------------------------------------------------------------------------------------------
986 (
987  void
988 );
989 
990 //--------------------------------------------------------------------------------------------------
991 /**
992  * This function disables the GNSS device.
993  *
994  * @return
995  * - LE_FAULT The function failed.
996  * - LE_DUPLICATE If the GNSS device is already disabled.
997  * - LE_NOT_PERMITTED If the GNSS device is not initialized or started.
998  * - LE_OK The function succeeded.
999  *
1000  * @warning The settings are platform dependent. Please refer to
1001  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1002  */
1003 //--------------------------------------------------------------------------------------------------
1005 (
1006  void
1007 );
1008 
1009 //--------------------------------------------------------------------------------------------------
1010 /**
1011  * This function sets the GNSS device acquisition rate.
1012  *
1013  * @return
1014  * - LE_OK on success
1015  * - LE_FAULT on failure
1016  * - LE_UNSUPPORTED request not supported
1017  * - LE_TIMEOUT a time-out occurred
1018  * - LE_NOT_PERMITTED If the GNSS device is not in "ready" state.
1019  * - LE_OUT_OF_RANGE if acquisition rate value is equal to zero
1020  *
1021  * @warning This function may be subject to limitations depending on the platform. Please refer to
1022  * the @ref platformConstraintsGnss page.
1023  *
1024  * @warning The settings are platform dependent. Please refer to
1025  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1026  */
1027 //--------------------------------------------------------------------------------------------------
1029 (
1030  uint32_t rate
1031  ///< [IN] Acquisition rate in milliseconds.
1032 );
1033 
1034 //--------------------------------------------------------------------------------------------------
1035 /**
1036  * This function gets the GNSS device acquisition rate.
1037  *
1038  * @return
1039  * - LE_OK on success
1040  * - LE_FAULT on failure
1041  * - LE_NOT_PERMITTED If the GNSS device is not in "ready" state.
1042  */
1043 //--------------------------------------------------------------------------------------------------
1045 (
1046  uint32_t* ratePtr
1047  ///< [OUT] Acquisition rate in milliseconds.
1048 );
1049 
1050 //--------------------------------------------------------------------------------------------------
1051 /**
1052  * Add handler function for EVENT 'le_gnss_Position'
1053  *
1054  * This event provides information on position.
1055  *
1056  * - A handler reference, which is only needed for later removal of the handler.
1057  *
1058  * @note Doesn't return on failure, so there's no need to check the return value for errors.
1059  */
1060 //--------------------------------------------------------------------------------------------------
1062 (
1063  le_gnss_PositionHandlerFunc_t handlerPtr,
1064  ///< [IN]
1065  void* contextPtr
1066  ///< [IN]
1067 );
1068 
1069 //--------------------------------------------------------------------------------------------------
1070 /**
1071  * Remove handler function for EVENT 'le_gnss_Position'
1072  */
1073 //--------------------------------------------------------------------------------------------------
1075 (
1076  le_gnss_PositionHandlerRef_t handlerRef
1077  ///< [IN]
1078 );
1079 
1080 //--------------------------------------------------------------------------------------------------
1081 /**
1082  * This function gets the position sample's fix state
1083  *
1084  * - LE_OK on success
1085  * - LE_FAULT on failure
1086  *
1087  * @note If the caller is passing an invalid Position sample reference into this function,
1088  * it is a fatal error, the function will not return.
1089  */
1090 //--------------------------------------------------------------------------------------------------
1092 (
1093  le_gnss_SampleRef_t positionSampleRef,
1094  ///< [IN] Position sample's reference.
1095  le_gnss_FixState_t* statePtr
1096  ///< [OUT] Position fix state.
1097 );
1098 
1099 //--------------------------------------------------------------------------------------------------
1100 /**
1101  * Get the location's data (Latitude, Longitude, Horizontal accuracy).
1102  *
1103  * @return
1104  * - LE_FAULT Function failed to get the location's data
1105  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to INT32_MAX).
1106  * - LE_OK Function succeeded.
1107  *
1108  * @note latitudePtr, longitudePtr, hAccuracyPtr, altitudePtr, vAccuracyPtr can be set to NULL
1109  * if not needed.
1110  *
1111  * @note: The latitude and longitude values are based on the WGS84 standard coordinate system.
1112  *
1113  * @note The latitude and longitude are given in degrees with 6 decimal places like:
1114  * Latitude +48858300 = 48.858300 degrees North
1115  * Longitude +2294400 = 2.294400 degrees East
1116  *
1117  * @note If the caller is passing an invalid Position sample reference into this function,
1118  * it is a fatal error, the function will not return.
1119  */
1120 //--------------------------------------------------------------------------------------------------
1122 (
1123  le_gnss_SampleRef_t positionSampleRef,
1124  ///< [IN] Position sample's reference.
1125  int32_t* latitudePtr,
1126  ///< [OUT] WGS84 Latitude in degrees, positive North [resolution 1e-6].
1127  int32_t* longitudePtr,
1128  ///< [OUT] WGS84 Longitude in degrees, positive East [resolution 1e-6].
1129  int32_t* hAccuracyPtr
1130  ///< [OUT] Horizontal position's accuracy in meters [resolution 1e-2].
1131 );
1132 
1133 //--------------------------------------------------------------------------------------------------
1134 /**
1135  * Get the position sample's altitude.
1136  *
1137  * @return
1138  * - LE_FAULT Function failed to get the altitude. Invalid Position reference provided.
1139  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to INT32_MAX).
1140  * - LE_OK Function succeeded.
1141  *
1142  * @note Altitude is in meters, above Mean Sea Level, with 3 decimal places (3047 = 3.047 meters).
1143  *
1144  * @note For a 2D position fix, the altitude will be indicated as invalid and set to INT32_MAX
1145  *
1146  * @note If the caller is passing an invalid Position reference into this function,
1147  * it is a fatal error, the function will not return.
1148  *
1149  * @note altitudePtr, altitudeAccuracyPtr can be set to NULL if not needed.
1150  */
1151 //--------------------------------------------------------------------------------------------------
1153 (
1154  le_gnss_SampleRef_t positionSampleRef,
1155  ///< [IN] Position sample's reference.
1156  int32_t* altitudePtr,
1157  ///< [OUT] Altitude in meters, above Mean Sea Level [resolution 1e-3].
1158  int32_t* vAccuracyPtr
1159  ///< [OUT] Vertical position's accuracy in meters [resolution 1e-1].
1160 );
1161 
1162 //--------------------------------------------------------------------------------------------------
1163 /**
1164  * Get the position sample's time.
1165  *
1166  * @return
1167  * - LE_FAULT Function failed to get the time.
1168  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1169  * - LE_OK Function succeeded.
1170  *
1171  * @note If the caller is passing an invalid Position sample reference into this function,
1172  * it is a fatal error, the function will not return.
1173  */
1174 //--------------------------------------------------------------------------------------------------
1176 (
1177  le_gnss_SampleRef_t positionSampleRef,
1178  ///< [IN] Position sample's reference.
1179  uint16_t* hoursPtr,
1180  ///< [OUT] UTC Hours into the day [range 0..23].
1181  uint16_t* minutesPtr,
1182  ///< [OUT] UTC Minutes into the hour [range 0..59].
1183  uint16_t* secondsPtr,
1184  ///< [OUT] UTC Seconds into the minute [range 0..59].
1185  uint16_t* millisecondsPtr
1186  ///< [OUT] UTC Milliseconds into the second [range 0..999].
1187 );
1188 
1189 //--------------------------------------------------------------------------------------------------
1190 /**
1191  * Get the position sample's GPS time.
1192  *
1193  * @return
1194  * - LE_FAULT Function failed to get the time.
1195  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1196  * - LE_OK Function succeeded.
1197  *
1198  * @note If the caller is passing an invalid Position sample reference into this function,
1199  * it is a fatal error, the function will not return.
1200  */
1201 //--------------------------------------------------------------------------------------------------
1203 (
1204  le_gnss_SampleRef_t positionSampleRef,
1205  ///< [IN] Position sample's reference.
1206  uint32_t* gpsWeekPtr,
1207  ///< [OUT] GPS week number from midnight, Jan. 6, 1980.
1208  uint32_t* gpsTimeOfWeekPtr
1209  ///< [OUT] Amount of time in milliseconds into the GPS week.
1210 );
1211 
1212 //--------------------------------------------------------------------------------------------------
1213 /**
1214  * Get the position sample's epoch time.
1215  *
1216  * @return
1217  * - LE_FAULT Function failed to acquire the epoch time.
1218  * - LE_OK Function succeeded.
1219  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1220  *
1221  * @note The epoch time is the number of seconds elapsed since January 1, 1970
1222  * (midnight UTC/GMT), not counting leaps seconds.
1223  *
1224  * @note If the caller is passing an invalid position sample reference into this function,
1225  * it is a fatal error, the function will not return.
1226  */
1227 //--------------------------------------------------------------------------------------------------
1229 (
1230  le_gnss_SampleRef_t positionSampleRef,
1231  ///< [IN] Position sample's reference.
1232  uint64_t* millisecondsPtr
1233  ///< [OUT] Milliseconds since Jan. 1, 1970.
1234 );
1235 
1236 //--------------------------------------------------------------------------------------------------
1237 /**
1238  * Get the position sample's time accurary.
1239  *
1240  * @return
1241  * - LE_FAULT Function failed to get the time.
1242  * - LE_OUT_OF_RANGE The retrieved time accuracy is invalid (set to UINT16_MAX).
1243  * - LE_OK Function succeeded.
1244  *
1245  * @note If the caller is passing an invalid Position sample reference into this function,
1246  * it is a fatal error, the function will not return.
1247  */
1248 //--------------------------------------------------------------------------------------------------
1250 (
1251  le_gnss_SampleRef_t positionSampleRef,
1252  ///< [IN] Position sample's reference.
1253  uint32_t* timeAccuracyPtr
1254  ///< [OUT] Estimated time accuracy in milliseconds
1255 );
1256 
1257 //--------------------------------------------------------------------------------------------------
1258 /**
1259  * Get the position sample's UTC leap seconds in advance
1260  *
1261  * @return
1262  * - LE_FAULT Function failed to get the leap seconds.
1263  * - LE_OUT_OF_RANGE The retrieved time accuracy is invalid (set to UINT8_MAX).
1264  * - LE_OK Function succeeded.
1265  *
1266  * @note The leap seconds in advance is the accumulated time in seconds since the start of GPS Epoch
1267  * time (Jan 6, 1980). This value has to be added to the UTC time (since Jan. 1, 1970)
1268  *
1269  * @note Insertion of each UTC leap second is usually decided about six months in advance by the
1270  * International Earth Rotation and Reference Systems Service (IERS).
1271  *
1272  * @note If the caller is passing an invalid position sample reference or a null pointer into this
1273  * function, it is a fatal error, the function will not return.
1274  */
1275 //--------------------------------------------------------------------------------------------------
1277 (
1278  le_gnss_SampleRef_t positionSampleRef,
1279  ///< [IN] Position sample's reference.
1280  uint8_t* leapSecondsPtr
1281  ///< [OUT] UTC leap seconds in advance in seconds
1282 );
1283 
1284 //--------------------------------------------------------------------------------------------------
1285 /**
1286  * Get the position sample's date.
1287  *
1288  * @return
1289  * - LE_FAULT Function failed to get the date.
1290  * - LE_OUT_OF_RANGE The retrieved date is invalid (all fields are set to 0).
1291  * - LE_OK Function succeeded.
1292  *
1293  * @note If the caller is passing an invalid Position sample reference into this function,
1294  * it is a fatal error, the function will not return.
1295  */
1296 //--------------------------------------------------------------------------------------------------
1298 (
1299  le_gnss_SampleRef_t positionSampleRef,
1300  ///< [IN] Position sample's reference.
1301  uint16_t* yearPtr,
1302  ///< [OUT] UTC Year A.D. [e.g. 2014].
1303  uint16_t* monthPtr,
1304  ///< [OUT] UTC Month into the year [range 1...12].
1305  uint16_t* dayPtr
1306  ///< [OUT] UTC Days into the month [range 1...31].
1307 );
1308 
1309 //--------------------------------------------------------------------------------------------------
1310 /**
1311  * Get the position sample's horizontal speed.
1312  *
1313  * - LE_FAULT Function failed to find the positionSample.
1314  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to UINT32_MAX).
1315  * - LE_OK Function succeeded.
1316  *
1317  * @note hSpeedPtr, hSpeedAccuracyPtr can be set to NULL if not needed.
1318  *
1319  * @note If the caller is passing an invalid Position sample reference into this function,
1320  * it is a fatal error, the function will not return.
1321  */
1322 //--------------------------------------------------------------------------------------------------
1324 (
1325  le_gnss_SampleRef_t positionSampleRef,
1326  ///< [IN] Position sample's reference.
1327  uint32_t* hspeedPtr,
1328  ///< [OUT] Horizontal speed in meters/second [resolution 1e-2].
1329  uint32_t* hspeedAccuracyPtr
1330  ///< [OUT] Horizontal speed's accuracy estimate
1331  ///< in meters/second [resolution 1e-1].
1332 );
1333 
1334 //--------------------------------------------------------------------------------------------------
1335 /**
1336  * Get the position sample's vertical speed.
1337  *
1338  * @return
1339  * - LE_FAULT The function failed to find the positionSample.
1340  * - LE_OUT_OF_RANGE One of the retrieved parameter is not valid (set to INT32_MAX).
1341  * - LE_OK The function succeeded.
1342  *
1343  * @note vSpeedPtr, vSpeedAccuracyPtr can be set to NULL if not needed.
1344  *
1345  * @note For a 2D position Fix, the vertical speed will be indicated as invalid
1346  * and set to INT32_MAX.
1347  *
1348  * @note If the caller is passing an invalid Position sample reference into this function,
1349  * it is a fatal error, the function will not return.
1350  */
1351 //--------------------------------------------------------------------------------------------------
1353 (
1354  le_gnss_SampleRef_t positionSampleRef,
1355  ///< [IN] Position sample's reference.
1356  int32_t* vspeedPtr,
1357  ///< [OUT] Vertical speed in meters/second [resolution 1e-2],
1358  ///< positive up.
1359  int32_t* vspeedAccuracyPtr
1360  ///< [OUT] Vertical speed's accuracy estimate
1361  ///< in meters/second [resolution 1e-1].
1362 );
1363 
1364 //--------------------------------------------------------------------------------------------------
1365 /**
1366  * Get the position sample's direction. Direction of movement is the direction that the vehicle or
1367  * person is actually moving.
1368  *
1369  * @return
1370  * - LE_FAULT Function failed to find the positionSample.
1371  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to UINT32_MAX).
1372  * - LE_OK Function succeeded.
1373  *
1374  * @note Direction is given in degrees with 1 decimal place: 1755 = 175,5 degrees.
1375  * Direction ranges from 0 to 359.9 degrees, where 0 is True North.
1376  *
1377  * @note directionPtr, directionAccuracyPtr can be set to NULL if not needed.
1378  *
1379  * @note If the caller is passing an invalid Position sample reference into this function,
1380  * it is a fatal error, the function will not return.
1381  */
1382 //--------------------------------------------------------------------------------------------------
1384 (
1385  le_gnss_SampleRef_t positionSampleRef,
1386  ///< [IN] Position sample's reference.
1387  uint32_t* directionPtr,
1388  ///< [OUT] Direction in degrees [resolution 1e-1].
1389  ///< Range: 0 to 359.9, where 0 is True North
1390  uint32_t* directionAccuracyPtr
1391  ///< [OUT] Direction's accuracy estimate
1392  ///< in degrees [resolution 1e-1].
1393 );
1394 
1395 //--------------------------------------------------------------------------------------------------
1396 /**
1397  * Get the Satellites Vehicle information.
1398  *
1399  * @return
1400  * - LE_FAULT Function failed to find the positionSample.
1401  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid.
1402  * - LE_OK Function succeeded.
1403  *
1404  * @note satId[] can be set to 0 if that information list index is not configured, so
1405  * all satellite parameters (satConst[], satSnr[],satAzim[], satElev[]) are fixed to 0.
1406  *
1407  * @note For LE_OUT_OF_RANGE returned code, invalid value depends on field type:
1408  * UINT16_MAX for satId, LE_GNSS_SV_CONSTELLATION_UNDEFINED for satConst, false for satUsed,
1409  * UINT8_MAX for satSnr, UINT16_MAX for satAzim, UINT8_MAX for satElev.
1410  *
1411  * @note If the caller is passing an invalid Position sample reference into this function,
1412  * it is a fatal error, the function will not return.
1413  */
1414 //--------------------------------------------------------------------------------------------------
1416 (
1417  le_gnss_SampleRef_t positionSampleRef,
1418  ///< [IN] Position sample's reference.
1419  uint16_t* satIdPtr,
1420  ///< [OUT] Satellites in View ID number, referring
1421  ///< to NMEA standard.
1422  size_t* satIdSizePtr,
1423  ///< [INOUT]
1424  le_gnss_Constellation_t* satConstPtr,
1425  ///< [OUT] GNSS constellation type.
1426  size_t* satConstSizePtr,
1427  ///< [INOUT]
1428  bool* satUsedPtr,
1429  ///< [OUT] TRUE if satellite in View Used
1430  ///< for Navigation.
1431  size_t* satUsedSizePtr,
1432  ///< [INOUT]
1433  uint8_t* satSnrPtr,
1434  ///< [OUT] Satellites in View Signal To
1435  ///< Noise Ratio [dBHz].
1436  size_t* satSnrSizePtr,
1437  ///< [INOUT]
1438  uint16_t* satAzimPtr,
1439  ///< [OUT] Satellites in View Azimuth [degrees].
1440  ///< Range: 0 to 360
1441  ///< If Azimuth angle is currently unknown,
1442  ///< the value is set to UINT16_MAX.
1443  size_t* satAzimSizePtr,
1444  ///< [INOUT]
1445  uint8_t* satElevPtr,
1446  ///< [OUT] Satellites in View Elevation [degrees].
1447  ///< Range: 0 to 90
1448  ///< If Elevation angle is currently unknown,
1449  ///< the value is set to UINT8_MAX.
1450  size_t* satElevSizePtr
1451  ///< [INOUT]
1452 );
1453 
1454 //--------------------------------------------------------------------------------------------------
1455 /**
1456  * Get the SBAS constellation category
1457  *
1458  */
1459 //--------------------------------------------------------------------------------------------------
1461 (
1462  uint16_t satId
1463  ///< [IN] Satellites in View ID number, referring
1464  ///< to NMEA standard.
1465 );
1466 
1467 //--------------------------------------------------------------------------------------------------
1468 /**
1469  * Get the Satellites Vehicle status.
1470  *
1471  * @return
1472  * - LE_FAULT Function failed to find the positionSample.
1473  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid.
1474  * - LE_OK Function succeeded.
1475  *
1476  * @note If the caller is passing an invalid Position sample reference into this function,
1477  * it is a fatal error, the function will not return.
1478  */
1479 //--------------------------------------------------------------------------------------------------
1481 (
1482  le_gnss_SampleRef_t positionSampleRef,
1483  ///< [IN] Position sample's reference.
1484  uint8_t* satsInViewCountPtr,
1485  ///< [OUT] Number of satellites expected to be in view.
1486  uint8_t* satsTrackingCountPtr,
1487  ///< [OUT] Number of satellites in view, when tracking.
1488  uint8_t* satsUsedCountPtr
1489  ///< [OUT] Number of satellites in view used for Navigation.
1490 );
1491 
1492 //--------------------------------------------------------------------------------------------------
1493 /**
1494  * Get the DOP parameters (Dilution Of Precision) for the fixed position.
1495  *
1496  * @return
1497  * - LE_FAULT Function failed to find the positionSample.
1498  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to INT16_MAX).
1499  * - LE_OK Function succeeded.
1500  *
1501  * @note The DOP values are given with 3 decimal places like: DOP value 2200 = 2.200
1502  *
1503  * @note If the caller is passing an invalid Position sample reference into this function,
1504  * it is a fatal error, the function will not return.
1505  */
1506 //--------------------------------------------------------------------------------------------------
1508 (
1509  le_gnss_SampleRef_t positionSampleRef,
1510  ///< [IN] Position sample's reference.
1511  uint16_t* hdopPtr,
1512  ///< [OUT] Horizontal Dilution of Precision [resolution 1e-3].
1513  uint16_t* vdopPtr,
1514  ///< [OUT] Vertical Dilution of Precision [resolution 1e-3].
1515  uint16_t* pdopPtr
1516  ///< [OUT] Position Dilution of Precision [resolution 1e-3].
1517 );
1518 
1519 //--------------------------------------------------------------------------------------------------
1520 /**
1521  * Get the position sample's altitude with respect to the WGS-84 ellipsoid
1522  *
1523  * @return
1524  * - LE_FAULT Function failed to get the altitude.
1525  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to INT32_MAX).
1526  * - LE_OK Function succeeded.
1527  *
1528  * @note altitudeOnWgs84 is in meters, between WGS-84 earth ellipsoid and mean sea level
1529  * with 3 decimal places (3047 = 3.047 meters).
1530  *
1531  * @note For a 2D position fix, the altitude with respect to the WGS-84 ellipsoid will be indicated
1532  * as invalid and set to INT32_MAX.
1533  *
1534  * @note If the caller is passing an invalid Position reference into this function,
1535  * it is a fatal error, the function will not return.
1536  */
1537 //--------------------------------------------------------------------------------------------------
1539 (
1540  le_gnss_SampleRef_t positionSampleRef,
1541  ///< [IN] Position sample's reference.
1542  int32_t* altitudeOnWgs84Ptr
1543  ///< [OUT] Altitude in meters, between WGS-84 earth ellipsoid
1544  ///< and mean sea level [resolution 1e-3].
1545 );
1546 
1547 //--------------------------------------------------------------------------------------------------
1548 /**
1549  * Get the position sample's magnetic deviation. It is the difference between the bearing to
1550  * true north and the bearing shown on a magnetic compass. The deviation is positive when the
1551  * magnetic north is east of true north.
1552  *
1553  * @return
1554  * - LE_FAULT Function failed to find the positionSample.
1555  * - LE_OUT_OF_RANGE One of the retrieved parameter is invalid (set to INT32_MAX).
1556  * - LE_OK Function succeeded.
1557  *
1558  * @note magneticDeviation is in degrees, with 1 decimal places (47 = 4.7 degree).
1559  *
1560  * @note If the caller is passing an invalid Position sample reference into this function,
1561  * it is a fatal error, the function will not return.
1562  */
1563 //--------------------------------------------------------------------------------------------------
1565 (
1566  le_gnss_SampleRef_t positionSampleRef,
1567  ///< [IN] Position sample's reference.
1568  int32_t* magneticDeviationPtr
1569  ///< [OUT] MagneticDeviation in degrees [resolution 1e-1].
1570 );
1571 
1572 //--------------------------------------------------------------------------------------------------
1573 /**
1574  * This function gets the last updated position sample object reference.
1575  *
1576  * @return A reference to last Position's sample.
1577  *
1578  * @note
1579  * On failure, the process exits, so you don't have to worry about checking the returned
1580  * reference for validity.
1581  */
1582 //--------------------------------------------------------------------------------------------------
1584 (
1585  void
1586 );
1587 
1588 //--------------------------------------------------------------------------------------------------
1589 /**
1590  * This function must be called to release the position sample.
1591  *
1592  * @note If the caller is passing an invalid Position sample reference into this function,
1593  * it is a fatal error, the function will not return.
1594  */
1595 //--------------------------------------------------------------------------------------------------
1597 (
1598  le_gnss_SampleRef_t positionSampleRef
1599  ///< [IN] Position sample's reference.
1600 );
1601 
1602 //--------------------------------------------------------------------------------------------------
1603 /**
1604  * This function sets the SUPL Assisted-GNSS mode.
1605  *
1606  * @return
1607  * - LE_OK on success
1608  * - LE_FAULT on failure
1609  * - LE_UNSUPPORTED request not supported
1610  * - LE_TIMEOUT a time-out occurred
1611  *
1612  * @warning The settings are platform dependent. Please refer to
1613  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1614  */
1615 //--------------------------------------------------------------------------------------------------
1617 (
1618  le_gnss_AssistedMode_t assistedMode
1619  ///< [IN] Assisted-GNSS mode.
1620 );
1621 
1622 //--------------------------------------------------------------------------------------------------
1623 /**
1624  * This function gets the SUPL Assisted-GNSS mode.
1625  *
1626  * @return
1627  * - LE_OK on success
1628  * - LE_FAULT on failure
1629  */
1630 //--------------------------------------------------------------------------------------------------
1632 (
1633  le_gnss_AssistedMode_t* assistedModePtr
1634  ///< [OUT] Assisted-GNSS mode.
1635 );
1636 
1637 //--------------------------------------------------------------------------------------------------
1638 /**
1639  * This function sets the SUPL server URL.
1640  * That server URL is a NULL-terminated string with a maximum string length (including NULL
1641  * terminator) equal to 256. Optionally the port number is specified after a colon.
1642  *
1643  * @return
1644  * - LE_OK on success
1645  * - LE_FAULT on failure
1646  * - LE_BUSY service is busy
1647  * - LE_TIMEOUT a time-out occurred
1648  *
1649  * @note If the SUPL server URL size is bigger than the maximum string length (including NULL
1650  * terminator) size, it is a fatal error, the function will not return.
1651  *
1652  * @warning The settings are platform dependent. Please refer to
1653  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1654  */
1655 //--------------------------------------------------------------------------------------------------
1657 (
1658  const char* LE_NONNULL suplServerUrl
1659  ///< [IN] SUPL server URL.
1660 );
1661 
1662 //--------------------------------------------------------------------------------------------------
1663 /**
1664  * This function injects the SUPL certificate to be used in A-GNSS sessions. Certificates must
1665  * be encoded in DER. Other certificate encryptions (e.g., PEM, CER and CRT)
1666  * aren't supported.
1667  *
1668  * @return
1669  * - LE_OK on success
1670  * - LE_BAD_PARAMETER on invalid parameter
1671  * - LE_FAULT on failure
1672  * - LE_BUSY service is busy
1673  * - LE_TIMEOUT a time-out occurred
1674  *
1675  * @note If the SUPL certificate size is bigger than the Maximum SUPL certificate size,
1676  * it is a fatal error, the function will not return.
1677  */
1678 //--------------------------------------------------------------------------------------------------
1680 (
1681  uint8_t suplCertificateId,
1682  ///< [IN] ID of the SUPL certificate.
1683  ///< Certificate ID range is 0 to 9
1684  uint16_t suplCertificateLen,
1685  ///< [IN] SUPL certificate size in Bytes.
1686  const char* LE_NONNULL suplCertificate
1687  ///< [IN] SUPL certificate contents.
1688 );
1689 
1690 //--------------------------------------------------------------------------------------------------
1691 /**
1692  * This function deletes the SUPL certificate.
1693  *
1694  * @return
1695  * - LE_OK on success
1696  * - LE_BAD_PARAMETER on invalid parameter
1697  * - LE_FAULT on failure
1698  * - LE_BUSY service is busy
1699  * - LE_TIMEOUT a time-out occurred
1700  */
1701 //--------------------------------------------------------------------------------------------------
1703 (
1704  uint8_t suplCertificateId
1705  ///< [IN] ID of the SUPL certificate.
1706  ///< Certificate ID range is 0 to 9
1707 );
1708 
1709 //--------------------------------------------------------------------------------------------------
1710 /**
1711  * This function sets the enabled NMEA sentences using a bit mask.
1712  *
1713  * @return
1714  * - LE_OK Success
1715  * - LE_BAD_PARAMETER Bit mask exceeds the maximal value
1716  * - LE_FAULT Failure
1717  * - LE_BUSY Service is busy
1718  * - LE_TIMEOUT Timeout occurred
1719  * - LE_NOT_PERMITTED GNSS device is not in "ready" state
1720  *
1721  * @warning This function may be subject to limitations depending on the platform. Please refer to
1722  * the @ref platformConstraintsGnss page.
1723  *
1724  * @warning The settings are platform dependent. Please refer to
1725  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1726  */
1727 //--------------------------------------------------------------------------------------------------
1729 (
1730  le_gnss_NmeaBitMask_t nmeaMask
1731  ///< [IN] Bit mask for enabled NMEA sentences.
1732 );
1733 
1734 //--------------------------------------------------------------------------------------------------
1735 /**
1736  * This function gets the bit mask for the enabled NMEA sentences.
1737  *
1738  * @return
1739  * - LE_OK Success
1740  * - LE_FAULT Failure
1741  * - LE_BUSY Service is busy
1742  * - LE_TIMEOUT Timeout occurred
1743  * - LE_NOT_PERMITTED GNSS device is not in "ready" state
1744  *
1745  * @note If the caller is passing an null pointer to this function, it is a fatal error
1746  * and the function will not return.
1747  */
1748 //--------------------------------------------------------------------------------------------------
1750 (
1751  le_gnss_NmeaBitMask_t* nmeaMaskPtrPtr
1752  ///< [OUT] Bit mask for enabled NMEA sentences.
1753 );
1754 
1755 //--------------------------------------------------------------------------------------------------
1756 /**
1757  * This function returns the status of the GNSS device.
1758  *
1759  */
1760 //--------------------------------------------------------------------------------------------------
1762 (
1763  void
1764 );
1765 
1766 //--------------------------------------------------------------------------------------------------
1767 /**
1768  * This function sets the GNSS minimum elevation.
1769  *
1770  * @return
1771  * - LE_OK on success
1772  * - LE_FAULT on failure
1773  * - LE_OUT_OF_RANGE if the minimum elevation is above range
1774  * - LE_UNSUPPORTED request not supported
1775  *
1776  * @warning The settings are platform dependent. Please refer to
1777  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1778  */
1779 //--------------------------------------------------------------------------------------------------
1781 (
1782  uint8_t minElevation
1783  ///< [IN] Minimum elevation in degrees [range 0..90].
1784 );
1785 
1786 //--------------------------------------------------------------------------------------------------
1787 /**
1788  * This function gets the GNSS minimum elevation.
1789  *
1790  * @return
1791  * - LE_OK on success
1792  * - LE_FAULT on failure
1793  * - LE_UNSUPPORTED request not supported
1794  *
1795  * @note If the caller is passing an null pointer to this function, it is a fatal error
1796  * and the function will not return.
1797  */
1798 //--------------------------------------------------------------------------------------------------
1800 (
1801  uint8_t* minElevationPtrPtr
1802  ///< [OUT] Minimum elevation in degrees [range 0..90].
1803 );
1804 
1805 #endif // LE_GNSS_INTERFACE_H_INCLUDE_GUARD
Definition: le_gnss_interface.h:586
le_gnss_AssistedMode_t
Definition: le_gnss_interface.h:643
le_result_t le_gnss_GetDirection(le_gnss_SampleRef_t positionSampleRef, uint32_t *directionPtr, uint32_t *directionAccuracyPtr)
le_result_t le_gnss_GetAltitude(le_gnss_SampleRef_t positionSampleRef, int32_t *altitudePtr, int32_t *vAccuracyPtr)
The GNSS device is not initialized.
Definition: le_gnss_interface.h:546
le_gnss_SbasConstellationCategory_t le_gnss_GetSbasConstellationCategory(uint16_t satId)
le_result_t le_gnss_InjectSuplCertificate(uint8_t suplCertificateId, uint16_t suplCertificateLen, const char *LE_NONNULL suplCertificate)
Do not use.
Definition: le_gnss_interface.h:554
le_result_t le_gnss_GetSatellitesInfo(le_gnss_SampleRef_t positionSampleRef, uint16_t *satIdPtr, size_t *satIdSizePtr, le_gnss_Constellation_t *satConstPtr, size_t *satConstSizePtr, bool *satUsedPtr, size_t *satUsedSizePtr, uint8_t *satSnrPtr, size_t *satSnrSizePtr, uint16_t *satAzimPtr, size_t *satAzimSizePtr, uint8_t *satElevPtr, size_t *satElevSizePtr)
Definition: le_gnss_interface.h:623
le_result_t le_gnss_GetExtendedEphemerisValidity(uint64_t *startTimePtr, uint64_t *stopTimePtr)
GNGSA type enabled: GNSS DOP and active satellites.
Definition: le_gnss_interface.h:698
le_result_t
Definition: le_basics.h:35
le_result_t le_gnss_Start(void)
Standalone mode.
Definition: le_gnss_interface.h:645
le_gnss_PositionHandlerRef_t le_gnss_AddPositionHandler(le_gnss_PositionHandlerFunc_t handlerPtr, void *contextPtr)
Russian satellite navigation system.
Definition: le_gnss_interface.h:666
le_result_t le_gnss_GetEpochTime(le_gnss_SampleRef_t positionSampleRef, uint64_t *millisecondsPtr)
le_result_t le_gnss_ForceFactoryRestart(void)
struct le_gnss_Sample * le_gnss_SampleRef_t
Definition: le_gnss_interface.h:536
le_result_t le_gnss_LoadExtendedEphemerisFile(int fd)
PSTIS type enabled: GPS session start indication.
Definition: le_gnss_interface.h:704
le_result_t le_gnss_GetAcquisitionRate(uint32_t *ratePtr)
void le_gnss_DisconnectService(void)
Definition: le_gnss_interface.h:595
Definition: le_gnss_interface.h:614
Definition: le_gnss_interface.h:626
Chinese satellite navigation system.
Definition: le_gnss_interface.h:668
GNGNS type enabled: GNSS fix data.
Definition: le_gnss_interface.h:697
GAGGA type enabled: Galileo fix data.
Definition: le_gnss_interface.h:699
le_result_t le_gnss_ForceColdRestart(void)
GAGSA type enabled: Galileo DOP and active satellites.
Definition: le_gnss_interface.h:700
Estimated (i.e. forward predicted) position fix.
Definition: le_gnss_interface.h:573
le_result_t le_gnss_ForceWarmRestart(void)
le_gnss_State_t
Definition: le_gnss_interface.h:544
le_result_t le_gnss_InjectUtcTime(uint64_t timeUtc, uint32_t timeUnc)
GPGSV type enabled: GPS satellites in view.
Definition: le_gnss_interface.h:693
Definition: le_gnss_interface.h:620
Japanese satellite navigation system.
Definition: le_gnss_interface.h:673
le_result_t le_gnss_GetTtff(uint32_t *ttffPtr)
le_result_t le_gnss_GetConstellation(le_gnss_ConstellationBitMask_t *constellationMaskPtr)
The GNSS device is active.
Definition: le_gnss_interface.h:550
void le_gnss_RemovePositionHandler(le_gnss_PositionHandlerRef_t handlerRef)
le_result_t le_gnss_SetSuplServerUrl(const char *LE_NONNULL suplServerUrl)
Maximum value.
Definition: le_gnss_interface.h:632
le_result_t le_gnss_EnableExtendedEphemerisFile(void)
3-Dimensional position fix.
Definition: le_gnss_interface.h:571
le_result_t le_gnss_GetAltitudeOnWgs84(le_gnss_SampleRef_t positionSampleRef, int32_t *altitudeOnWgs84Ptr)
le_result_t le_gnss_GetTime(le_gnss_SampleRef_t positionSampleRef, uint16_t *hoursPtr, uint16_t *minutesPtr, uint16_t *secondsPtr, uint16_t *millisecondsPtr)
le_result_t le_gnss_GetSuplAssistedMode(le_gnss_AssistedMode_t *assistedModePtr)
le_result_t le_gnss_GetLocation(le_gnss_SampleRef_t positionSampleRef, int32_t *latitudePtr, int32_t *longitudePtr, int32_t *hAccuracyPtr)
le_result_t le_gnss_DisableExtendedEphemerisFile(void)
GAVTG type enabled: Galileo vector track and speed over the ground.
Definition: le_gnss_interface.h:703
le_result_t le_gnss_TryConnectService(void)
le_result_t le_gnss_SetAcquisitionRate(uint32_t rate)
le_result_t le_gnss_SetMinElevation(uint8_t minElevation)
Definition: le_gnss_interface.h:589
le_gnss_NmeaBitMask_t
Definition: le_gnss_interface.h:689
le_result_t le_gnss_DeleteSuplCertificate(uint8_t suplCertificateId)
North American satellite navigation system.
Definition: le_gnss_interface.h:664
le_gnss_FixState_t
Definition: le_gnss_interface.h:565
2-Dimensional position fix.
Definition: le_gnss_interface.h:569
le_result_t le_gnss_GetMagneticDeviation(le_gnss_SampleRef_t positionSampleRef, int32_t *magneticDeviationPtr)
Definition: le_gnss_interface.h:629
void le_gnss_ReleaseSampleRef(le_gnss_SampleRef_t positionSampleRef)
Definition: le_gnss_interface.h:617
le_result_t le_gnss_GetNmeaSentences(le_gnss_NmeaBitMask_t *nmeaMaskPtrPtr)
The GNSS device is disabled.
Definition: le_gnss_interface.h:552
le_result_t le_gnss_GetVerticalSpeed(le_gnss_SampleRef_t positionSampleRef, int32_t *vspeedPtr, int32_t *vspeedAccuracyPtr)
MS-Assisted mode.
Definition: le_gnss_interface.h:649
le_result_t le_gnss_SetSuplAssistedMode(le_gnss_AssistedMode_t assistedMode)
le_result_t le_gnss_GetDate(le_gnss_SampleRef_t positionSampleRef, uint16_t *yearPtr, uint16_t *monthPtr, uint16_t *dayPtr)
le_gnss_ConstellationBitMask_t
Definition: le_gnss_interface.h:662
GPVTG type enabled: GPS vector track and speed over the ground.
Definition: le_gnss_interface.h:695
void le_gnss_ConnectService(void)
GPRMC type enabled: GPS recommended minimum data.
Definition: le_gnss_interface.h:694
le_result_t le_gnss_GetSatellitesStatus(le_gnss_SampleRef_t positionSampleRef, uint8_t *satsInViewCountPtr, uint8_t *satsTrackingCountPtr, uint8_t *satsUsedCountPtr)
PQXFI type enabled: Proprietary Qualcomm eXtended Fix Information.
Definition: le_gnss_interface.h:705
European Union satellite navigation system.
Definition: le_gnss_interface.h:670
le_result_t le_gnss_Stop(void)
Definition: le_gnss_interface.h:598
le_gnss_State_t le_gnss_GetState(void)
le_result_t le_gnss_SetNmeaSentences(le_gnss_NmeaBitMask_t nmeaMask)
le_result_t le_gnss_GetPositionState(le_gnss_SampleRef_t positionSampleRef, le_gnss_FixState_t *statePtr)
le_result_t le_gnss_GetMinElevation(uint8_t *minElevationPtrPtr)
le_result_t le_gnss_Disable(void)
GPGGA type enabled: GPS fix data.
Definition: le_gnss_interface.h:691
void le_gnss_SetServerDisconnectHandler(le_gnss_DisconnectHandler_t disconnectHandler, void *contextPtr)
Definition: le_gnss_interface.h:592
le_result_t le_gnss_GetHorizontalSpeed(le_gnss_SampleRef_t positionSampleRef, uint32_t *hspeedPtr, uint32_t *hspeedAccuracyPtr)
void(* le_gnss_PositionHandlerFunc_t)(le_gnss_SampleRef_t positionSampleRef, void *contextPtr)
Definition: le_gnss_interface.h:725
le_gnss_SampleRef_t le_gnss_GetLastSampleRef(void)
le_result_t le_gnss_SetConstellation(le_gnss_ConstellationBitMask_t constellationMask)
GNSS constellation field not defined.
Definition: le_gnss_interface.h:612
le_result_t le_gnss_ForceHotRestart(void)
SBAS constellation used in solution.
Definition: le_gnss_interface.h:672
MS-Based mode.
Definition: le_gnss_interface.h:647
le_result_t le_gnss_Enable(void)
void(* le_gnss_DisconnectHandler_t)(void *)
Definition: le_gnss_interface.h:401
le_result_t le_gnss_GetGpsTime(le_gnss_SampleRef_t positionSampleRef, uint32_t *gpsWeekPtr, uint32_t *gpsTimeOfWeekPtr)
GPGSA type enabled: GPS DOP and active satellites.
Definition: le_gnss_interface.h:692
le_gnss_SbasConstellationCategory_t
Definition: le_gnss_interface.h:584
le_result_t le_gnss_GetGpsLeapSeconds(le_gnss_SampleRef_t positionSampleRef, uint8_t *leapSecondsPtr)
The GNSS device is ready.
Definition: le_gnss_interface.h:548
The GNSS fix position is not fixed.
Definition: le_gnss_interface.h:567
GLGSV type enabled: GLONASS satellites in view.
Definition: le_gnss_interface.h:696
GAGSV type enabled: Galileo satellites in view.
Definition: le_gnss_interface.h:701
le_result_t le_gnss_GetTimeAccuracy(le_gnss_SampleRef_t positionSampleRef, uint32_t *timeAccuracyPtr)
struct le_gnss_PositionHandler * le_gnss_PositionHandlerRef_t
Definition: le_gnss_interface.h:715
GARMC type enabled: Galileo recommended minimum data.
Definition: le_gnss_interface.h:702
le_gnss_Constellation_t
Definition: le_gnss_interface.h:610
le_result_t le_gnss_GetDop(le_gnss_SampleRef_t positionSampleRef, uint16_t *hdopPtr, uint16_t *vdopPtr, uint16_t *pdopPtr)