le_gnss_common.h

Go to the documentation of this file.
1 
2 /*
3  * ====================== WARNING ======================
4  *
5  * THE CONTENTS OF THIS FILE HAVE BEEN AUTO-GENERATED.
6  * DO NOT MODIFY IN ANY WAY.
7  *
8  * ====================== WARNING ======================
9  */
10 /**
11  * @file le_gnss_common.h
12  *
13  * Type definitions for le_gnss.
14  *
15  */
16 #ifndef LE_GNSS_COMMON_H_INCLUDE_GUARD
17 #define LE_GNSS_COMMON_H_INCLUDE_GUARD
18 
19 
20 #include "legato.h"
21 
22 #define IFGEN_LE_GNSS_PROTOCOL_ID "033024bf41c7d7022c57982b49cdfda3"
23 #define IFGEN_LE_GNSS_MSG_SIZE 2015
24 /** @addtogroup le_gnss
25  * @{ **/
26 
27 
28 //--------------------------------------------------------------------------------------------------
29 /**
30  * Maximum length of the SUP Server URL string.
31  */
32 //--------------------------------------------------------------------------------------------------
33 #define LE_GNSS_SUPL_SERVER_URL_MAX_LEN 256
34 
35 //--------------------------------------------------------------------------------------------------
36 /**
37  * Maximum length of the SUP Server URL string.
38  * One extra byte is added for the null character.
39  */
40 //--------------------------------------------------------------------------------------------------
41 #define LE_GNSS_SUPL_SERVER_URL_MAX_BYTES 257
42 
43 //--------------------------------------------------------------------------------------------------
44 /**
45  * Maximum SUPL certificate size.
46  */
47 //--------------------------------------------------------------------------------------------------
48 #define LE_GNSS_SUPL_CERTIFICATE_MAX_LEN 2000
49 
50 //--------------------------------------------------------------------------------------------------
51 /**
52  * Maximum SUPL certificate string size.
53  * One extra byte is added for the null character.
54  */
55 //--------------------------------------------------------------------------------------------------
56 #define LE_GNSS_SUPL_CERTIFICATE_MAX_BYTES 2001
57 
58 //--------------------------------------------------------------------------------------------------
59 /**
60  * Define the maximum length of the Satellites Vehicle information list
61  */
62 //--------------------------------------------------------------------------------------------------
63 #define LE_GNSS_SV_INFO_MAX_LEN 80
64 
65 //--------------------------------------------------------------------------------------------------
66 /**
67  * Define the maximal bit mask for enabled NMEA sentences
68  *
69  * @note This maximal value should be coherent with @ref le_gnss_NmeaBitMask_t
70  */
71 //--------------------------------------------------------------------------------------------------
72 #define LE_GNSS_NMEA_SENTENCES_MAX 15728639
73 
74 //--------------------------------------------------------------------------------------------------
75 /**
76  * Define the maximal degree for the minimal elevation
77  */
78 //--------------------------------------------------------------------------------------------------
79 #define LE_GNSS_MIN_ELEVATION_MAX_DEGREE 90
80 
81 //--------------------------------------------------------------------------------------------------
82 /**
83  * Satellite Vehicle (SV) ID to PRN offset definitions
84  *
85  * @note SV ID is given both in le_gnss_GetSatellitesInfo() API and NMEA flow. Its corresponding
86  * PRN code can be computed adding the following offset according to its constellation.
87  */
88 //--------------------------------------------------------------------------------------------------
89 #define LE_GNSS_PRN_OFFSET_GPS 0
90 
91 //--------------------------------------------------------------------------------------------------
92 /**
93  */
94 //--------------------------------------------------------------------------------------------------
95 #define LE_GNSS_PRN_OFFSET_SBAS 87
96 
97 //--------------------------------------------------------------------------------------------------
98 /**
99  */
100 //--------------------------------------------------------------------------------------------------
101 #define LE_GNSS_PRN_OFFSET_GLONASS -64
102 
103 //--------------------------------------------------------------------------------------------------
104 /**
105  */
106 //--------------------------------------------------------------------------------------------------
107 #define LE_GNSS_PRN_OFFSET_GALILEO -300
108 
109 //--------------------------------------------------------------------------------------------------
110 /**
111  */
112 //--------------------------------------------------------------------------------------------------
113 #define LE_GNSS_PRN_OFFSET_BEIDOU -200
114 
115 //--------------------------------------------------------------------------------------------------
116 /**
117  */
118 //--------------------------------------------------------------------------------------------------
119 #define LE_GNSS_PRN_OFFSET_QZSS 0
120 
121 //--------------------------------------------------------------------------------------------------
122 /**
123  * Reference type for dealing with GNSS position samples.
124  */
125 //--------------------------------------------------------------------------------------------------
126 typedef struct le_gnss_Sample* le_gnss_SampleRef_t;
127 
128 
129 //--------------------------------------------------------------------------------------------------
130 /**
131  * Enumeration for GNSS device state
132  */
133 //--------------------------------------------------------------------------------------------------
134 typedef enum
135 {
137  ///< The GNSS device is not initialized
139  ///< The GNSS device is ready
141  ///< The GNSS device is active
143  ///< The GNSS device is disabled
145  ///< Do not use
146 }
148 
149 
150 //--------------------------------------------------------------------------------------------------
151 /**
152  * GNSS fix position states.
153  */
154 //--------------------------------------------------------------------------------------------------
155 typedef enum
156 {
158  ///< The GNSS fix position is not fixed.
160  ///< 2-Dimensional position fix.
162  ///< 3-Dimensional position fix.
164  ///< Estimated (i.e. forward predicted) position fix.
165 }
167 
168 
169 //--------------------------------------------------------------------------------------------------
170 /**
171  * Resolutions values.
172  */
173 //--------------------------------------------------------------------------------------------------
174 typedef enum
175 {
177  ///< Resolution of 0 decimal place.
179  ///< Resolution of 1 decimal place.
181  ///< Resolution of 2 decimal places.
183  ///< Resolution of 3 decimal places.
185  ///< Unknown resolution.
186 }
188 
189 
190 //--------------------------------------------------------------------------------------------------
191 /**
192  ** Data types.
193  */
194 //--------------------------------------------------------------------------------------------------
195 typedef enum
196 {
198  ///< Vertical accuracy data.
200  ///< Vertical speed accuracy data.
202  ///< Horizontal speed accuracy data.
204  ///< Unknown data type.
205 }
207 
208 
209 //--------------------------------------------------------------------------------------------------
210 /**
211  * SBAS constellation category
212  */
213 //--------------------------------------------------------------------------------------------------
214 typedef enum
215 {
217  ///< Satellite Vehicle of Satellite-based augmentation system
218  ///< (SBAS) EGNOS constellation.
220  ///< Satellite Vehicle of Satellite-based augmentation system
221  ///< (SBAS) WAAS constellation.
223  ///< Satellite Vehicle of Satellite-based augmentation system
224  ///< (SBAS) GAGAN constellation.
226  ///< Satellite Vehicle of Satellite-based augmentation system
227  ///< (SBAS) MSAS constellation.
229  ///< Satellite Vehicle of Satellite-based augmentation system
230  ///< (SBAS) SDCM constellation.
232  ///< Satellite Vehicle of Satellite-based augmentation system
233  ///< (SBAS) unknown constellation.
234 }
236 
237 
238 //--------------------------------------------------------------------------------------------------
239 /**
240  * GNSS constellation type.
241  */
242 //--------------------------------------------------------------------------------------------------
243 typedef enum
244 {
246  ///< GNSS constellation field not defined.
248  ///< Satellite Vehicle of GPS constellation.
249  ///< North American satellite navigation system
251  ///< Satellite Vehicle of SBAS constellation.
252  ///< Satellite-based augmentation system
254  ///< Satellite Vehicle of Glonass constellation.
255  ///< Russian satellite navigation system
257  ///< Satellite Vehicle of Galileo constellation.
258  ///< European Union satellite navigation system
260  ///< Satellite Vehicle of Beidou constellation.
261  ///< Chinese satellite navigation system
263  ///< Satellite Vehicle of QZSS constellation.
264  ///< Japanese satellite navigation system
266  ///< Maximum value.
267 }
269 
270 
271 //--------------------------------------------------------------------------------------------------
272 /**
273  * Assisted-GNSS mode
274  */
275 //--------------------------------------------------------------------------------------------------
276 typedef enum
277 {
279  ///< Standalone mode.
281  ///< MS-Based mode.
283  ///< MS-Assisted mode.
284 }
286 
287 
288 //--------------------------------------------------------------------------------------------------
289 /**
290  * Dilution of precision type
291  */
292 //--------------------------------------------------------------------------------------------------
293 typedef enum
294 {
296  ///< Position dilution of precision.
298  ///< Horizontal dilution of precision.
300  ///< Vertical dilution of precision.
302  ///< Geometric dilution of precision.
304  ///< Time dilution of precision.
305  LE_GNSS_DOP_LAST = 5
306  ///<
307 }
309 
310 
311 //--------------------------------------------------------------------------------------------------
312 /**
313  * GNSS constellation area type
314  */
315 //--------------------------------------------------------------------------------------------------
316 typedef enum
317 {
319  ///< Unset area.
321  ///< Worldwide area.
323  ///< Outside US area.
324 }
326 
327 
328 //--------------------------------------------------------------------------------------------------
329 /**
330  * GNSS constellation Bit Mask (8 bits) indicating the GNSS constellation(s)
331  * used in solution.
332  *
333  */
334 //--------------------------------------------------------------------------------------------------/// GPS constellation used in solution.
335 /// North American satellite navigation system
336 #define LE_GNSS_CONSTELLATION_GPS 0x1/// GLONASS constellation used in solution.
337 /// Russian satellite navigation system
338 #define LE_GNSS_CONSTELLATION_GLONASS 0x2/// BEIDOU constellation used in solution.
339 /// Chinese satellite navigation system
340 #define LE_GNSS_CONSTELLATION_BEIDOU 0x4/// GALILEO constellation used in solution.
341 /// European Union satellite navigation system
342 #define LE_GNSS_CONSTELLATION_GALILEO 0x8/// SBAS constellation used in solution.
343 #define LE_GNSS_CONSTELLATION_SBAS 0x10/// QZSS constellation used in solution.
344 /// Japanese satellite navigation system
345 #define LE_GNSS_CONSTELLATION_QZSS 0x20
346 typedef uint32_t le_gnss_ConstellationBitMask_t;
347 
348 
349 //--------------------------------------------------------------------------------------------------
350 /**
351  * NMEA sentences Bit Mask indicating the NMEA sentences enabled in the NMEA flow.
352  *
353  * @warning The supported NMEA sentences depend on the platform. Please refer to your platform
354  * documentation for further details.
355  *
356  * @note The bit mask values should be coherent with @ref LE_GNSS_NMEA_SENTENCES_MAX
357  */
358 //--------------------------------------------------------------------------------------------------/// GPGGA type enabled: GPS fix data.
359 #define LE_GNSS_NMEA_MASK_GPGGA 0x1/// GPGSA type enabled: GPS DOP and active satellites.
360 #define LE_GNSS_NMEA_MASK_GPGSA 0x2/// GPGSV type enabled: GPS satellites in view.
361 #define LE_GNSS_NMEA_MASK_GPGSV 0x4/// GPRMC type enabled: GPS recommended minimum data.
362 #define LE_GNSS_NMEA_MASK_GPRMC 0x8/// GPVTG type enabled: GPS vector track and speed over the ground.
363 #define LE_GNSS_NMEA_MASK_GPVTG 0x10/// GLGSV type enabled: GLONASS satellites in view.
364 #define LE_GNSS_NMEA_MASK_GLGSV 0x20/// GNGNS type enabled: GNSS fix data.
365 #define LE_GNSS_NMEA_MASK_GNGNS 0x40/// GNGSA type enabled: GNSS DOP and active satellites.
366 #define LE_GNSS_NMEA_MASK_GNGSA 0x80/// GAGGA type enabled: Galileo fix data.
367 #define LE_GNSS_NMEA_MASK_GAGGA 0x100/// GAGSA type enabled: Galileo DOP and active satellites.
368 #define LE_GNSS_NMEA_MASK_GAGSA 0x200/// GAGSV type enabled: Galileo satellites in view.
369 #define LE_GNSS_NMEA_MASK_GAGSV 0x400/// GARMC type enabled: Galileo recommended minimum data.
370 #define LE_GNSS_NMEA_MASK_GARMC 0x800/// GAVTG type enabled: Galileo vector track and speed over the ground.
371 #define LE_GNSS_NMEA_MASK_GAVTG 0x1000/// PSTIS type enabled: GPS session start indication.
372 #define LE_GNSS_NMEA_MASK_PSTIS 0x2000///
373 #define LE_GNSS_NMEA_MASK_REMOVED 0x4000/// PTYPE type enabled: Proprietary Type mask.
374 #define LE_GNSS_NMEA_MASK_PTYPE 0x8000/// GPGRS type enabled: GPS Range residuals.
375 #define LE_GNSS_NMEA_MASK_GPGRS 0x10000/// GPGLL type enabled: GPS Geographic position, latitude / longitude.
376 #define LE_GNSS_NMEA_MASK_GPGLL 0x20000/// DEBUG type enabled: Debug NMEA indication.
377 #define LE_GNSS_NMEA_MASK_DEBUG 0x40000/// GPDTM type enabled: Local geodetic datum and datum offset from a
378 #define LE_GNSS_NMEA_MASK_GPDTM 0x80000/// GAGNS type enabled: Fix data for Galileo.
379 #define LE_GNSS_NMEA_MASK_GAGNS 0x100000/// GPGNS type enabled: Fix data for GPS.
380 #define LE_GNSS_NMEA_MASK_GPGNS 0x200000/// GPGST type enabled: Position Error statistics for GPS.
381 #define LE_GNSS_NMEA_MASK_GPGST 0x400000/// GPZDA type enabled: UTC day, month, year, and local time zone offset.
382 #define LE_GNSS_NMEA_MASK_GPZDA 0x800000
383 typedef uint32_t le_gnss_NmeaBitMask_t;
384 
385 
386 //--------------------------------------------------------------------------------------------------
387 /**
388  * Coordinate system
389  */
390 //--------------------------------------------------------------------------------------------------
391 typedef enum
392 {
394  ///< Coordinate system WGS84.
396  ///< Coordinate system PZ90.
398  ///< Maximum value.
399 }
401 
402 
403 //--------------------------------------------------------------------------------------------------
404 /**
405  ** Location data types
406  */
407 //--------------------------------------------------------------------------------------------------
408 typedef enum
409 {
411  ///< Latitude data position.
413  ///< Longitude data position.
415  ///< Altitude data position.
417  ///< Maximum value.
418 }
420 
421 
422 //--------------------------------------------------------------------------------------------------
423 /**
424  * Type of GNSS start.
425  */
426 //--------------------------------------------------------------------------------------------------
427 typedef enum
428 {
430  ///< Hot start.
432  ///< Warm start.
434  ///< Cold start.
436  ///< Factory start.
438  ///< Unknown start.
439 }
441 
442 
443 //--------------------------------------------------------------------------------------------------
444 /**
445  * Reference type used by Add/Remove functions for EVENT 'le_gnss_Position'
446  */
447 //--------------------------------------------------------------------------------------------------
448 typedef struct le_gnss_PositionHandler* le_gnss_PositionHandlerRef_t;
449 
450 
451 //--------------------------------------------------------------------------------------------------
452 /**
453  * Handler for position information.
454  *
455  */
456 //--------------------------------------------------------------------------------------------------
457 typedef void (*le_gnss_PositionHandlerFunc_t)
458 (
459  le_gnss_SampleRef_t positionSampleRef,
460  ///< Position's sample reference
461  void* contextPtr
462  ///<
463 );
464 
465 
466 //--------------------------------------------------------------------------------------------------
467 /**
468  * Get if this client bound locally.
469  */
470 //--------------------------------------------------------------------------------------------------
471 LE_SHARED bool ifgen_le_gnss_HasLocalBinding
472 (
473  void
474 );
475 
476 
477 //--------------------------------------------------------------------------------------------------
478 /**
479  * Init data that is common across all threads
480  */
481 //--------------------------------------------------------------------------------------------------
482 LE_SHARED void ifgen_le_gnss_InitCommonData
483 (
484  void
485 );
486 
487 
488 //--------------------------------------------------------------------------------------------------
489 /**
490  * Perform common initialization and open a session
491  */
492 //--------------------------------------------------------------------------------------------------
493 LE_SHARED le_result_t ifgen_le_gnss_OpenSession
494 (
495  le_msg_SessionRef_t _ifgen_sessionRef,
496  bool isBlocking
497 );
498 
499 //--------------------------------------------------------------------------------------------------
500 /**
501  * Set the GNSS constellation bit mask
502  *
503  * @return
504  * - LE_FAULT The function failed.
505  * - LE_UNSUPPORTED If the request is not supported.
506  * - LE_NOT_PERMITTED If the GNSS device is not initialized, disabled or active.
507  * - LE_OK The function succeeded.
508  *
509  * @warning Some constellation types are unsupported depending on the platform. Please refer to
510  * @ref platformConstraintsGnss_ConstellationType section for full details.
511  *
512  * @warning The settings are platform dependent. Please refer to
513  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
514  */
515 //--------------------------------------------------------------------------------------------------
516 LE_SHARED le_result_t ifgen_le_gnss_SetConstellation
517 (
518  le_msg_SessionRef_t _ifgen_sessionRef,
519  le_gnss_ConstellationBitMask_t constellationMask
520  ///< [IN] GNSS constellation used in solution.
521 );
522 
523 //--------------------------------------------------------------------------------------------------
524 /**
525  * Get the GNSS constellation bit mask
526  *
527  * @return
528  * - LE_OK on success
529  * - LE_FAULT on failure
530  *
531  * @note If the caller is passing a null pointer into this function, it is a fatal error, the
532  * function will not return.
533  */
534 //--------------------------------------------------------------------------------------------------
535 LE_SHARED le_result_t ifgen_le_gnss_GetConstellation
536 (
537  le_msg_SessionRef_t _ifgen_sessionRef,
538  le_gnss_ConstellationBitMask_t* constellationMaskPtr
539  ///< [OUT] GNSS constellation used in solution.
540 );
541 
542 //--------------------------------------------------------------------------------------------------
543 /**
544  * Set the area for the GNSS constellation
545  *
546  * @return
547  * - LE_OK The function succeeded.
548  * - LE_FAULT The function failed.
549  * - LE_UNSUPPORTED If the request is not supported.
550  * - LE_NOT_PERMITTED If the GNSS device is not initialized, disabled or active.
551  * - LE_BAD_PARAMETER Invalid constellation area.
552  *
553  * @warning The settings are platform dependent. Please refer to
554  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
555  */
556 //--------------------------------------------------------------------------------------------------
557 LE_SHARED le_result_t ifgen_le_gnss_SetConstellationArea
558 (
559  le_msg_SessionRef_t _ifgen_sessionRef,
560  le_gnss_Constellation_t satConstellation,
561  ///< [IN] GNSS constellation type.
562  le_gnss_ConstellationArea_t constellationArea
563  ///< [IN] GNSS constellation area.
564 );
565 
566 //--------------------------------------------------------------------------------------------------
567 /**
568  * Get the area for the GNSS constellation
569  *
570  * @return
571  * - LE_OK On success
572  * - LE_FAULT On failure
573  * - LE_UNSUPPORTED Request not supported
574  * - LE_NOT_PERMITTED If the GNSS device is not initialized, disabled or active.
575  *
576  * @note If the caller is passing a null pointer into this function, it is a fatal error, the
577  * function will not return.
578  */
579 //--------------------------------------------------------------------------------------------------
580 LE_SHARED le_result_t ifgen_le_gnss_GetConstellationArea
581 (
582  le_msg_SessionRef_t _ifgen_sessionRef,
583  le_gnss_Constellation_t satConstellation,
584  ///< [IN] GNSS constellation type.
585  le_gnss_ConstellationArea_t* constellationAreaPtr
586  ///< [OUT] GNSS constellation area.
587 );
588 
589 //--------------------------------------------------------------------------------------------------
590 /**
591  * This function enables the use of the 'Extended Ephemeris' file into the GNSS device.
592  *
593  * @return
594  * - LE_FAULT The function failed.
595  * - LE_OK The function succeeded.
596  *
597  * @warning The settings are platform dependent. Please refer to
598  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
599  */
600 //--------------------------------------------------------------------------------------------------
601 LE_SHARED le_result_t ifgen_le_gnss_EnableExtendedEphemerisFile
602 (
603  le_msg_SessionRef_t _ifgen_sessionRef
604 );
605 
606 //--------------------------------------------------------------------------------------------------
607 /**
608  * This function disables the use of the 'Extended Ephemeris' file into the GNSS device.
609  *
610  * @return
611  * - LE_FAULT The function failed.
612  * - LE_OK The function succeeded.
613  *
614  * @warning The settings are platform dependent. Please refer to
615  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
616  */
617 //--------------------------------------------------------------------------------------------------
618 LE_SHARED le_result_t ifgen_le_gnss_DisableExtendedEphemerisFile
619 (
620  le_msg_SessionRef_t _ifgen_sessionRef
621 );
622 
623 //--------------------------------------------------------------------------------------------------
624 /**
625  * This function must be called to load an 'Extended Ephemeris' file into the GNSS device.
626  *
627  * @return
628  * - LE_FAULT The function failed to inject the 'Extended Ephemeris' file.
629  * - LE_TIMEOUT A time-out occurred.
630  * - LE_FORMAT_ERROR 'Extended Ephemeris' file format error.
631  * - LE_OK The function succeeded.
632  *
633  */
634 //--------------------------------------------------------------------------------------------------
635 LE_SHARED le_result_t ifgen_le_gnss_LoadExtendedEphemerisFile
636 (
637  le_msg_SessionRef_t _ifgen_sessionRef,
638  int fd
639  ///< [IN] Extended ephemeris file descriptor
640 );
641 
642 //--------------------------------------------------------------------------------------------------
643 /**
644  * This function must be called to get the validity of the last injected Extended Ephemeris.
645  *
646  * @return
647  * - LE_FAULT The function failed to get the validity
648  * - LE_OK The function succeeded.
649  *
650  * @note If the caller is passing an invalid Position sample reference or null pointers into this
651  * function, it is a fatal error, the function will not return.
652  */
653 //--------------------------------------------------------------------------------------------------
654 LE_SHARED le_result_t ifgen_le_gnss_GetExtendedEphemerisValidity
655 (
656  le_msg_SessionRef_t _ifgen_sessionRef,
657  uint64_t* startTimePtr,
658  ///< [OUT] Start time in seconds (since Jan. 1, 1970)
659  uint64_t* stopTimePtr
660  ///< [OUT] Stop time in seconds (since Jan. 1, 1970)
661 );
662 
663 //--------------------------------------------------------------------------------------------------
664 /**
665  * This function must be called to inject the UTC time into the GNSS device.
666  *
667  * @return
668  * - LE_OK The function succeeded.
669  * - LE_FAULT The function failed to inject the UTC time.
670  * - LE_TIMEOUT A time-out occurred.
671  *
672  * @note It is mandatory to enable the 'Extended Ephemeris' file injection into the GNSS device with
673  * le_gnss_EnableExtendedEphemerisFile() before injecting time with this API.
674  */
675 //--------------------------------------------------------------------------------------------------
676 LE_SHARED le_result_t ifgen_le_gnss_InjectUtcTime
677 (
678  le_msg_SessionRef_t _ifgen_sessionRef,
679  uint64_t timeUtc,
680  ///< [IN] [IN] UTC time since Jan. 1, 1970 in milliseconds
681  uint32_t timeUnc
682  ///< [IN] [IN] Time uncertainty in milliseconds
683 );
684 
685 //--------------------------------------------------------------------------------------------------
686 /**
687  * This function starts the GNSS device.
688  *
689  * @return
690  * - LE_FAULT The function failed.
691  * - LE_DUPLICATE If the GNSS device is already started.
692  * - LE_NOT_PERMITTED If the GNSS device is not initialized or disabled.
693  * - LE_OK The function succeeded.
694  *
695  */
696 //--------------------------------------------------------------------------------------------------
697 LE_SHARED le_result_t ifgen_le_gnss_Start
698 (
699  le_msg_SessionRef_t _ifgen_sessionRef
700 );
701 
702 //--------------------------------------------------------------------------------------------------
703 /**
704  * This function starts the GNSS device in the specified start mode.
705  *
706  * @return
707  * - LE_OK The function succeeded.
708  * - LE_BAD_PARAMETER Invalid start mode
709  * - LE_FAULT The function failed.
710  * - LE_DUPLICATE If the GNSS device is already started.
711  * - LE_NOT_PERMITTED If the GNSS device is not initialized or disabled.
712  *
713  * @warning This function may be subject to limitations depending on the platform. Please refer to
714  * the @ref platformConstraintsGnss page.
715  */
716 //--------------------------------------------------------------------------------------------------
717 LE_SHARED le_result_t ifgen_le_gnss_StartMode
718 (
719  le_msg_SessionRef_t _ifgen_sessionRef,
721  ///< [IN] [IN] Start mode
722 );
723 
724 //--------------------------------------------------------------------------------------------------
725 /**
726  * This function stops the GNSS device.
727  *
728  * @return
729  * - LE_FAULT The function failed.
730  * - LE_DUPLICATE If the GNSS device is already stopped.
731  * - LE_NOT_PERMITTED If the GNSS device is not initialized or disabled.
732  * - LE_OK The function succeeded.
733  *
734  */
735 //--------------------------------------------------------------------------------------------------
736 LE_SHARED le_result_t ifgen_le_gnss_Stop
737 (
738  le_msg_SessionRef_t _ifgen_sessionRef
739 );
740 
741 //--------------------------------------------------------------------------------------------------
742 /**
743  * This function performs a "HOT" restart of the GNSS device.
744  *
745  * @return
746  * - LE_FAULT The function failed.
747  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
748  * - LE_OK The function succeeded.
749  *
750  * @Note This API can be used to restart the GNSS device. It is equivalent calling le_gnss_Stop()
751  * and le_gnss_Start().
752  */
753 //--------------------------------------------------------------------------------------------------
754 LE_SHARED le_result_t ifgen_le_gnss_ForceHotRestart
755 (
756  le_msg_SessionRef_t _ifgen_sessionRef
757 );
758 
759 //--------------------------------------------------------------------------------------------------
760 /**
761  * This function performs a "WARM" restart of the GNSS device.
762  *
763  * @return
764  * - LE_FAULT The function failed.
765  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
766  * - LE_OK The function succeeded.
767  *
768  * @Note This API has a platform dependent feature. Please refer to
769  * @ref platformConstraintsGnss_WarmRestart for further details.
770  */
771 //--------------------------------------------------------------------------------------------------
772 LE_SHARED le_result_t ifgen_le_gnss_ForceWarmRestart
773 (
774  le_msg_SessionRef_t _ifgen_sessionRef
775 );
776 
777 //--------------------------------------------------------------------------------------------------
778 /**
779  * This function performs a "COLD" restart of the GNSS device.
780  *
781  * @return
782  * - LE_FAULT The function failed.
783  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
784  * - LE_OK The function succeeded.
785  *
786  */
787 //--------------------------------------------------------------------------------------------------
788 LE_SHARED le_result_t ifgen_le_gnss_ForceColdRestart
789 (
790  le_msg_SessionRef_t _ifgen_sessionRef
791 );
792 
793 //--------------------------------------------------------------------------------------------------
794 /**
795  * This function performs a "FACTORY" restart of the GNSS device.
796  *
797  * @return
798  * - LE_FAULT The function failed.
799  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
800  * - LE_OK The function succeeded.
801  *
802  */
803 //--------------------------------------------------------------------------------------------------
804 LE_SHARED le_result_t ifgen_le_gnss_ForceFactoryRestart
805 (
806  le_msg_SessionRef_t _ifgen_sessionRef
807 );
808 
809 //--------------------------------------------------------------------------------------------------
810 /**
811  * Get the TTFF in milliseconds
812  *
813  * @return
814  * - LE_BUSY The position is not fixed and TTFF can't be measured.
815  * - LE_NOT_PERMITTED If the GNSS device is not enabled or not started.
816  * - LE_OK Function succeeded.
817  * - LE_FAULT If there are some other errors.
818  *
819  * @note If the caller is passing a null pointer into this function, it is a fatal error, the
820  * function will not return.
821  */
822 //--------------------------------------------------------------------------------------------------
823 LE_SHARED le_result_t ifgen_le_gnss_GetTtff
824 (
825  le_msg_SessionRef_t _ifgen_sessionRef,
826  uint32_t* ttffPtr
827  ///< [OUT] TTFF in milliseconds
828 );
829 
830 //--------------------------------------------------------------------------------------------------
831 /**
832  * This function enables the GNSS device.
833  *
834  * @return
835  * - LE_FAULT The function failed.
836  * - LE_DUPLICATE If the GNSS device is already enabled.
837  * - LE_NOT_PERMITTED If the GNSS device is not initialized.
838  * - LE_OK The function succeeded.
839  *
840  * @warning The settings are platform dependent. Please refer to
841  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
842  */
843 //--------------------------------------------------------------------------------------------------
844 LE_SHARED le_result_t ifgen_le_gnss_Enable
845 (
846  le_msg_SessionRef_t _ifgen_sessionRef
847 );
848 
849 //--------------------------------------------------------------------------------------------------
850 /**
851  * This function disables the GNSS device.
852  *
853  * @return
854  * - LE_FAULT The function failed.
855  * - LE_DUPLICATE If the GNSS device is already disabled.
856  * - LE_NOT_PERMITTED If the GNSS device is not initialized or started.
857  * - LE_OK The function succeeded.
858  *
859  * @warning The settings are platform dependent. Please refer to
860  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
861  */
862 //--------------------------------------------------------------------------------------------------
863 LE_SHARED le_result_t ifgen_le_gnss_Disable
864 (
865  le_msg_SessionRef_t _ifgen_sessionRef
866 );
867 
868 //--------------------------------------------------------------------------------------------------
869 /**
870  * This function sets the GNSS device acquisition rate.
871  *
872  * @return
873  * - LE_OK on success
874  * - LE_FAULT on failure
875  * - LE_UNSUPPORTED request not supported
876  * - LE_TIMEOUT a time-out occurred
877  * - LE_NOT_PERMITTED If the GNSS device is not in "ready" state.
878  * - LE_OUT_OF_RANGE if acquisition rate value is equal to zero
879  *
880  * @warning This function may be subject to limitations depending on the platform. Please refer to
881  * the @ref platformConstraintsGnss page.
882  *
883  * @warning The settings are platform dependent. Please refer to
884  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
885  */
886 //--------------------------------------------------------------------------------------------------
887 LE_SHARED le_result_t ifgen_le_gnss_SetAcquisitionRate
888 (
889  le_msg_SessionRef_t _ifgen_sessionRef,
890  uint32_t rate
891  ///< [IN] Acquisition rate in milliseconds.
892 );
893 
894 //--------------------------------------------------------------------------------------------------
895 /**
896  * This function gets the GNSS device acquisition rate.
897  *
898  * @return
899  * - LE_OK on success
900  * - LE_FAULT on failure
901  * - LE_NOT_PERMITTED If the GNSS device is not in "ready" state.
902  *
903  * @note If the caller is passing a null pointer into this function, it is a fatal error, the
904  * function will not return.
905  */
906 //--------------------------------------------------------------------------------------------------
907 LE_SHARED le_result_t ifgen_le_gnss_GetAcquisitionRate
908 (
909  le_msg_SessionRef_t _ifgen_sessionRef,
910  uint32_t* ratePtr
911  ///< [OUT] Acquisition rate in milliseconds.
912 );
913 
914 //--------------------------------------------------------------------------------------------------
915 /**
916  * Add handler function for EVENT 'le_gnss_Position'
917  *
918  * This event provides information on position.
919  *
920  * - A handler reference, which is only needed for later removal of the handler.
921  *
922  * @note Doesn't return on failure, so there's no need to check the return value for errors.
923  */
924 //--------------------------------------------------------------------------------------------------
925 LE_SHARED le_gnss_PositionHandlerRef_t ifgen_le_gnss_AddPositionHandler
926 (
927  le_msg_SessionRef_t _ifgen_sessionRef,
929  ///< [IN]
930  void* contextPtr
931  ///< [IN]
932 );
933 
934 //--------------------------------------------------------------------------------------------------
935 /**
936  * Remove handler function for EVENT 'le_gnss_Position'
937  */
938 //--------------------------------------------------------------------------------------------------
939 LE_SHARED void ifgen_le_gnss_RemovePositionHandler
940 (
941  le_msg_SessionRef_t _ifgen_sessionRef,
943  ///< [IN]
944 );
945 
946 //--------------------------------------------------------------------------------------------------
947 /**
948  * This function gets the position sample's fix state
949  *
950  * - LE_OK on success
951  * - LE_FAULT on failure
952  *
953  * @note If the caller is passing an invalid Position sample reference or a null pointer into this
954  * function, it is a fatal error, the function will not return.
955  */
956 //--------------------------------------------------------------------------------------------------
957 LE_SHARED le_result_t ifgen_le_gnss_GetPositionState
958 (
959  le_msg_SessionRef_t _ifgen_sessionRef,
960  le_gnss_SampleRef_t positionSampleRef,
961  ///< [IN] Position sample's reference.
962  le_gnss_FixState_t* statePtr
963  ///< [OUT] Position fix state.
964 );
965 
966 //--------------------------------------------------------------------------------------------------
967 /**
968  * Get the location's data (Latitude, Longitude, Horizontal accuracy).
969  *
970  * @return
971  * - LE_FAULT Function failed to get the location's data
972  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid (set to INT32_MAX).
973  * - LE_OK Function succeeded.
974  *
975  * @note latitudePtr, longitudePtr and hAccuracyPtr can be set to NULL if not needed.
976  *
977  * @note The latitude and longitude values are based on the WGS84 standard coordinate system.
978  *
979  * @note The latitude and longitude values are given in degrees with 6 decimal places like:
980  * Latitude +48858300 = 48.858300 degrees North
981  * Longitude +2294400 = 2.294400 degrees East
982  * (The latitude and longitude values are given in degrees, minutes, seconds in NMEA frame)
983  *
984  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
985  * valid. Please compare them with INT32_MAX.
986  *
987  * @note If the caller is passing an invalid Position sample reference into this function,
988  * it is a fatal error, the function will not return.
989  */
990 //--------------------------------------------------------------------------------------------------
991 LE_SHARED le_result_t ifgen_le_gnss_GetLocation
992 (
993  le_msg_SessionRef_t _ifgen_sessionRef,
994  le_gnss_SampleRef_t positionSampleRef,
995  ///< [IN] Position sample's reference.
996  int32_t* latitudePtr,
997  ///< [OUT] WGS84 Latitude in degrees, positive North [resolution 1e-6].
998  int32_t* longitudePtr,
999  ///< [OUT] WGS84 Longitude in degrees, positive East [resolution 1e-6].
1000  int32_t* hAccuracyPtr
1001  ///< [OUT] Horizontal position's accuracy in meters [resolution 1e-2].
1002 );
1003 
1004 //--------------------------------------------------------------------------------------------------
1005 /**
1006  * Get the position sample's altitude.
1007  *
1008  * @return
1009  * - LE_FAULT Function failed to get the altitude. Invalid Position reference provided.
1010  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid (set to INT32_MAX).
1011  * - LE_OK Function succeeded.
1012  *
1013  * @note Altitude is in meters, above Mean Sea Level, with 3 decimal places (3047 = 3.047 meters).
1014  *
1015  * @note For a 2D position fix, the altitude will be indicated as invalid and set to INT32_MAX
1016  *
1017  * @note Vertical position accuracy is default set to meters with 1 decimal place (3047 = 3.0
1018  * meters). To change its accuracy, call the @c le_gnss_SetDataResolution() function. Vertical
1019  * position accuracy is set as data type and accuracy from 0 to 3 decimal place is set as
1020  * resolution.
1021  *
1022  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1023  * valid. Please compare them with INT32_MAX.
1024  *
1025  * @note If the caller is passing an invalid Position reference into this function,
1026  * it is a fatal error, the function will not return.
1027  *
1028  * @note altitudePtr, altitudeAccuracyPtr can be set to NULL if not needed.
1029  */
1030 //--------------------------------------------------------------------------------------------------
1031 LE_SHARED le_result_t ifgen_le_gnss_GetAltitude
1032 (
1033  le_msg_SessionRef_t _ifgen_sessionRef,
1034  le_gnss_SampleRef_t positionSampleRef,
1035  ///< [IN] Position sample's reference.
1036  int32_t* altitudePtr,
1037  ///< [OUT] Altitude in meters, above Mean Sea Level [resolution 1e-3].
1038  int32_t* vAccuracyPtr
1039  ///< [OUT] Vertical position's accuracy in meters.
1040 );
1041 
1042 //--------------------------------------------------------------------------------------------------
1043 /**
1044  * Get the position sample's time.
1045  *
1046  * @return
1047  * - LE_FAULT Function failed to get the time.
1048  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1049  * - LE_OK Function succeeded.
1050  *
1051  * @note If the caller is passing an invalid Position sample reference or null pointers into this
1052  * function, it is a fatal error, the function will not return.
1053  *
1054  */
1055 //--------------------------------------------------------------------------------------------------
1056 LE_SHARED le_result_t ifgen_le_gnss_GetTime
1057 (
1058  le_msg_SessionRef_t _ifgen_sessionRef,
1059  le_gnss_SampleRef_t positionSampleRef,
1060  ///< [IN] Position sample's reference.
1061  uint16_t* hoursPtr,
1062  ///< [OUT] UTC Hours into the day [range 0..23].
1063  uint16_t* minutesPtr,
1064  ///< [OUT] UTC Minutes into the hour [range 0..59].
1065  uint16_t* secondsPtr,
1066  ///< [OUT] UTC Seconds into the minute [range 0..59].
1067  uint16_t* millisecondsPtr
1068  ///< [OUT] UTC Milliseconds into the second [range 0..999].
1069 );
1070 
1071 //--------------------------------------------------------------------------------------------------
1072 /**
1073  * Get the position sample's GPS time.
1074  *
1075  * @return
1076  * - LE_FAULT Function failed to get the time.
1077  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1078  * - LE_OK Function succeeded.
1079  *
1080  * @note If the caller is passing an invalid Position sample reference or null pointers into this
1081  * function, it is a fatal error, the function will not return.
1082  */
1083 //--------------------------------------------------------------------------------------------------
1084 LE_SHARED le_result_t ifgen_le_gnss_GetGpsTime
1085 (
1086  le_msg_SessionRef_t _ifgen_sessionRef,
1087  le_gnss_SampleRef_t positionSampleRef,
1088  ///< [IN] Position sample's reference.
1089  uint32_t* gpsWeekPtr,
1090  ///< [OUT] GPS week number from midnight, Jan. 6, 1980.
1091  uint32_t* gpsTimeOfWeekPtr
1092  ///< [OUT] Amount of time in milliseconds into the GPS week.
1093 );
1094 
1095 //--------------------------------------------------------------------------------------------------
1096 /**
1097  * Get the position sample's epoch time.
1098  *
1099  * @return
1100  * - LE_FAULT Function failed to acquire the epoch time.
1101  * - LE_OK Function succeeded.
1102  * - LE_OUT_OF_RANGE The retrieved time is invalid (all fields are set to 0).
1103  *
1104  * @note The epoch time is the number of seconds elapsed since January 1, 1970
1105  * (midnight UTC/GMT), not counting leaps seconds.
1106  *
1107  * @note If the caller is passing an invalid position sample reference or a null pointer into this
1108  * function, it is a fatal error, the function will not return.
1109  */
1110 //--------------------------------------------------------------------------------------------------
1111 LE_SHARED le_result_t ifgen_le_gnss_GetEpochTime
1112 (
1113  le_msg_SessionRef_t _ifgen_sessionRef,
1114  le_gnss_SampleRef_t positionSampleRef,
1115  ///< [IN] Position sample's reference.
1116  uint64_t* millisecondsPtr
1117  ///< [OUT] Milliseconds since Jan. 1, 1970.
1118 );
1119 
1120 //--------------------------------------------------------------------------------------------------
1121 /**
1122  * Get the position sample's time accurary.
1123  *
1124  * @return
1125  * - LE_FAULT Function failed to get the time.
1126  * - LE_OUT_OF_RANGE The retrieved time accuracy is invalid (set to UINT16_MAX).
1127  * - LE_OK Function succeeded.
1128  *
1129  * @note If the caller is passing an invalid position sample reference or a null pointer into this
1130  * function, it is a fatal error, the function will not return.
1131  */
1132 //--------------------------------------------------------------------------------------------------
1133 LE_SHARED le_result_t ifgen_le_gnss_GetTimeAccuracy
1134 (
1135  le_msg_SessionRef_t _ifgen_sessionRef,
1136  le_gnss_SampleRef_t positionSampleRef,
1137  ///< [IN] Position sample's reference.
1138  uint32_t* timeAccuracyPtr
1139  ///< [OUT] Estimated time accuracy in nanoseconds
1140 );
1141 
1142 //--------------------------------------------------------------------------------------------------
1143 /**
1144  * Get the position sample's UTC leap seconds in advance
1145  *
1146  * @return
1147  * - LE_FAULT Function failed to get the leap seconds.
1148  * - LE_OUT_OF_RANGE The retrieved time accuracy is invalid (set to UINT8_MAX).
1149  * - LE_OK Function succeeded.
1150  *
1151  * @note The leap seconds in advance is the accumulated time in seconds since the start of GPS Epoch
1152  * time (Jan 6, 1980). This value has to be added to the UTC time (since Jan. 1, 1970)
1153  *
1154  * @note Insertion of each UTC leap second is usually decided about six months in advance by the
1155  * International Earth Rotation and Reference Systems Service (IERS).
1156  *
1157  * @note If the caller is passing an invalid position sample reference or a null pointer into this
1158  * function, it is a fatal error, the function will not return.
1159  *
1160  * @deprecated This function is deprecated, le_gnss_GetLeapSeconds should be used instead.
1161  */
1162 //--------------------------------------------------------------------------------------------------
1163 LE_SHARED le_result_t ifgen_le_gnss_GetGpsLeapSeconds
1164 (
1165  le_msg_SessionRef_t _ifgen_sessionRef,
1166  le_gnss_SampleRef_t positionSampleRef,
1167  ///< [IN] Position sample's reference.
1168  uint8_t* leapSecondsPtr
1169  ///< [OUT] UTC leap seconds in advance in seconds
1170 );
1171 
1172 //--------------------------------------------------------------------------------------------------
1173 /**
1174  * Get leap seconds information.
1175  *
1176  * @return
1177  * - LE_OK Function succeeded.
1178  * - LE_FAULT Function failed to get the data.
1179  * - LE_TIMEOUT Timeout occured.
1180  * - LE_UNSUPPORTED Not supported on this platform.
1181  *
1182  * @note Insertion of each UTC leap second is usually decided about six months in advance by the
1183  * International Earth Rotation and Reference Systems Service (IERS).
1184  *
1185  * @note If the caller is passing a null pointer into this function, it is considered a fatal
1186  * error and the function will not return.
1187  *
1188  * @note If the return value of a parameter is INT32_MAX/UINT64_MAX, the parameter is not valid.
1189  */
1190 //--------------------------------------------------------------------------------------------------
1191 LE_SHARED le_result_t ifgen_le_gnss_GetLeapSeconds
1192 (
1193  le_msg_SessionRef_t _ifgen_sessionRef,
1194  uint64_t* gpsTimePtr,
1195  ///< [OUT] The number of milliseconds of GPS time since midnight,
1196  ///< Jan. 6, 1980.
1197  int32_t* currentLeapSecondsPtr,
1198  ///< [OUT] Current UTC leap seconds value in milliseconds.
1199  uint64_t* changeEventTimePtr,
1200  ///< [OUT] The number of milliseconds since midnight, Jan. 6, 1980
1201  ///< to the next leap seconds change event.
1202  int32_t* nextLeapSecondsPtr
1203  ///< [OUT] UTC leap seconds value to be applied at the change
1204  ///< event time in milliseconds.
1205 );
1206 
1207 //--------------------------------------------------------------------------------------------------
1208 /**
1209  * Get the position sample's date.
1210  *
1211  * @return
1212  * - LE_FAULT Function failed to get the date.
1213  * - LE_OUT_OF_RANGE The retrieved date is invalid (all fields are set to 0).
1214  * - LE_OK Function succeeded.
1215  *
1216  * @note If the caller is passing an invalid Position sample reference or null pointers into this
1217  * function, it is a fatal error, the function will not return.
1218  */
1219 //--------------------------------------------------------------------------------------------------
1220 LE_SHARED le_result_t ifgen_le_gnss_GetDate
1221 (
1222  le_msg_SessionRef_t _ifgen_sessionRef,
1223  le_gnss_SampleRef_t positionSampleRef,
1224  ///< [IN] Position sample's reference.
1225  uint16_t* yearPtr,
1226  ///< [OUT] UTC Year A.D. [e.g. 2014].
1227  uint16_t* monthPtr,
1228  ///< [OUT] UTC Month into the year [range 1...12].
1229  uint16_t* dayPtr
1230  ///< [OUT] UTC Days into the month [range 1...31].
1231 );
1232 
1233 //--------------------------------------------------------------------------------------------------
1234 /**
1235  * Get the position sample's horizontal speed.
1236  *
1237  * - LE_FAULT Function failed to find the positionSample.
1238  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid (set to UINT32_MAX).
1239  * - LE_OK Function succeeded.
1240  *
1241  * @note hSpeedPtr, hSpeedAccuracyPtr can be set to NULL if not needed.
1242  *
1243  * @note Horizontal speed is in meters/second with 2 decimal places (3047 = 30.47 meters/second).
1244  *
1245  * @note Horizontal speed accuracy estimate is default set to meters/second with 1 decimal place
1246  * (304 = 30.4 meters/second). To change its accuracy, call the @c le_gnss_SetDataResolution()
1247  * function. Horizontal speed accuracy estimate is set as data type and accuracy from 0 to 3
1248  * decimal place is set as resolution.
1249  *
1250  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1251  * valid. Please compare them with UINT32_MAX.
1252  *
1253  * @note If the caller is passing an invalid Position sample reference into this function,
1254  * it is a fatal error, the function will not return.
1255  *
1256  * @warning The Horizontal speed accuracy is platform dependent. Please refer to
1257  * @ref platformConstraintsGnss_speedAccuracies section for full details.
1258  */
1259 //--------------------------------------------------------------------------------------------------
1260 LE_SHARED le_result_t ifgen_le_gnss_GetHorizontalSpeed
1261 (
1262  le_msg_SessionRef_t _ifgen_sessionRef,
1263  le_gnss_SampleRef_t positionSampleRef,
1264  ///< [IN] Position sample's reference.
1265  uint32_t* hspeedPtr,
1266  ///< [OUT] Horizontal speed in meters/second [resolution 1e-2].
1267  uint32_t* hspeedAccuracyPtr
1268  ///< [OUT] Horizontal speed's accuracy estimate in meters/second.
1269 );
1270 
1271 //--------------------------------------------------------------------------------------------------
1272 /**
1273  * Get the position sample's vertical speed.
1274  *
1275  * @return
1276  * - LE_FAULT The function failed to find the positionSample.
1277  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is not valid (set to INT32_MAX).
1278  * - LE_OK The function succeeded.
1279  *
1280  * @note vSpeedPtr, vSpeedAccuracyPtr can be set to NULL if not needed.
1281  *
1282  * @note For a 2D position Fix, the vertical speed will be indicated as invalid
1283  * and set to INT32_MAX.
1284  *
1285  * @note Vertical speed accuracy estimate is default set to meters/second with 1 decimal place
1286  * (304 = 30.4 meters/second). To change its accuracy, call the @c le_gnss_SetDataResolution()
1287  * function. Vertical speed accuracy estimate is set as data type and accuracy from 0 to 3
1288  * decimal place is set as resolution.
1289  *
1290  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1291  * valid. Please compare them with INT32_MAX.
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  * @warning The Vertical speed accuracy is platform dependent. Please refer to
1297  * @ref platformConstraintsGnss_speedAccuracies section for full details.
1298  */
1299 //--------------------------------------------------------------------------------------------------
1300 LE_SHARED le_result_t ifgen_le_gnss_GetVerticalSpeed
1301 (
1302  le_msg_SessionRef_t _ifgen_sessionRef,
1303  le_gnss_SampleRef_t positionSampleRef,
1304  ///< [IN] Position sample's reference.
1305  int32_t* vspeedPtr,
1306  ///< [OUT] Vertical speed in meters/second [resolution 1e-2],
1307  ///< positive up.
1308  int32_t* vspeedAccuracyPtr
1309  ///< [OUT] Vertical speed's accuracy estimate in meters/second.
1310 );
1311 
1312 //--------------------------------------------------------------------------------------------------
1313 /**
1314  * Get the position sample's direction. Direction of movement is the direction that the vehicle or
1315  * person is actually moving.
1316  *
1317  * @return
1318  * - LE_FAULT Function failed to find the positionSample.
1319  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid (set to UINT32_MAX).
1320  * - LE_OK Function succeeded.
1321  *
1322  * @note Direction and direction accuracy are given in degrees with 1 decimal place: 1755 = 175.5
1323  * degrees.
1324  * Direction ranges from 0 to 359.9 degrees, where 0 is True North.
1325  *
1326  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1327  * valid. Please compare them with UINT32_MAX.
1328  *
1329  * @note directionPtr, directionAccuracyPtr can be set to NULL if not needed.
1330  *
1331  * @note If the caller is passing an invalid Position sample reference into this function,
1332  * it is a fatal error, the function will not return.
1333  */
1334 //--------------------------------------------------------------------------------------------------
1335 LE_SHARED le_result_t ifgen_le_gnss_GetDirection
1336 (
1337  le_msg_SessionRef_t _ifgen_sessionRef,
1338  le_gnss_SampleRef_t positionSampleRef,
1339  ///< [IN] Position sample's reference.
1340  uint32_t* directionPtr,
1341  ///< [OUT] Direction in degrees [resolution 1e-1].
1342  ///< Range: 0 to 359.9, where 0 is True North
1343  uint32_t* directionAccuracyPtr
1344  ///< [OUT] Direction's accuracy estimate
1345  ///< in degrees [resolution 1e-1].
1346 );
1347 
1348 //--------------------------------------------------------------------------------------------------
1349 /**
1350  * Get the Satellites Vehicle information.
1351  *
1352  * @return
1353  * - LE_FAULT Function failed to find the positionSample.
1354  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid.
1355  * - LE_OK Function succeeded.
1356  *
1357  * @note satId[] can be set to 0 if that information list index is not configured, so
1358  * all satellite parameters (satConst[], satSnr[],satAzim[], satElev[]) are fixed to 0.
1359  *
1360  * @note For LE_OUT_OF_RANGE returned code, invalid value depends on field type:
1361  * UINT16_MAX for satId, LE_GNSS_SV_CONSTELLATION_UNDEFINED for satConst, false for satUsed,
1362  * UINT8_MAX for satSnr, UINT16_MAX for satAzim, UINT8_MAX for satElev.
1363  *
1364  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1365  * valid.
1366  *
1367  * @note If the caller is passing an invalid Position sample reference into this function,
1368  * it is a fatal error, the function will not return.
1369  */
1370 //--------------------------------------------------------------------------------------------------
1371 LE_SHARED le_result_t ifgen_le_gnss_GetSatellitesInfo
1372 (
1373  le_msg_SessionRef_t _ifgen_sessionRef,
1374  le_gnss_SampleRef_t positionSampleRef,
1375  ///< [IN] Position sample's reference.
1376  uint16_t* satIdPtr,
1377  ///< [OUT] Satellites in View ID number, referring
1378  ///< to NMEA standard.
1379  size_t* satIdSizePtr,
1380  ///< [INOUT]
1381  le_gnss_Constellation_t* satConstPtr,
1382  ///< [OUT] GNSS constellation type.
1383  size_t* satConstSizePtr,
1384  ///< [INOUT]
1385  bool* satUsedPtr,
1386  ///< [OUT] TRUE if satellite in View Used
1387  ///< for Navigation.
1388  size_t* satUsedSizePtr,
1389  ///< [INOUT]
1390  uint8_t* satSnrPtr,
1391  ///< [OUT] Satellites in View Signal To
1392  ///< Noise Ratio (C/No) [dBHz].
1393  size_t* satSnrSizePtr,
1394  ///< [INOUT]
1395  uint16_t* satAzimPtr,
1396  ///< [OUT] Satellites in View Azimuth [degrees].
1397  ///< Range: 0 to 360
1398  ///< If Azimuth angle is currently unknown,
1399  ///< the value is set to UINT16_MAX.
1400  size_t* satAzimSizePtr,
1401  ///< [INOUT]
1402  uint8_t* satElevPtr,
1403  ///< [OUT] Satellites in View Elevation [degrees].
1404  ///< Range: 0 to 90
1405  ///< If Elevation angle is currently unknown,
1406  ///< the value is set to UINT8_MAX.
1407  size_t* satElevSizePtr
1408  ///< [INOUT]
1409 );
1410 
1411 //--------------------------------------------------------------------------------------------------
1412 /**
1413  * Get the SBAS constellation category given the SBAS satellite number ID.
1414  *
1415  */
1416 //--------------------------------------------------------------------------------------------------
1417 LE_SHARED le_gnss_SbasConstellationCategory_t ifgen_le_gnss_GetSbasConstellationCategory
1418 (
1419  le_msg_SessionRef_t _ifgen_sessionRef,
1420  uint16_t satId
1421  ///< [IN] SBAS satellite number ID, referring to NMEA standard.
1422 );
1423 
1424 //--------------------------------------------------------------------------------------------------
1425 /**
1426  * Get the Satellites Vehicle status.
1427  *
1428  * @return
1429  * - LE_FAULT Function failed to find the positionSample.
1430  * - LE_OUT_OF_RANGE At least one of the retrieved parameters is invalid (set to UINT8_MAX).
1431  * - LE_OK Function succeeded.
1432  *
1433  * @note In case the function returns LE_OUT_OF_RANGE, some of the retrieved parameters may be
1434  * valid. Please compare them with UINT8_MAX.
1435  *
1436  * @note If the caller is passing an invalid Position sample reference into this function,
1437  * it is a fatal error, the function will not return.
1438  */
1439 //--------------------------------------------------------------------------------------------------
1440 LE_SHARED le_result_t ifgen_le_gnss_GetSatellitesStatus
1441 (
1442  le_msg_SessionRef_t _ifgen_sessionRef,
1443  le_gnss_SampleRef_t positionSampleRef,
1444  ///< [IN] Position sample's reference.
1445  uint8_t* satsInViewCountPtr,
1446  ///< [OUT] Number of satellites expected to be in view.
1447  uint8_t* satsTrackingCountPtr,
1448  ///< [OUT] Number of satellites in view, when tracking.
1449  uint8_t* satsUsedCountPtr
1450  ///< [OUT] Number of satellites in view used for Navigation.
1451 );
1452 
1453 //--------------------------------------------------------------------------------------------------
1454 /**
1455  * Get the DOP parameter (Dilution Of Precision) for the fixed position.
1456  *
1457  * @return
1458  * - LE_FAULT Function failed to find the DOP value.
1459  * - LE_OUT_OF_RANGE The retrieved parameter is invalid (set to UINT16_MAX).
1460  * - LE_OK Function succeeded.
1461  *
1462  * @note The DOP value is given with 3 decimal places by default like: DOP value 2200 = 2.200
1463  * The resolution can be modified by calling the @c le_gnss_SetDopResolution() function.
1464  *
1465  * @note If the caller is passing an invalid Position sample reference into this function,
1466  * it is a fatal error, the function will not return.
1467  */
1468 //--------------------------------------------------------------------------------------------------
1469 LE_SHARED le_result_t ifgen_le_gnss_GetDilutionOfPrecision
1470 (
1471  le_msg_SessionRef_t _ifgen_sessionRef,
1472  le_gnss_SampleRef_t positionSampleRef,
1473  ///< [IN] Position sample's reference.
1474  le_gnss_DopType_t dopType,
1475  ///< [IN] Dilution of Precision type [range 0..5].
1476  uint16_t* dopPtr
1477  ///< [OUT] Dilution of Precision corresponding to the dopType
1478 );
1479 
1480 //--------------------------------------------------------------------------------------------------
1481 /**
1482  * Get the position sample's altitude with respect to the WGS-84 ellipsoid
1483  *
1484  * @return
1485  * - LE_FAULT Function failed to get the altitude.
1486  * - LE_OUT_OF_RANGE The altitudeOnWgs84 is invalid (set to INT32_MAX).
1487  * - LE_OK Function succeeded.
1488  *
1489  * @note altitudeOnWgs84 is in meters, with respect to the WGS-84 ellipsoid with 3 decimal
1490  * places (3047 = 3.047 meters).
1491  *
1492  * @note For a 2D position fix, the altitude with respect to the WGS-84 ellipsoid will be indicated
1493  * as invalid and set to INT32_MAX.
1494  *
1495  * @note If the caller is passing an invalid Position reference or a null pointer into this
1496  * function, it is a fatal error, the function will not return.
1497  */
1498 //--------------------------------------------------------------------------------------------------
1499 LE_SHARED le_result_t ifgen_le_gnss_GetAltitudeOnWgs84
1500 (
1501  le_msg_SessionRef_t _ifgen_sessionRef,
1502  le_gnss_SampleRef_t positionSampleRef,
1503  ///< [IN] Position sample's reference.
1504  int32_t* altitudeOnWgs84Ptr
1505  ///< [OUT] Altitude in meters, between WGS-84 earth ellipsoid
1506  ///< and mean sea level [resolution 1e-3].
1507 );
1508 
1509 //--------------------------------------------------------------------------------------------------
1510 /**
1511  * Get the position sample's magnetic deviation. It is the difference between the bearing to
1512  * true north and the bearing shown on a magnetic compass. The deviation is positive when the
1513  * magnetic north is east of true north.
1514  *
1515  * @return
1516  * - LE_FAULT Function failed to find the positionSample.
1517  * - LE_OUT_OF_RANGE The magneticDeviation is invalid (set to INT32_MAX).
1518  * - LE_OK Function succeeded.
1519  *
1520  * @note magneticDeviation is in degrees, with 1 decimal places (47 = 4.7 degree).
1521  *
1522  * @note If the caller is passing an invalid Position sample reference into this function,
1523  * it is a fatal error, the function will not return.
1524  */
1525 //--------------------------------------------------------------------------------------------------
1526 LE_SHARED le_result_t ifgen_le_gnss_GetMagneticDeviation
1527 (
1528  le_msg_SessionRef_t _ifgen_sessionRef,
1529  le_gnss_SampleRef_t positionSampleRef,
1530  ///< [IN] Position sample's reference.
1531  int32_t* magneticDeviationPtr
1532  ///< [OUT] MagneticDeviation in degrees [resolution 1e-1].
1533 );
1534 
1535 //--------------------------------------------------------------------------------------------------
1536 /**
1537  * This function gets the last updated position sample object reference.
1538  *
1539  * @return A reference to last Position's sample.
1540  *
1541  * @note
1542  * On failure, the process exits, so you don't have to worry about checking the returned
1543  * reference for validity.
1544  */
1545 //--------------------------------------------------------------------------------------------------
1546 LE_SHARED le_gnss_SampleRef_t ifgen_le_gnss_GetLastSampleRef
1547 (
1548  le_msg_SessionRef_t _ifgen_sessionRef
1549 );
1550 
1551 //--------------------------------------------------------------------------------------------------
1552 /**
1553  * This function must be called to release the position sample.
1554  *
1555  * @note If the caller is passing an invalid Position sample reference into this function,
1556  * it is a fatal error, the function will not return.
1557  */
1558 //--------------------------------------------------------------------------------------------------
1559 LE_SHARED void ifgen_le_gnss_ReleaseSampleRef
1560 (
1561  le_msg_SessionRef_t _ifgen_sessionRef,
1562  le_gnss_SampleRef_t positionSampleRef
1563  ///< [IN] Position sample's reference.
1564 );
1565 
1566 //--------------------------------------------------------------------------------------------------
1567 /**
1568  * This function sets the SUPL Assisted-GNSS mode.
1569  *
1570  * @return
1571  * - LE_OK on success
1572  * - LE_FAULT on failure
1573  * - LE_UNSUPPORTED request not supported
1574  * - LE_TIMEOUT a time-out occurred
1575  *
1576  * @warning The settings are platform dependent. Please refer to
1577  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1578  */
1579 //--------------------------------------------------------------------------------------------------
1580 LE_SHARED le_result_t ifgen_le_gnss_SetSuplAssistedMode
1581 (
1582  le_msg_SessionRef_t _ifgen_sessionRef,
1583  le_gnss_AssistedMode_t assistedMode
1584  ///< [IN] Assisted-GNSS mode.
1585 );
1586 
1587 //--------------------------------------------------------------------------------------------------
1588 /**
1589  * This function gets the SUPL Assisted-GNSS mode.
1590  *
1591  * @return
1592  * - LE_OK on success
1593  * - LE_FAULT on failure
1594  *
1595  * @note If the caller is passing a null pointer into this function, it is a fatal error, the
1596  * function will not return.
1597  */
1598 //--------------------------------------------------------------------------------------------------
1599 LE_SHARED le_result_t ifgen_le_gnss_GetSuplAssistedMode
1600 (
1601  le_msg_SessionRef_t _ifgen_sessionRef,
1602  le_gnss_AssistedMode_t* assistedModePtr
1603  ///< [OUT] Assisted-GNSS mode.
1604 );
1605 
1606 //--------------------------------------------------------------------------------------------------
1607 /**
1608  * This function sets the SUPL server URL.
1609  * That server URL is a NULL-terminated string with a maximum string length (including NULL
1610  * terminator) equal to 256. Optionally the port number is specified after a colon.
1611  *
1612  * @return
1613  * - LE_OK on success
1614  * - LE_FAULT on failure
1615  * - LE_BUSY service is busy
1616  * - LE_TIMEOUT a time-out occurred
1617  *
1618  * @note If the SUPL server URL size is bigger than the maximum string length (including NULL
1619  * terminator) size, it is a fatal error, the function will not return.
1620  *
1621  * @warning The settings are platform dependent. Please refer to
1622  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1623  */
1624 //--------------------------------------------------------------------------------------------------
1625 LE_SHARED le_result_t ifgen_le_gnss_SetSuplServerUrl
1626 (
1627  le_msg_SessionRef_t _ifgen_sessionRef,
1628  const char* LE_NONNULL suplServerUrl
1629  ///< [IN] SUPL server URL.
1630 );
1631 
1632 //--------------------------------------------------------------------------------------------------
1633 /**
1634  * This function injects the SUPL certificate to be used in A-GNSS sessions. Certificates must
1635  * be encoded in DER. Other certificate encryptions (e.g., PEM, CER and CRT)
1636  * aren't supported.
1637  *
1638  * @return
1639  * - LE_OK on success
1640  * - LE_BAD_PARAMETER on invalid parameter
1641  * - LE_FAULT on failure
1642  * - LE_BUSY service is busy
1643  * - LE_TIMEOUT a time-out occurred
1644  *
1645  * @note If the SUPL certificate size is bigger than the Maximum SUPL certificate size,
1646  * it is a fatal error, the function will not return.
1647  */
1648 //--------------------------------------------------------------------------------------------------
1649 LE_SHARED le_result_t ifgen_le_gnss_InjectSuplCertificate
1650 (
1651  le_msg_SessionRef_t _ifgen_sessionRef,
1652  uint8_t suplCertificateId,
1653  ///< [IN] ID of the SUPL certificate.
1654  ///< Certificate ID range is 0 to 9
1655  uint16_t suplCertificateLen,
1656  ///< [IN] SUPL certificate size in Bytes.
1657  const char* LE_NONNULL suplCertificate
1658  ///< [IN] SUPL certificate contents.
1659 );
1660 
1661 //--------------------------------------------------------------------------------------------------
1662 /**
1663  * This function deletes the SUPL certificate.
1664  *
1665  * @return
1666  * - LE_OK on success
1667  * - LE_BAD_PARAMETER on invalid parameter
1668  * - LE_FAULT on failure
1669  * - LE_BUSY service is busy
1670  * - LE_TIMEOUT a time-out occurred
1671  */
1672 //--------------------------------------------------------------------------------------------------
1673 LE_SHARED le_result_t ifgen_le_gnss_DeleteSuplCertificate
1674 (
1675  le_msg_SessionRef_t _ifgen_sessionRef,
1676  uint8_t suplCertificateId
1677  ///< [IN] ID of the SUPL certificate.
1678  ///< Certificate ID range is 0 to 9
1679 );
1680 
1681 //--------------------------------------------------------------------------------------------------
1682 /**
1683  * This function sets the enabled NMEA sentences using a bit mask.
1684  *
1685  * @return
1686  * - LE_OK Success
1687  * - LE_BAD_PARAMETER Bit mask exceeds the maximal value
1688  * - LE_FAULT Failure
1689  * - LE_BUSY Service is busy
1690  * - LE_TIMEOUT Timeout occurred
1691  * - LE_NOT_PERMITTED GNSS device is not in "ready" state
1692  *
1693  * @warning This function may be subject to limitations depending on the platform. Please refer to
1694  * the @ref platformConstraintsGnss page.
1695  *
1696  * @note Some NMEA sentences are unsupported depending on the platform. Please refer to
1697  * @ref platformConstraintsGnss_nmeaMask section for full details. Setting an unsuported NMEA
1698  * sentence won't report an error.
1699  *
1700  * @warning The settings are platform dependent. Please refer to
1701  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1702  */
1703 //--------------------------------------------------------------------------------------------------
1704 LE_SHARED le_result_t ifgen_le_gnss_SetNmeaSentences
1705 (
1706  le_msg_SessionRef_t _ifgen_sessionRef,
1707  le_gnss_NmeaBitMask_t nmeaMask
1708  ///< [IN] Bit mask for enabled NMEA sentences.
1709 );
1710 
1711 //--------------------------------------------------------------------------------------------------
1712 /**
1713  * This function gets the bit mask for the enabled NMEA sentences.
1714  *
1715  * @return
1716  * - LE_OK Success
1717  * - LE_FAULT Failure
1718  * - LE_BUSY Service is busy
1719  * - LE_TIMEOUT Timeout occurred
1720  * - LE_NOT_PERMITTED GNSS device is not in "ready" state
1721  *
1722  * @note If the caller is passing a null pointer to this function, it is a fatal error, the
1723  * function will not return.
1724  *
1725  * @note Some NMEA sentences are unsupported depending on the platform. Please refer to
1726  * @ref platformConstraintsGnss_nmeaMask section for full details. The bit mask for an unset
1727  * or unsupported NMEA sentence is zero.
1728  */
1729 //--------------------------------------------------------------------------------------------------
1730 LE_SHARED le_result_t ifgen_le_gnss_GetNmeaSentences
1731 (
1732  le_msg_SessionRef_t _ifgen_sessionRef,
1733  le_gnss_NmeaBitMask_t* nmeaMaskPtrPtr
1734  ///< [OUT] Bit mask for enabled NMEA sentences.
1735 );
1736 
1737 //--------------------------------------------------------------------------------------------------
1738 /**
1739  * This function returns the status of the GNSS device.
1740  *
1741  */
1742 //--------------------------------------------------------------------------------------------------
1743 LE_SHARED le_gnss_State_t ifgen_le_gnss_GetState
1744 (
1745  le_msg_SessionRef_t _ifgen_sessionRef
1746 );
1747 
1748 //--------------------------------------------------------------------------------------------------
1749 /**
1750  * This function sets the GNSS minimum elevation.
1751  *
1752  * @return
1753  * - LE_OK on success
1754  * - LE_FAULT on failure
1755  * - LE_OUT_OF_RANGE if the minimum elevation is above range
1756  * - LE_UNSUPPORTED request not supported
1757  *
1758  * @warning The settings are platform dependent. Please refer to
1759  * @ref platformConstraintsGnss_SettingConfiguration section for full details.
1760  */
1761 //--------------------------------------------------------------------------------------------------
1762 LE_SHARED le_result_t ifgen_le_gnss_SetMinElevation
1763 (
1764  le_msg_SessionRef_t _ifgen_sessionRef,
1765  uint8_t minElevation
1766  ///< [IN] Minimum elevation in degrees [range 0..90].
1767 );
1768 
1769 //--------------------------------------------------------------------------------------------------
1770 /**
1771  * This function gets the GNSS minimum elevation.
1772  *
1773  * @return
1774  * - LE_OK on success
1775  * - LE_FAULT on failure
1776  * - LE_UNSUPPORTED request not supported
1777  *
1778  * @note If the caller is passing n null pointer to this function, it is a fatal error, the
1779  * function will not return.
1780  */
1781 //--------------------------------------------------------------------------------------------------
1782 LE_SHARED le_result_t ifgen_le_gnss_GetMinElevation
1783 (
1784  le_msg_SessionRef_t _ifgen_sessionRef,
1785  uint8_t* minElevationPtrPtr
1786  ///< [OUT] Minimum elevation in degrees [range 0..90].
1787 );
1788 
1789 //--------------------------------------------------------------------------------------------------
1790 /**
1791  * Set the resolution for the DOP parameters
1792  *
1793  * @return LE_OK Function succeeded.
1794  * @return LE_BAD_PARAMETER Invalid parameter provided.
1795  * @return LE_FAULT Function failed.
1796  *
1797  * @note The function sets the same resolution to all DOP values returned by
1798  * le_gnss_GetDilutionOfPrecision() API. The resolution setting takes effect immediately.
1799  *
1800  * @note The resolution setting is done per client session.
1801  */
1802 //--------------------------------------------------------------------------------------------------
1803 LE_SHARED le_result_t ifgen_le_gnss_SetDopResolution
1804 (
1805  le_msg_SessionRef_t _ifgen_sessionRef,
1806  le_gnss_Resolution_t resolution
1807  ///< [IN] Resolution.
1808 );
1809 
1810 //--------------------------------------------------------------------------------------------------
1811 /**
1812  * Set the resolution for the specific type of data
1813  *
1814  * @return LE_OK Function succeeded.
1815  * @return LE_BAD_PARAMETER Invalid parameter provided.
1816  * @return LE_FAULT Function failed.
1817  *
1818  * @note The resolution setting takes effect immediately and is not persistent to reset.
1819  *
1820  * @note The resolution setting is done per client session.
1821  */
1822 //--------------------------------------------------------------------------------------------------
1823 LE_SHARED le_result_t ifgen_le_gnss_SetDataResolution
1824 (
1825  le_msg_SessionRef_t _ifgen_sessionRef,
1826  le_gnss_DataType_t dataType,
1827  ///< [IN] Data type.
1828  le_gnss_Resolution_t resolution
1829  ///< [IN] Resolution.
1830 );
1831 
1832 //--------------------------------------------------------------------------------------------------
1833 /**
1834  * This function converts a location data parameter from/to multi-coordinate system
1835  *
1836  * @return
1837  * - LE_OK on success
1838  * - LE_FAULT on failure
1839  * - LE_BAD_PARAMETER Invalid parameter provided.
1840  * - LE_UNSUPPORTED request not supported
1841  *
1842  * @note The resolution of location data parameter remains unchanged after the conversion.
1843  */
1844 //--------------------------------------------------------------------------------------------------
1845 LE_SHARED le_result_t ifgen_le_gnss_ConvertDataCoordinateSystem
1846 (
1847  le_msg_SessionRef_t _ifgen_sessionRef,
1848  le_gnss_CoordinateSystem_t coordinateSrc,
1849  ///< [IN] Coordinate system to convert from.
1850  le_gnss_CoordinateSystem_t coordinateDst,
1851  ///< [IN] Coordinate system to convert to.
1852  le_gnss_LocationDataType_t locationDataType,
1853  ///< [IN] Type of location data to convert.
1854  int64_t locationDataSrc,
1855  ///< [IN] Data to convert.
1856  int64_t* locationDataDstPtr
1857  ///< [OUT] Converted Data.
1858 );
1859 
1860 //--------------------------------------------------------------------------------------------------
1861 /**
1862  * Enables the EXT_GPS_LNA_EN signal
1863  *
1864  * @return LE_OK Function succeeded.
1865  * @return LE_NOT_PERMITTED GNSS is not in the ready state
1866  * @return LE_UNSUPPORTED Function not supported on this platform
1867  *
1868  * @note The EXT_GPS_LNA_EN signal will be set high when the GNSS state is active
1869  */
1870 //--------------------------------------------------------------------------------------------------
1871 LE_SHARED le_result_t ifgen_le_gnss_EnableExternalLna
1872 (
1873  le_msg_SessionRef_t _ifgen_sessionRef
1874 );
1875 
1876 //--------------------------------------------------------------------------------------------------
1877 /**
1878  * Disables the EXT_GPS_LNA_EN signal
1879  *
1880  * @return LE_OK Function succeeded.
1881  * @return LE_NOT_PERMITTED GNSS is not in the ready state
1882  * @return LE_UNSUPPORTED Function not supported on this platform
1883  *
1884  */
1885 //--------------------------------------------------------------------------------------------------
1886 LE_SHARED le_result_t ifgen_le_gnss_DisableExternalLna
1887 (
1888  le_msg_SessionRef_t _ifgen_sessionRef
1889 );
1890 
1891 //--------------------------------------------------------------------------------------------------
1892 /**
1893  * Read the EXT_GPS_LNA_EN status
1894  *
1895  * @return LE_OK Function succeeded.
1896  * @return LE_NOT_PERMITTED GNSS is not in the ready state
1897  * @return LE_UNSUPPORTED Function not supported on this platform
1898  *
1899  */
1900 //--------------------------------------------------------------------------------------------------
1901 LE_SHARED le_result_t ifgen_le_gnss_GetExternalLna
1902 (
1903  le_msg_SessionRef_t _ifgen_sessionRef,
1904  uint8_t* lnaStatusPtr
1905  ///< [OUT] GNSS LNA Status
1906 );
1907 
1908 //--------------------------------------------------------------------------------------------------
1909 /**
1910  * Returns a bitmask containing all NMEA sentences supported on this platform
1911  *
1912  * @return LE_OK Function succeeded.
1913  * @return LE_UNSUPPORTED Function not supported on this platform.
1914  */
1915 //--------------------------------------------------------------------------------------------------
1916 LE_SHARED le_result_t ifgen_le_gnss_GetSupportedNmeaSentences
1917 (
1918  le_msg_SessionRef_t _ifgen_sessionRef,
1919  le_gnss_NmeaBitMask_t* NmeaMaskPtr
1920  ///< [OUT] Supported NMEA sentences
1921 );
1922 
1923 //--------------------------------------------------------------------------------------------------
1924 /**
1925  * Returns a bitmask containing all satellite constellations supported on this platform
1926  *
1927  * @return LE_OK Function succeeded.
1928  * @return LE_UNSUPPORTED Function not supported on this platform.
1929  */
1930 //--------------------------------------------------------------------------------------------------
1931 LE_SHARED le_result_t ifgen_le_gnss_GetSupportedConstellations
1932 (
1933  le_msg_SessionRef_t _ifgen_sessionRef,
1934  le_gnss_ConstellationBitMask_t* constellationMaskPtr
1935  ///< [OUT] Supported GNSS constellations
1936 );
1937 
1938 //--------------------------------------------------------------------------------------------------
1939 /**
1940  * Get the minimum NMEA rate supported on this platform
1941  *
1942  * @return LE_OK Function succeeded.
1943  * @return LE_UNSUPPORTED Function not supported on this platform
1944  */
1945 //--------------------------------------------------------------------------------------------------
1946 LE_SHARED le_result_t ifgen_le_gnss_GetMinNmeaRate
1947 (
1948  le_msg_SessionRef_t _ifgen_sessionRef,
1949  uint32_t* minNmeaRatePtr
1950  ///< [OUT] Minimum NMEA rate in milliseconds.
1951 );
1952 
1953 //--------------------------------------------------------------------------------------------------
1954 /**
1955  * Get the maximum NMEA rate supported on this platform
1956  *
1957  * @return LE_OK Function succeeded.
1958  * @return LE_UNSUPPORTED Function not supported on this platform
1959  */
1960 //--------------------------------------------------------------------------------------------------
1961 LE_SHARED le_result_t ifgen_le_gnss_GetMaxNmeaRate
1962 (
1963  le_msg_SessionRef_t _ifgen_sessionRef,
1964  uint32_t* maxNmeaRatePtr
1965  ///< [OUT] Maximum NMEA rate in milliseconds.
1966 );
1967 /** @} **/
1968 #endif // LE_GNSS_COMMON_H_INCLUDE_GUARD
Resolution of 0 decimal place.
Definition: le_gnss_common.h:176
le_gnss_FixState_t
Definition: le_gnss_common.h:155
Unknown start.
Definition: le_gnss_common.h:437
Definition: le_gnss_common.h:262
GNSS constellation field not defined.
Definition: le_gnss_common.h:245
Cold start.
Definition: le_gnss_common.h:433
#define LE_SHARED
Definition: le_basics.h:300
Maximum value.
Definition: le_gnss_common.h:397
The GNSS fix position is not fixed.
Definition: le_gnss_common.h:157
le_result_t
Definition: le_basics.h:46
Worldwide area.
Definition: le_gnss_common.h:320
Unknown resolution.
Definition: le_gnss_common.h:184
Unknown data type.
Definition: le_gnss_common.h:203
2-Dimensional position fix.
Definition: le_gnss_common.h:159
le_gnss_Constellation_t
Definition: le_gnss_common.h:243
Definition: le_gnss_common.h:222
Latitude data position.
Definition: le_gnss_common.h:410
Factory start.
Definition: le_gnss_common.h:435
Vertical speed accuracy data.
Definition: le_gnss_common.h:199
le_gnss_DopType_t
Definition: le_gnss_common.h:293
Resolution of 3 decimal places.
Definition: le_gnss_common.h:182
Definition: le_gnss_common.h:225
The GNSS device is active.
Definition: le_gnss_common.h:140
Definition: le_gnss_common.h:253
Maximum value.
Definition: le_gnss_common.h:416
Definition: le_gnss_common.h:219
Altitude data position.
Definition: le_gnss_common.h:414
le_gnss_CoordinateSystem_t
Definition: le_gnss_common.h:391
The GNSS device is ready.
Definition: le_gnss_common.h:138
Standalone mode.
Definition: le_gnss_common.h:278
Definition: le_gnss_common.h:231
Coordinate system WGS84.
Definition: le_gnss_common.h:393
le_gnss_StartMode_t
Definition: le_gnss_common.h:427
Longitude data position.
Definition: le_gnss_common.h:412
le_gnss_SbasConstellationCategory_t
Definition: le_gnss_common.h:214
Resolution of 2 decimal places.
Definition: le_gnss_common.h:180
Vertical dilution of precision.
Definition: le_gnss_common.h:299
The GNSS device is disabled.
Definition: le_gnss_common.h:142
le_gnss_ConstellationArea_t
Definition: le_gnss_common.h:316
Outside US area.
Definition: le_gnss_common.h:322
Warm start.
Definition: le_gnss_common.h:431
Resolution of 1 decimal place.
Definition: le_gnss_common.h:178
3-Dimensional position fix.
Definition: le_gnss_common.h:161
Vertical accuracy data.
Definition: le_gnss_common.h:197
le_gnss_LocationDataType_t
Definition: le_gnss_common.h:408
void(* le_gnss_PositionHandlerFunc_t)(le_gnss_SampleRef_t positionSampleRef, void *contextPtr)
Definition: le_gnss_common.h:458
Definition: le_gnss_common.h:259
Geometric dilution of precision.
Definition: le_gnss_common.h:301
le_gnss_DataType_t
Definition: le_gnss_common.h:195
struct le_msg_Session * le_msg_SessionRef_t
Definition: le_messaging.h:860
Coordinate system PZ90.
Definition: le_gnss_common.h:395
Definition: le_gnss_common.h:250
Definition: le_gnss_common.h:216
MS-Assisted mode.
Definition: le_gnss_common.h:282
struct le_gnss_PositionHandler * le_gnss_PositionHandlerRef_t
Definition: le_gnss_common.h:448
Estimated (i.e. forward predicted) position fix.
Definition: le_gnss_common.h:163
Definition: le_gnss_common.h:256
le_gnss_AssistedMode_t
Definition: le_gnss_common.h:276
Maximum value.
Definition: le_gnss_common.h:265
struct le_gnss_Sample * le_gnss_SampleRef_t
Definition: le_gnss_common.h:126
le_gnss_Resolution_t
Definition: le_gnss_common.h:174
Definition: le_gnss_common.h:247
Time dilution of precision.
Definition: le_gnss_common.h:303
Hot start.
Definition: le_gnss_common.h:429
Horizontal dilution of precision.
Definition: le_gnss_common.h:297
le_gnss_State_t
Definition: le_gnss_common.h:134
MS-Based mode.
Definition: le_gnss_common.h:280
Horizontal speed accuracy data.
Definition: le_gnss_common.h:201
Unset area.
Definition: le_gnss_common.h:318
Position dilution of precision.
Definition: le_gnss_common.h:295
Do not use.
Definition: le_gnss_common.h:144
The GNSS device is not initialized.
Definition: le_gnss_common.h:136
Definition: le_gnss_common.h:228