le_ecall_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_ecall_common.h
12  *
13  * Type definitions for le_ecall.
14  *
15  */
16 #ifndef LE_ECALL_COMMON_H_INCLUDE_GUARD
17 #define LE_ECALL_COMMON_H_INCLUDE_GUARD
18 
19 
20 #include "legato.h"
21 
22 // Interface specific includes
23 #include "le_mdmDefs_common.h"
24 #include "le_mcc_common.h"
25 
26 #define IFGEN_LE_ECALL_PROTOCOL_ID "930cb22e230e6b6eb5376314828fdf9f"
27 #define IFGEN_LE_ECALL_MSG_SIZE 156
28 /** @addtogroup le_ecall
29  * @{ **/
30 
31 
32 //--------------------------------------------------------------------------------------------------
33 /**
34  * MSD message length in bytes.
35  */
36 //--------------------------------------------------------------------------------------------------
37 #define LE_ECALL_MSD_MAX_LEN 140
38 
39 //--------------------------------------------------------------------------------------------------
40 /**
41  * Vehicle Identification Number (VIN) string LENGTH. (without nulltermination)
42  */
43 //--------------------------------------------------------------------------------------------------
44 #define LE_ECALL_VIN_MAX_LEN 17
45 
46 //--------------------------------------------------------------------------------------------------
47 /**
48  * Vehicle Identification Number (VIN) string BYTES. One extra byte is added for the null
49  * character.
50  */
51 //--------------------------------------------------------------------------------------------------
52 #define LE_ECALL_VIN_MAX_BYTES 18
53 
54 //--------------------------------------------------------------------------------------------------
55 /**
56  * Reference returned by Create function and used by other functions
57  */
58 //--------------------------------------------------------------------------------------------------
59 typedef struct le_ecall_Call* le_ecall_CallRef_t;
60 
61 
62 //--------------------------------------------------------------------------------------------------
63 /**
64  * Configured operation modes.
65  */
66 //--------------------------------------------------------------------------------------------------
67 typedef enum
68 {
70  ///< Normal mode.
72  ///< eCall only mode according to U/SIM operation mode or forced
73  ///< by application through the le_ecall_ForceOnlyMode() function.
75  ///< Persistent eCall only mode.
76 }
78 
79 
80 //--------------------------------------------------------------------------------------------------
81 /**
82  * Configure which standard to follow for the eCall, either PAN European eCall or ERA GLONASS.
83  */
84 //--------------------------------------------------------------------------------------------------
85 typedef enum
86 {
88  ///< PAN-EUROPEAN standard
90  ///< ERA GLONASS standard
91 }
93 
94 
95 //--------------------------------------------------------------------------------------------------
96 /**
97  * eCall session states.
98  */
99 //--------------------------------------------------------------------------------------------------
100 typedef enum
101 {
103  ///< Unknown state.
105  ///< eCall session started.
107  ///< Emergency call is established.
109  ///< Emergency call is disconnected.
111  ///< Waiting for PSAP start indication.
113  ///< PSAP start indication received.
115  ///< MSD transmission is started.
117  ///< LL-NACK received.
119  ///< LL-ACK received.
121  ///< MSD transmission is complete.
123  ///< MSD transmission has failed.
125  ///< AL-ACK received.
127  ///< AL-ACK clear-down received.
129  ///< Auto answer timer has expired after eCall session
130  ///< stopped by PSAP, or le_ecall_End() has been called by IVS.
132  ///< eCall session has lost synchronization and starts over.
134  ///< eCall session completed. The modem successfully completed
135  ///< the MSD transmission and received two AL-ACKs (positive).
136  ///< Can now switch to voice path.
138  ///< Unsuccessful eCall session.
140  ///< End of the redial period.
142  ///< Timeout for Timer T2 (see CEN-EN 16062, annex A)
144  ///< Timeout for Timer T3 (see CEN-EN 16062, annex A)
146  ///< Timeout for Timer T5 (see CEN-EN 16062, annex A)
148  ///< Timeout for Timer T6 (see CEN-EN 16062, annex A)
150  ///< Timeout for Timer T7 (see CEN-EN 16062, annex A)
152  ///< Timeout for Timer T9 (see CEN-EN 16062, annex A)
154  ///< Timeout for Timer T10 (see CEN-EN 16062, annex A)
155 }
157 
158 
159 //--------------------------------------------------------------------------------------------------
160 /**
161  * eCall MSD transmission mode.
162  */
163 //--------------------------------------------------------------------------------------------------
164 typedef enum
165 {
167  ///< Pull mode (modem/host waits for MSD request from PSAP to send MSD).
169  ///< Push mode (modem/host sends MSD to PSAP right after eCall is connected).
170 }
172 
173 
174 //--------------------------------------------------------------------------------------------------
175 /**
176  * eCall MSD vehicle type
177  */
178 //--------------------------------------------------------------------------------------------------
179 typedef enum
180 {
182  ///< Passenger vehicle (Class M1)
184  ///< Buses and coaches (Class M2)
186  ///< Buses and coaches (Class M3)
188  ///< Light commercial vehicles (Class N1)
190  ///< Heavy duty vehicles (Class N2)
192  ///< Heavy duty vehicles (Class N3)
194  ///< Motorcycles (Class L1e)
196  ///< Motorcycles (Class L2e)
198  ///< Motorcycles (Class L3e)
200  ///< Motorcycles (Class L4e)
202  ///< Motorcycles (Class L5e)
204  ///< Motorcycles (Class L6e)
206  ///< Motorcycles (Class L7e)
207 }
209 
210 
211 //--------------------------------------------------------------------------------------------------
212 /**
213  * Propulsion type Bit Mask
214  */
215 //--------------------------------------------------------------------------------------------------/// Gasoline propulsion)
216 #define LE_ECALL_PROPULSION_TYPE_GASOLINE 0x1/// Diesel propulsion
217 #define LE_ECALL_PROPULSION_TYPE_DIESEL 0x2/// Compressed natural gas propulsion
218 #define LE_ECALL_PROPULSION_TYPE_NATURALGAS 0x4/// Liquid propane gas propulsion
219 #define LE_ECALL_PROPULSION_TYPE_PROPANE 0x8/// Electric propulsion
220 #define LE_ECALL_PROPULSION_TYPE_ELECTRIC 0x10/// Hydrogen propulsion
221 #define LE_ECALL_PROPULSION_TYPE_HYDROGEN 0x20/// Other type of propulsions
222 #define LE_ECALL_PROPULSION_TYPE_OTHER 0x40
223 typedef uint32_t le_ecall_PropulsionTypeBitMask_t;
224 
225 
226 //--------------------------------------------------------------------------------------------------
227 /**
228  * Diagnostic result Bit Mask (64 bits)
229  *
230  */
231 //--------------------------------------------------------------------------------------------------/// Present Mic connection failure.
232 #define LE_ECALL_DIAG_RESULT_PRESENT_MIC_CONNECTION_FAILURE 0x1/// Mic connection failure status.
233 #define LE_ECALL_DIAG_RESULT_MIC_CONNECTION_FAILURE 0x2/// Present Mic failure.
234 #define LE_ECALL_DIAG_RESULT_PRESENT_MIC_FAILURE 0x4/// Mic failure status.
235 #define LE_ECALL_DIAG_RESULT_MIC_FAILURE 0x8/// Present Right speaker failure.
236 #define LE_ECALL_DIAG_RESULT_PRESENT_RIGHT_SPEAKER_FAILURE 0x10/// Right speaker failure status.
237 #define LE_ECALL_DIAG_RESULT_RIGHT_SPEAKER_FAILURE 0x20/// Present Left speaker failure.
238 #define LE_ECALL_DIAG_RESULT_PRESENT_LEFT_SPEAKER_FAILURE 0x40/// Left speaker failure status.
239 #define LE_ECALL_DIAG_RESULT_LEFT_SPEAKER_FAILURE 0x80/// Present Speaker failure.
240 #define LE_ECALL_DIAG_RESULT_PRESENT_SPEAKERS_FAILURE 0x100/// Speaker failure status.
241 #define LE_ECALL_DIAG_RESULT_SPEAKERS_FAILURE 0x200/// Present Ignition line failure.
242 #define LE_ECALL_DIAG_RESULT_PRESENT_IGNITION_LINE_FAILURE 0x400/// Ignition line failure status.
243 #define LE_ECALL_DIAG_RESULT_IGNITION_LINE_FAILURE 0x800/// Present UIM failure.
244 #define LE_ECALL_DIAG_RESULT_PRESENT_UIM_FAILURE 0x1000/// UIM failure status.
245 #define LE_ECALL_DIAG_RESULT_UIM_FAILURE 0x2000/// Present Status indicator failure.
246 #define LE_ECALL_DIAG_RESULT_PRESENT_STATUS_INDICATOR_FAILURE 0x4000/// Status indicator failure status.
247 #define LE_ECALL_DIAG_RESULT_STATUS_INDICATOR_FAILURE 0x8000/// Present Battery failure.
248 #define LE_ECALL_DIAG_RESULT_PRESENT_BATTERY_FAILURE 0x10000/// Battery failure status.
249 #define LE_ECALL_DIAG_RESULT_BATTERY_FAILURE 0x20000/// Present Battery voltage low failure.
250 #define LE_ECALL_DIAG_RESULT_PRESENT_BATTERY_VOLTAGE_LOW 0x40000/// Battery voltage low failure status.
251 #define LE_ECALL_DIAG_RESULT_BATTERY_VOLTAGE_LOW 0x80000/// Present Crash sensor failure.
252 #define LE_ECALL_DIAG_RESULT_PRESENT_CRASH_SENSOR_FAILURE 0x100000/// Crash sensor failure status.
253 #define LE_ECALL_DIAG_RESULT_CRASH_SENSOR_FAILURE 0x200000/// Present Firmware image corruption failure.
254 #define LE_ECALL_DIAG_RESULT_PRESENT_FIRMWARE_IMAGE_CORRUPTION 0x400000/// Firmware image corruption failure status.
255 #define LE_ECALL_DIAG_RESULT_FIRMWARE_IMAGE_CORRUPTION 0x800000/// Present Comm module interface failure.
256 #define LE_ECALL_DIAG_RESULT_PRESENT_COMM_MODULE_INTERFACE_FAILURE 0x1000000/// Comm module interface failure status.
257 #define LE_ECALL_DIAG_RESULT_COMM_MODULE_INTERFACE_FAILURE 0x2000000/// Present GNSS receiver failure.
258 #define LE_ECALL_DIAG_RESULT_PRESENT_GNSS_RECEIVER_FAILURE 0x4000000/// GNSS receiver failure status.
259 #define LE_ECALL_DIAG_RESULT_GNSS_RECEIVER_FAILURE 0x8000000/// Present RAIM problem.
260 #define LE_ECALL_DIAG_RESULT_PRESENT_RAIM_PROBLEM 0x10000000/// RAIM problem status.
261 #define LE_ECALL_DIAG_RESULT_RAIM_PROBLEM 0x20000000/// Present GNSS antenna failure.
262 #define LE_ECALL_DIAG_RESULT_PRESENT_GNSS_ANTENNA_FAILURE 0x40000000/// GNSS antenna failure status.
263 #define LE_ECALL_DIAG_RESULT_GNSS_ANTENNA_FAILURE 0x80000000/// Present Comm module failure.
264 #define LE_ECALL_DIAG_RESULT_PRESENT_COMM_MODULE_FAILURE 0x100000000/// Comm module failure status.
265 #define LE_ECALL_DIAG_RESULT_COMM_MODULE_FAILURE 0x200000000/// Present Events memory overflow.
266 #define LE_ECALL_DIAG_RESULT_PRESENT_EVENTS_MEMORY_OVERFLOW 0x400000000/// Events memory overflow status.
267 #define LE_ECALL_DIAG_RESULT_EVENTS_MEMORY_OVERFLOW 0x800000000/// Present Crash profile memory overflow.
268 #define LE_ECALL_DIAG_RESULT_PRESENT_CRASH_PROFILE_MEMORY_OVERFLOW 0x1000000000/// Crash profile memory overflow status.
269 #define LE_ECALL_DIAG_RESULT_CRASH_PROFILE_MEMORY_OVERFLOW 0x2000000000/// Present Other critical failures.
270 #define LE_ECALL_DIAG_RESULT_PRESENT_OTHER_CRITICAL_FAILURES 0x4000000000/// Other critical failures status.
271 #define LE_ECALL_DIAG_RESULT_OTHER_CRITICAL_FAILURES 0x8000000000/// Present Other not critical failures.
272 #define LE_ECALL_DIAG_RESULT_PRESENT_OTHER_NOT_CRITICAL_FAILURES 0x10000000000/// Other not critical failures status.
273 #define LE_ECALL_DIAG_RESULT_OTHER_NOT_CRITICAL_FAILURES 0x20000000000
274 typedef uint64_t le_ecall_DiagnosticResultBitMask_t;
275 
276 
277 //--------------------------------------------------------------------------------------------------
278 /**
279  * Crash information Bit Mask (16 bits) indicating the type of road accident.
280  *
281  */
282 //--------------------------------------------------------------------------------------------------/// Present Front collision indicator.
283 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_FRONT 0x1/// Front collision indicator.
284 #define LE_ECALL_CRASH_INFO_CRASH_FRONT 0x2/// Present Left collision indicator.
285 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_LEFT 0x4/// Left collision indicator.
286 #define LE_ECALL_CRASH_INFO_CRASH_LEFT 0x8/// Present Right collision indicator
287 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_RIGHT 0x10/// Right collision indicator
288 #define LE_ECALL_CRASH_INFO_CRASH_RIGHT 0x20/// Present indicator
289 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_REAR 0x40/// Rear impact indicator.
290 #define LE_ECALL_CRASH_INFO_CRASH_REAR 0x80/// Present Rollover indicator.
291 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_ROLLOVER 0x100/// Rollover indicator.
292 #define LE_ECALL_CRASH_INFO_CRASH_ROLLOVER 0x200/// Present Side collision indicator.
293 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_SIDE 0x400/// Side collision indicator.
294 #define LE_ECALL_CRASH_INFO_CRASH_SIDE 0x800/// Present Front or side collision indicator.
295 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_FRONT_OR_SIDE 0x1000/// Front or side collision indicator.
296 #define LE_ECALL_CRASH_INFO_CRASH_FRONT_OR_SIDE 0x2000/// Present Other types of damage indicator.
297 #define LE_ECALL_CRASH_INFO_PRESENT_CRASH_ANOTHER_TYPE 0x4000/// Other types of damage indicator.
298 #define LE_ECALL_CRASH_INFO_CRASH_ANOTHER_TYPE 0x8000
299 typedef uint32_t le_ecall_CrashInfoBitMask_t;
300 
301 
302 //--------------------------------------------------------------------------------------------------
303 /**
304  * eCall MSD coordinate system type
305  */
306 //--------------------------------------------------------------------------------------------------
307 typedef enum
308 {
310  ///< Coordinate system type is absent
312  ///< Coordinate system type WGS-84
314  ///< Coordinate system type PZ-90
315 }
317 
318 
319 //--------------------------------------------------------------------------------------------------
320 /**
321  * Reference type used by Add/Remove functions for EVENT 'le_ecall_StateChange'
322  */
323 //--------------------------------------------------------------------------------------------------
324 typedef struct le_ecall_StateChangeHandler* le_ecall_StateChangeHandlerRef_t;
325 
326 
327 //--------------------------------------------------------------------------------------------------
328 /**
329  * Handler for eCall state changes.
330  *
331  */
332 //--------------------------------------------------------------------------------------------------
333 typedef void (*le_ecall_StateChangeHandlerFunc_t)
334 (
335  le_ecall_CallRef_t ecallRef,
336  ///< eCall reference
337  le_ecall_State_t state,
338  ///< eCall state
339  void* contextPtr
340  ///<
341 );
342 
343 
344 //--------------------------------------------------------------------------------------------------
345 /**
346  * Get if this client bound locally.
347  */
348 //--------------------------------------------------------------------------------------------------
349 LE_SHARED bool ifgen_le_ecall_HasLocalBinding
350 (
351  void
352 );
353 
354 
355 //--------------------------------------------------------------------------------------------------
356 /**
357  * Init data that is common across all threads
358  */
359 //--------------------------------------------------------------------------------------------------
360 LE_SHARED void ifgen_le_ecall_InitCommonData
361 (
362  void
363 );
364 
365 
366 //--------------------------------------------------------------------------------------------------
367 /**
368  * Perform common initialization and open a session
369  */
370 //--------------------------------------------------------------------------------------------------
371 LE_SHARED le_result_t ifgen_le_ecall_OpenSession
372 (
373  le_msg_SessionRef_t _ifgen_sessionRef,
374  bool isBlocking
375 );
376 
377 //--------------------------------------------------------------------------------------------------
378 /**
379  * This function configures the eCall operation mode to eCall only, only emergency number can be
380  * used to start an eCall session. The modem doesn't try to register on the Cellular network.
381  * This function forces the modem to behave as eCall only mode whatever U/SIM operation mode.
382  * The change doesn't persist over power cycles.
383  * This function can be called before making an eCall.
384  *
385  * @return
386  * - LE_OK on success
387  * - LE_FAULT for other failures
388  * - LE_UNSUPPORTED Not supported on this platform
389  */
390 //--------------------------------------------------------------------------------------------------
391 LE_SHARED le_result_t ifgen_le_ecall_ForceOnlyMode
392 (
393  le_msg_SessionRef_t _ifgen_sessionRef
394 );
395 
396 //--------------------------------------------------------------------------------------------------
397 /**
398  * Same as le_ecall_ForceOnlyMode(), but the change persists over power cycles.
399  *
400  * @return
401  * - LE_OK on success
402  * - LE_FAULT for other failures
403  * - LE_UNSUPPORTED Not supported on this platform
404  */
405 //--------------------------------------------------------------------------------------------------
406 LE_SHARED le_result_t ifgen_le_ecall_ForcePersistentOnlyMode
407 (
408  le_msg_SessionRef_t _ifgen_sessionRef
409 );
410 
411 //--------------------------------------------------------------------------------------------------
412 /**
413  * This function exits from eCall Only mode. It configures the eCall operation mode to Normal mode,
414  * the modem uses the default operation mode at power up (or after U/SIM hotswap). The modem behaves
415  * following the U/SIM eCall operation mode; for example the U/SIM can be configured only for eCall,
416  * or a combination of eCall and commercial service provision.
417  *
418  * @return
419  * - LE_OK on success
420  * - LE_FAULT for other failures
421  * - LE_UNSUPPORTED Not supported on this platform
422  */
423 //--------------------------------------------------------------------------------------------------
424 LE_SHARED le_result_t ifgen_le_ecall_ExitOnlyMode
425 (
426  le_msg_SessionRef_t _ifgen_sessionRef
427 );
428 
429 //--------------------------------------------------------------------------------------------------
430 /**
431  * Get the configured Operation mode.
432  *
433  * @return
434  * - LE_OK on success
435  * - LE_FAULT for other failures
436  * - LE_UNSUPPORTED Not supported on this platform
437  *
438  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
439  * function will not return.
440  */
441 //--------------------------------------------------------------------------------------------------
442 LE_SHARED le_result_t ifgen_le_ecall_GetConfiguredOperationMode
443 (
444  le_msg_SessionRef_t _ifgen_sessionRef,
445  le_ecall_OpMode_t* opModePtr
446  ///< [OUT] Operation mode
447 );
448 
449 //--------------------------------------------------------------------------------------------------
450 /**
451  * Add handler function for EVENT 'le_ecall_StateChange'
452  *
453  * This event provides information on eCall state changes.
454  *
455  */
456 //--------------------------------------------------------------------------------------------------
457 LE_SHARED le_ecall_StateChangeHandlerRef_t ifgen_le_ecall_AddStateChangeHandler
458 (
459  le_msg_SessionRef_t _ifgen_sessionRef,
461  ///< [IN]
462  void* contextPtr
463  ///< [IN]
464 );
465 
466 //--------------------------------------------------------------------------------------------------
467 /**
468  * Remove handler function for EVENT 'le_ecall_StateChange'
469  */
470 //--------------------------------------------------------------------------------------------------
471 LE_SHARED void ifgen_le_ecall_RemoveStateChangeHandler
472 (
473  le_msg_SessionRef_t _ifgen_sessionRef,
475  ///< [IN]
476 );
477 
478 //--------------------------------------------------------------------------------------------------
479 /**
480  * Create a new eCall object
481  *
482  * The eCall is not actually established at this point. It's still up to the caller to call
483  * le_ecall_Start() when ready.
484  *
485  * @return
486  * - A reference to the new Call object.
487  *
488  * @note On failure, the process exits; you don't have to worry about checking the returned
489  * reference for validity.
490  */
491 //--------------------------------------------------------------------------------------------------
492 LE_SHARED le_ecall_CallRef_t ifgen_le_ecall_Create
493 (
494  le_msg_SessionRef_t _ifgen_sessionRef
495 );
496 
497 //--------------------------------------------------------------------------------------------------
498 /**
499  * Call to free up a call reference.
500  *
501  * @note This will free the reference, but not necessarily stop an active eCall. If there are
502  * other holders of this reference the eCall will remain active.
503  */
504 //--------------------------------------------------------------------------------------------------
505 LE_SHARED void ifgen_le_ecall_Delete
506 (
507  le_msg_SessionRef_t _ifgen_sessionRef,
508  le_ecall_CallRef_t ecallRef
509  ///< [IN] eCall reference
510 );
511 
512 //--------------------------------------------------------------------------------------------------
513 /**
514  * Set the system standard.
515  * Default is PAN EUROPEAN
516  *
517  * @return
518  * - LE_OK on success
519  * - LE_FAULT for other failures
520  */
521 //--------------------------------------------------------------------------------------------------
522 LE_SHARED le_result_t ifgen_le_ecall_SetSystemStandard
523 (
524  le_msg_SessionRef_t _ifgen_sessionRef,
525  le_ecall_SystemStandard_t systemStandard
526  ///< [IN] System standard
527 );
528 
529 //--------------------------------------------------------------------------------------------------
530 /**
531  * Get the system standard.
532  *
533  * @return
534  * - LE_OK on success
535  * - LE_FAULT for other failures
536  * - LE_BAD_PARAMETER parameter is NULL
537  */
538 //--------------------------------------------------------------------------------------------------
539 LE_SHARED le_result_t ifgen_le_ecall_GetSystemStandard
540 (
541  le_msg_SessionRef_t _ifgen_sessionRef,
542  le_ecall_SystemStandard_t* systemStandardPtr
543  ///< [OUT] System Standard
544 );
545 
546 //--------------------------------------------------------------------------------------------------
547 /**
548  * Set the MSDs version.
549  * Default value is 1
550  *
551  * @return
552  * - LE_OK on success
553  * - LE_FAULT for other failures
554  */
555 //--------------------------------------------------------------------------------------------------
556 LE_SHARED le_result_t ifgen_le_ecall_SetMsdVersion
557 (
558  le_msg_SessionRef_t _ifgen_sessionRef,
559  uint32_t msdVersion
560  ///< [IN] Msd version
561 );
562 
563 //--------------------------------------------------------------------------------------------------
564 /**
565  * Get the MSD version.
566  *
567  * @return
568  * - LE_OK on success
569  * - LE_FAULT for other failures
570  * - LE_BAD_PARAMETER parameter is NULL
571  */
572 //--------------------------------------------------------------------------------------------------
573 LE_SHARED le_result_t ifgen_le_ecall_GetMsdVersion
574 (
575  le_msg_SessionRef_t _ifgen_sessionRef,
576  uint32_t* msdVersionPtr
577  ///< [OUT] Msd version
578 );
579 
580 //--------------------------------------------------------------------------------------------------
581 /**
582  * Set the Vehicled Type
583  * Default value is 0
584  *
585  * @return
586  * - LE_OK on success
587  * - LE_FAULT for other failures
588  */
589 //--------------------------------------------------------------------------------------------------
590 LE_SHARED le_result_t ifgen_le_ecall_SetVehicleType
591 (
592  le_msg_SessionRef_t _ifgen_sessionRef,
593  le_ecall_MsdVehicleType_t vehicleType
594  ///< [IN] Vehicle type
595 );
596 
597 //--------------------------------------------------------------------------------------------------
598 /**
599  * Get the Vehicled Type.
600  *
601  * @return
602  * - LE_OK on success
603  * - LE_BAD_PARAMETER parameter is NULL
604  * - LE_FAULT for other failures
605  */
606 //--------------------------------------------------------------------------------------------------
607 LE_SHARED le_result_t ifgen_le_ecall_GetVehicleType
608 (
609  le_msg_SessionRef_t _ifgen_sessionRef,
610  le_ecall_MsdVehicleType_t* vehicleTypePtr
611  ///< [OUT] Vehicle type
612 );
613 
614 //--------------------------------------------------------------------------------------------------
615 /**
616  * Set the VIN (Vehicle Identification Number).
617  *
618  * @return
619  * - LE_OK on success
620  * - LE_BAD_PARAMETER parameter is NULL.
621  * - LE_FAULT for other failures
622  */
623 //--------------------------------------------------------------------------------------------------
624 LE_SHARED le_result_t ifgen_le_ecall_SetVIN
625 (
626  le_msg_SessionRef_t _ifgen_sessionRef,
627  const char* LE_NONNULL vin
628  ///< [IN] VIN (Vehicle Identification Number)
629 );
630 
631 //--------------------------------------------------------------------------------------------------
632 /**
633  * Get the VIN (Vehicle Identification Number).
634  *
635  * @return
636  * - LE_OK on success
637  * - LE_NOT_FOUND if the value is not set.
638  * - LE_BAD_PARAMETER parameter is NULL or to small
639  * - LE_FAULT for other failures
640  */
641 //--------------------------------------------------------------------------------------------------
642 LE_SHARED le_result_t ifgen_le_ecall_GetVIN
643 (
644  le_msg_SessionRef_t _ifgen_sessionRef,
645  char* vin,
646  ///< [OUT] VIN is gotten with a null termination.
647  size_t vinSize
648  ///< [IN]
649 );
650 
651 //--------------------------------------------------------------------------------------------------
652 /**
653  * Set the propulsion type.
654  * Note that a vehicle may have more than one propulsion type.
655  *
656  * @return
657  * - LE_OK on success
658  * - LE_FAULT for other failures
659  */
660 //--------------------------------------------------------------------------------------------------
661 LE_SHARED le_result_t ifgen_le_ecall_SetPropulsionType
662 (
663  le_msg_SessionRef_t _ifgen_sessionRef,
664  le_ecall_PropulsionTypeBitMask_t propulsionType
665  ///< [IN] bitmask
666 );
667 
668 //--------------------------------------------------------------------------------------------------
669 /**
670  * Get the propulsion stored.
671  * Note that a vehicle may have more than one propulsion type.
672  *
673  * @return
674  * - LE_OK on success
675  * - LE_NOT_FOUND if the value is not set.
676  * - LE_FAULT for other failures
677  * - LE_BAD_PARAMETER parameter is NULL
678  */
679 //--------------------------------------------------------------------------------------------------
680 LE_SHARED le_result_t ifgen_le_ecall_GetPropulsionType
681 (
682  le_msg_SessionRef_t _ifgen_sessionRef,
683  le_ecall_PropulsionTypeBitMask_t* propulsionTypePtr
684  ///< [OUT] bitmask
685 );
686 
687 //--------------------------------------------------------------------------------------------------
688 /**
689  * Set the push/pull transmission mode.
690  *
691  * @return
692  * - LE_OK on success
693  * - LE_FAULT for other failures
694  * - LE_UNSUPPORTED Not supported on this platform
695  */
696 //--------------------------------------------------------------------------------------------------
697 LE_SHARED le_result_t ifgen_le_ecall_SetMsdTxMode
698 (
699  le_msg_SessionRef_t _ifgen_sessionRef,
701  ///< [IN] Transmission mode
702 );
703 
704 //--------------------------------------------------------------------------------------------------
705 /**
706  * Get the push/pull transmission mode.
707  *
708  * @return
709  * - LE_OK on success
710  * - LE_FAULT for other failures
711  * - LE_UNSUPPORTED Not supported on this platform
712  *
713  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
714  * function will not return.
715  */
716 //--------------------------------------------------------------------------------------------------
717 LE_SHARED le_result_t ifgen_le_ecall_GetMsdTxMode
718 (
719  le_msg_SessionRef_t _ifgen_sessionRef,
720  le_ecall_MsdTxMode_t* modePtr
721  ///< [OUT] Transmission mode
722 );
723 
724 //--------------------------------------------------------------------------------------------------
725 /**
726  * Set the position transmitted by the MSD.
727  *
728  * @return
729  * - LE_OK on success
730  * - LE_DUPLICATE an MSD has been already imported
731  * - LE_BAD_PARAMETER bad input parameter
732  * - LE_FAULT on other failures
733  *
734  * @note The process exits, if an invalid eCall reference is given
735  */
736 //--------------------------------------------------------------------------------------------------
737 LE_SHARED le_result_t ifgen_le_ecall_SetMsdPosition
738 (
739  le_msg_SessionRef_t _ifgen_sessionRef,
740  le_ecall_CallRef_t ecallRef,
741  ///< [IN] eCall reference
742  bool isTrusted,
743  ///< [IN] true if the position is accurate, false otherwise
744  int32_t latitude,
745  ///< [IN] latitude in degrees with 6 decimal places, positive North.
746  ///< Maximum value is +90 degrees (+90000000), minimum value is -90
747  ///< degrees (-90000000).
748  int32_t longitude,
749  ///< [IN] longitude in degrees with 6 decimal places, positive East.
750  ///< Maximum value is +180 degrees (+180000000), minimum value is
751  ///< -180 degrees (-180000000).
752  int32_t direction
753  ///< [IN] direction of the vehicle from magnetic north (0 to 358, clockwise)
754  ///< in 2-degrees unit. Valid range is 0 to 179. If direction of
755  ///< travel is invalid or unknown, the value 0xFF shall be used.
756 );
757 
758 //--------------------------------------------------------------------------------------------------
759 /**
760  * Set the position Delta N-1 from position set in le_ecall_SetMsdPosition() transmitted by the MSD.
761  *
762  * @return
763  * - LE_OK on success
764  * - LE_DUPLICATE an MSD has been already imported
765  * - LE_BAD_PARAMETER bad input parameter
766  * - LE_FAULT on other failures
767  *
768  * @note The process exits, if an invalid eCall reference is given
769  */
770 //--------------------------------------------------------------------------------------------------
771 LE_SHARED le_result_t ifgen_le_ecall_SetMsdPositionN1
772 (
773  le_msg_SessionRef_t _ifgen_sessionRef,
774  le_ecall_CallRef_t ecallRef,
775  ///< [IN] eCall reference
776  int32_t latitudeDeltaN1,
777  ///< [IN] longitude delta from position set in SetMsdPosition
778  ///< 1 Unit = 100 miliarcseconds, which is approximately 3m
779  ///< maximum value: 511 = 0 0'51.100'' (+- 1580m)
780  ///< minimum value: -512 = -0 0'51.200'' (+- -1583m)
781  int32_t longitudeDeltaN1
782  ///< [IN] longitude delta from position set in SetMsdPosition
783  ///< 1 Unit = 100 miliarcseconds, which is approximately 3m
784  ///< maximum value: 511 = 0 0'51.100'' (+-1580m)
785  ///< minimum value: -512 = -0 0'51.200'' (+- -1583m) )
786 );
787 
788 //--------------------------------------------------------------------------------------------------
789 /**
790  * Set the position Delta N-2 from position set in le_ecall_SetMsdPositionN1() transmitted by the MSD.
791  *
792  * @return
793  * - LE_OK on success
794  * - LE_DUPLICATE an MSD has been already imported
795  * - LE_BAD_PARAMETER bad input parameter
796  * - LE_FAULT on other failures
797  *
798  * @note The process exits, if an invalid eCall reference is given
799  */
800 //--------------------------------------------------------------------------------------------------
801 LE_SHARED le_result_t ifgen_le_ecall_SetMsdPositionN2
802 (
803  le_msg_SessionRef_t _ifgen_sessionRef,
804  le_ecall_CallRef_t ecallRef,
805  ///< [IN] eCall reference
806  int32_t latitudeDeltaN2,
807  ///< [IN] longitude delta from position set in SetMsdPositionN1
808  ///< 1 Unit = 100 miliarcseconds, which is approximately 3m
809  ///< maximum value: 511 = 0 0'51.100'' (+-1580m)
810  ///< minimum value: -512 = -0 0'51.200'' (+- -1583m)
811  int32_t longitudeDeltaN2
812  ///< [IN] longitude delta from position set in SetMsdPositionN1
813  ///< 1 Unit = 100 miliarcseconds, which is approximately 3m
814  ///< maximum value: 511 = 0 0'51.100'' (+-1580m)
815  ///< minimum value: -512 = -0 0'51.200'' (+- -1583m) )
816 );
817 
818 //--------------------------------------------------------------------------------------------------
819 /**
820  * Set the number of passengers transmitted by the MSD.
821  *
822  * @return
823  * - LE_OK on success
824  * - LE_DUPLICATE an MSD has been already imported
825  * - LE_BAD_PARAMETER bad eCall reference
826  *
827  * @note The process exits, if an invalid eCall reference is given
828  */
829 //--------------------------------------------------------------------------------------------------
830 LE_SHARED le_result_t ifgen_le_ecall_SetMsdPassengersCount
831 (
832  le_msg_SessionRef_t _ifgen_sessionRef,
833  le_ecall_CallRef_t ecallRef,
834  ///< [IN] eCall reference
835  uint32_t paxCount
836  ///< [IN] number of passengers
837 );
838 
839 //--------------------------------------------------------------------------------------------------
840 /**
841  * Set the ECALL_DIAL_DURATION time. It's the maximum time the IVS have to connect the emergency
842  * call to the PSAP, including all redial attempts.
843  * If the call is not connected within this time (or ManualDialAttempts/AutoDialAttempts dial
844  * attempts), it will stop.
845  *
846  * @return
847  * - LE_OK on success
848  * - LE_FAULT on failure
849  *
850  * @note This ECALL_DIAL_DURATION time is only applicable to initial call (call never established
851  * with PSAP). After first call establishment, in case of dropped call, redial duration is
852  * fixed by PAN-European eCall standard to 2 minutes.
853  */
854 //--------------------------------------------------------------------------------------------------
855 LE_SHARED le_result_t ifgen_le_ecall_SetPanInitialDialDuration
856 (
857  le_msg_SessionRef_t _ifgen_sessionRef,
858  uint16_t duration
859  ///< [IN] the ECALL_DIAL_DURATION time value (in seconds)
860 );
861 
862 //--------------------------------------------------------------------------------------------------
863 /**
864  * Get the ECALL_DIAL_DURATION time.
865  *
866  * @return
867  * - LE_OK on success
868  * - LE_FAULT on failure
869  */
870 //--------------------------------------------------------------------------------------------------
871 LE_SHARED le_result_t ifgen_le_ecall_GetPanInitialDialDuration
872 (
873  le_msg_SessionRef_t _ifgen_sessionRef,
874  uint16_t* durationPtr
875  ///< [OUT] the ECALL_DIAL_DURATION time value (in seconds)
876 );
877 
878 //--------------------------------------------------------------------------------------------------
879 /**
880  * Import an already prepared MSD.
881  *
882  * MSD is transmitted only after an emergency call has been established.
883  *
884  * @return
885  * - LE_OK on success
886  * - LE_OVERFLOW The imported MSD length exceeds the MSD_MAX_LEN maximum length.
887  * - LE_BAD_PARAMETER bad eCall reference
888  * - LE_FAULT for other failures
889  *
890  * @note On failure, the process exits; you don't have to worry about checking the returned
891  * reference for validity.
892  */
893 //--------------------------------------------------------------------------------------------------
894 LE_SHARED le_result_t ifgen_le_ecall_ImportMsd
895 (
896  le_msg_SessionRef_t _ifgen_sessionRef,
897  le_ecall_CallRef_t ecallRef,
898  ///< [IN] eCall reference
899  const uint8_t* msdPtr,
900  ///< [IN] the prepared MSD
901  size_t msdSize
902  ///< [IN]
903 );
904 
905 //--------------------------------------------------------------------------------------------------
906 /**
907  * Export the encoded MSD.
908  *
909  * @return
910  * - LE_OK on success
911  * - LE_OVERFLOW The encoded MSD length exceeds the user's buffer length.
912  * - LE_NOT_FOUND No encoded MSD is available.
913  * - LE_BAD_PARAMETER bad eCall reference.
914  * - LE_FAULT for other failures.
915  *
916  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
917  * function will not return.
918  */
919 //--------------------------------------------------------------------------------------------------
920 LE_SHARED le_result_t ifgen_le_ecall_ExportMsd
921 (
922  le_msg_SessionRef_t _ifgen_sessionRef,
923  le_ecall_CallRef_t ecallRef,
924  ///< [IN] eCall reference
925  uint8_t* msdPtr,
926  ///< [OUT] the encoded MSD
927  size_t* msdSizePtr
928  ///< [INOUT]
929 );
930 
931 //--------------------------------------------------------------------------------------------------
932 /**
933  * Send the MSD.
934  *
935  * @return
936  * - LE_OK on success
937  * - LE_BAD_PARAMETER bad eCall reference
938  * - LE_FAULT for other failures
939  * - LE_UNSUPPORTED Not supported on this platform
940  *
941  * @note On failure, the process exits, so you don't have to worry about checking the returned
942  * reference for validity.
943  */
944 //--------------------------------------------------------------------------------------------------
945 LE_SHARED le_result_t ifgen_le_ecall_SendMsd
946 (
947  le_msg_SessionRef_t _ifgen_sessionRef,
948  le_ecall_CallRef_t ecallRef
949  ///< [IN] eCall reference
950 );
951 
952 //--------------------------------------------------------------------------------------------------
953 /**
954  * Start an automatic eCall session
955  *
956  * @return
957  * - LE_OK on success
958  * - LE_BUSY an eCall session is already in progress
959  * - LE_BAD_PARAMETER bad eCall reference
960  * - LE_FAULT for other failures
961  * - LE_UNSUPPORTED Not supported on this platform
962  *
963  * @note The process exits, if an invalid eCall reference is given
964  */
965 //--------------------------------------------------------------------------------------------------
966 LE_SHARED le_result_t ifgen_le_ecall_StartAutomatic
967 (
968  le_msg_SessionRef_t _ifgen_sessionRef,
969  le_ecall_CallRef_t ecallRef
970  ///< [IN] eCall reference
971 );
972 
973 //--------------------------------------------------------------------------------------------------
974 /**
975  * Start a manual eCall session
976  *
977  * @return
978  * - LE_OK on success
979  * - LE_BUSY an eCall session is already in progress
980  * - LE_BAD_PARAMETER bad eCall reference
981  * - LE_FAULT for other failures
982  * - LE_UNSUPPORTED Not supported on this platform
983  *
984  * @note The process exits, if an invalid eCall reference is given
985  */
986 //--------------------------------------------------------------------------------------------------
987 LE_SHARED le_result_t ifgen_le_ecall_StartManual
988 (
989  le_msg_SessionRef_t _ifgen_sessionRef,
990  le_ecall_CallRef_t ecallRef
991  ///< [IN] eCall reference
992 );
993 
994 //--------------------------------------------------------------------------------------------------
995 /**
996  * Start a test eCall session
997  *
998  * @return
999  * - LE_OK on success
1000  * - LE_BUSY an eCall session is already in progress
1001  * - LE_BAD_PARAMETER bad eCall reference
1002  * - LE_FAULT for other failures
1003  * - LE_UNSUPPORTED Not supported on this platform
1004  *
1005  * @note The process exits, if an invalid eCall reference is given
1006  */
1007 //--------------------------------------------------------------------------------------------------
1008 LE_SHARED le_result_t ifgen_le_ecall_StartTest
1009 (
1010  le_msg_SessionRef_t _ifgen_sessionRef,
1011  le_ecall_CallRef_t ecallRef
1012  ///< [IN] eCall reference
1013 );
1014 
1015 //--------------------------------------------------------------------------------------------------
1016 /**
1017  * End the current eCall session
1018  *
1019  * @note
1020  * - During an automatic eCall session, it is not possible to end the ongoing session until
1021  * LE_ECALL_STATE_STOPPED event is notified.
1022  * - For manual session, it is possible to end the ongoing session if the eCall is not connected
1023  * (LE_ECALL_STATE_CONNECTED not yet received) and after LE_ECALL_STATE_STOPPED event is notified.
1024  * - Using this API doesn't affect the NAD deregistration mechanism. However, it disables the call
1025  * auto answer function if already running.
1026  *
1027  * @return
1028  * - LE_OK on success
1029  * - LE_BAD_PARAMETER bad eCall reference
1030  * - LE_FAULT for other failures
1031  * - LE_UNSUPPORTED Not supported on this platform
1032  */
1033 //--------------------------------------------------------------------------------------------------
1034 LE_SHARED le_result_t ifgen_le_ecall_End
1035 (
1036  le_msg_SessionRef_t _ifgen_sessionRef,
1037  le_ecall_CallRef_t ecallRef
1038  ///< [IN] eCall reference
1039 );
1040 
1041 //--------------------------------------------------------------------------------------------------
1042 /**
1043  * Get the current state for the given eCall
1044  *
1045  * @return
1046  * - The current state for the given eCall
1047  *
1048  * @note The process exits, if an invalid eCall reference is given
1049  */
1050 //--------------------------------------------------------------------------------------------------
1051 LE_SHARED le_ecall_State_t ifgen_le_ecall_GetState
1052 (
1053  le_msg_SessionRef_t _ifgen_sessionRef,
1054  le_ecall_CallRef_t ecallRef
1055  ///< [IN] eCall reference
1056 );
1057 
1058 //--------------------------------------------------------------------------------------------------
1059 /**
1060  * Set the Public Safely Answering Point telephone number.
1061  *
1062  * @note That PSAP number is not applied to Manually or Automatically initiated eCall. For those
1063  * modes, an emergency call is launched.
1064  *
1065  * @warning This function doesn't modify the U/SIM content.
1066  *
1067  * @return
1068  * - LE_OK On success
1069  * - LE_FAULT For other failures
1070  * - LE_UNSUPPORTED Not supported on this platform
1071  *
1072  * @note If PSAP number is empty or too long (max LE_MDMDEFS_PHONE_NUM_MAX_LEN digits), it is a
1073  * fatal error, the function will not return.
1074  */
1075 //--------------------------------------------------------------------------------------------------
1076 LE_SHARED le_result_t ifgen_le_ecall_SetPsapNumber
1077 (
1078  le_msg_SessionRef_t _ifgen_sessionRef,
1079  const char* LE_NONNULL psap
1080  ///< [IN] Public Safely Answering Point number
1081 );
1082 
1083 //--------------------------------------------------------------------------------------------------
1084 /**
1085  * Get the Public Safely Answering Point telephone number set with le_ecall_SetPsapNumber()
1086  * function.
1087  *
1088  * @note That PSAP number is not applied to Manually or Automatically initiated eCall. For those
1089  * modes, an emergency call is launched.
1090  *
1091  * @warning This function doesn't read the U/SIM content.
1092  *
1093  * @return
1094  * - LE_OK On success
1095  * - LE_FAULT On failures or if le_ecall_SetPsapNumber() has never been called before
1096  * * - LE_OVERFLOW Retrieved PSAP number is too long for the out parameter
1097  * - LE_UNSUPPORTED Not supported on this platform
1098  *
1099  * @note If the passed PSAP pointer is NULL, a fatal error is raised and the function will not
1100  * return.
1101  */
1102 //--------------------------------------------------------------------------------------------------
1103 LE_SHARED le_result_t ifgen_le_ecall_GetPsapNumber
1104 (
1105  le_msg_SessionRef_t _ifgen_sessionRef,
1106  char* psap,
1107  ///< [OUT] Public Safely Answering Point telephone
1108  ///< number
1109  size_t psapSize
1110  ///< [IN]
1111 );
1112 
1113 //--------------------------------------------------------------------------------------------------
1114 /**
1115  * When modem is in ECALL_FORCED_PERSISTENT_ONLY_MODE or ECALL_ONLY_MODE, this function
1116  * can be called to request the modem to read the number to dial from the FDN/SDN of the U/SIM.
1117  *
1118  * @note If FDN directory is updated with new dial numbers, be sure that the SIM card is refreshed.
1119  *
1120  * @return
1121  * - LE_OK on success
1122  * - LE_FAULT for other failures
1123  */
1124 //--------------------------------------------------------------------------------------------------
1125 LE_SHARED le_result_t ifgen_le_ecall_UseUSimNumbers
1126 (
1127  le_msg_SessionRef_t _ifgen_sessionRef
1128 );
1129 
1130 //--------------------------------------------------------------------------------------------------
1131 /**
1132  * Set the NAD (network access device) deregistration time value. After termination of an emergency
1133  * call the in-vehicle system remains registered on the network for the period of time, defined by
1134  * the installation parameter NAD (network access device) deregistration time.
1135  *
1136  * @return
1137  * - LE_OK on success
1138  * - LE_FAULT on failure
1139  *
1140  * @note The formula to calculate NAD deregistration time for PAN_EUROPEAN is as below:
1141  * ECallConfiguration.nad_deregistration_time = (deregTime+59)/60;
1142  */
1143 //--------------------------------------------------------------------------------------------------
1144 LE_SHARED le_result_t ifgen_le_ecall_SetNadDeregistrationTime
1145 (
1146  le_msg_SessionRef_t _ifgen_sessionRef,
1147  uint16_t deregTime
1148  ///< [IN] the NAD (network access device) deregistration time value (in minutes).
1149 );
1150 
1151 //--------------------------------------------------------------------------------------------------
1152 /**
1153  * Get the NAD (network access device) deregistration time value.
1154  *
1155  * @return
1156  * - LE_OK on success
1157  * - LE_FAULT on failure
1158  */
1159 //--------------------------------------------------------------------------------------------------
1160 LE_SHARED le_result_t ifgen_le_ecall_GetNadDeregistrationTime
1161 (
1162  le_msg_SessionRef_t _ifgen_sessionRef,
1163  uint16_t* deregTimePtr
1164  ///< [OUT] the NAD (network access device) deregistration time value
1165 );
1166 
1167 //--------------------------------------------------------------------------------------------------
1168 /**
1169  * Set the minimum interval value between dial attempts.
1170  *
1171  * @return
1172  * - LE_OK on success
1173  * - LE_FAULT for other failures
1174  */
1175 //--------------------------------------------------------------------------------------------------
1176 LE_SHARED le_result_t ifgen_le_ecall_SetIntervalBetweenDialAttempts
1177 (
1178  le_msg_SessionRef_t _ifgen_sessionRef,
1179  uint16_t pause
1180  ///< [IN] the minimum interval value in seconds
1181 );
1182 
1183 //--------------------------------------------------------------------------------------------------
1184 /**
1185  * Get the minimum interval value between dial attempts.
1186  *
1187  * @return
1188  * - LE_OK on success
1189  * - LE_FAULT for other failures
1190  */
1191 //--------------------------------------------------------------------------------------------------
1192 LE_SHARED le_result_t ifgen_le_ecall_GetIntervalBetweenDialAttempts
1193 (
1194  le_msg_SessionRef_t _ifgen_sessionRef,
1195  uint16_t* pausePtr
1196  ///< [OUT] the minimum interval value in seconds
1197 );
1198 
1199 //--------------------------------------------------------------------------------------------------
1200 /**
1201  * Set the ECALL_MANUAL_DIAL_ATTEMPTS value. If a dial attempt under manual emergency call
1202  * initiation failed, it should be repeated maximally ECALL_MANUAL_DIAL_ATTEMPTS-1 times within
1203  * the maximal time limit of ECALL_DIAL_DURATION. The default value is 10.
1204  * Redial attempts stop once the call has been cleared down correctly, or if counter/timer reached
1205  * their limits.
1206  *
1207  * @return
1208  * - LE_OK on success
1209  * - LE_FAULT on failure
1210  */
1211 //--------------------------------------------------------------------------------------------------
1212 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassManualDialAttempts
1213 (
1214  le_msg_SessionRef_t _ifgen_sessionRef,
1215  uint16_t attempts
1216  ///< [IN] the ECALL_MANUAL_DIAL_ATTEMPTS value
1217 );
1218 
1219 //--------------------------------------------------------------------------------------------------
1220 /**
1221  * Set the ECALL_AUTO_DIAL_ATTEMPTS value. If a dial attempt under automatic emergency call
1222  * initiation failed, it should be repeated maximally ECALL_AUTO_DIAL_ATTEMPTS-1 times within
1223  * the maximal time limit of ECALL_DIAL_DURATION. The default value is 10.
1224  * Redial attempts stop once the call has been cleared down correctly, or if counter/timer reached
1225  * their limits.
1226  *
1227  * @return
1228  * - LE_OK on success
1229  * - LE_FAULT on failure
1230  */
1231 //--------------------------------------------------------------------------------------------------
1232 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassAutoDialAttempts
1233 (
1234  le_msg_SessionRef_t _ifgen_sessionRef,
1235  uint16_t attempts
1236  ///< [IN] the ECALL_AUTO_DIAL_ATTEMPTS value
1237 );
1238 
1239 //--------------------------------------------------------------------------------------------------
1240 /**
1241  * Set the ECALL_DIAL_DURATION time. It's the maximum time the IVS have to connect the emergency
1242  * call to the PSAP, including all redial attempts.
1243  * If the call is not connected within this time (or ManualDialAttempts/AutoDialAttempts dial
1244  * attempts), it will stop.
1245  *
1246  * @return
1247  * - LE_OK on success
1248  * - LE_FAULT on failure
1249  * - LE_UNSUPPORTED if the function is not supported by the target
1250  */
1251 //--------------------------------------------------------------------------------------------------
1252 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassDialDuration
1253 (
1254  le_msg_SessionRef_t _ifgen_sessionRef,
1255  uint16_t duration
1256  ///< [IN] the ECALL_DIAL_DURATION time value (in seconds)
1257 );
1258 
1259 //--------------------------------------------------------------------------------------------------
1260 /**
1261  * Set the ECALL_CCFT time. It's the maximum delay before initiating an an automatic call
1262  * termination.
1263  * When the delay is reached and IVS NAD didn't receive a call clear-down indication then the call
1264  * is immediatly terminated.
1265  *
1266  * @note Allowed range of values is 1 to 720 minutes.
1267  *
1268  * @return
1269  * - LE_OK on success
1270  * - LE_FAULT on failure
1271  * - LE_UNSUPPORTED if the function is not supported by the target
1272  */
1273 //--------------------------------------------------------------------------------------------------
1274 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassFallbackTime
1275 (
1276  le_msg_SessionRef_t _ifgen_sessionRef,
1277  uint16_t duration
1278  ///< [IN] the ECALL_CCFT time value (in minutes)
1279 );
1280 
1281 //--------------------------------------------------------------------------------------------------
1282 /**
1283  * Set the ECALL_AUTO_ANSWER_TIME time, the time interval wherein IVDS responds to incoming calls
1284  * automatically after emergency call completion.
1285  *
1286  * @note Default value of auto answer time is 20 minutes. Maximum value is 720 minutes.
1287  *
1288  * @return
1289  * - LE_OK on success
1290  * - LE_FAULT on failure
1291  * - LE_UNSUPPORTED if the function is not supported by the target
1292  */
1293 //--------------------------------------------------------------------------------------------------
1294 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassAutoAnswerTime
1295 (
1296  le_msg_SessionRef_t _ifgen_sessionRef,
1297  uint16_t autoAnswerTime
1298  ///< [IN] The ECALL_AUTO_ANSWER_TIME time value (in minutes)
1299 );
1300 
1301 //--------------------------------------------------------------------------------------------------
1302 /**
1303  * Set the ECALL_MSD_MAX_TRANSMISSION_TIME time, the time period for MSD transmission.
1304  *
1305  * @note Default value of MSD transmission time is 20 seconds.
1306  *
1307  * @return
1308  * - LE_OK on success
1309  * - LE_FAULT on failure
1310  * - LE_UNSUPPORTED if the function is not supported by the target
1311  */
1312 //--------------------------------------------------------------------------------------------------
1313 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassMSDMaxTransmissionTime
1314 (
1315  le_msg_SessionRef_t _ifgen_sessionRef,
1316  uint16_t msdMaxTransTime
1317  ///< [IN] The ECALL_MSD_MAX_TRANSMISSION_TIME time value (in seconds)
1318 );
1319 
1320 //--------------------------------------------------------------------------------------------------
1321 /**
1322  * Set the ERA-GLONASS ECALL_POST_TEST_REGISTRATION_TIME time.
1323  *
1324  * After completion of transmission of test diagnostics results in an eCall test session, the
1325  * in-vehicle system remains registered on the network for the period of time defined by the
1326  * ECALL_POST_TEST_REGISTRATION_TIME value.
1327  *
1328  * @note The ECALL_POST_TEST_REGISTRATION_TIME setting takes effect immediately and is persistent to
1329  * reset.
1330  *
1331  * @note An ECALL_POST_TEST_REGISTRATION_TIME value of zero means the IVS doesn't remain registered
1332  * after completion of transmission of test (diagnostics) results.
1333  *
1334  * @return
1335  * - LE_OK on success
1336  * - LE_FAULT on failure
1337  * - LE_UNSUPPORTED if the function is not supported by the target
1338  */
1339 //--------------------------------------------------------------------------------------------------
1340 LE_SHARED le_result_t ifgen_le_ecall_SetEraGlonassPostTestRegistrationTime
1341 (
1342  le_msg_SessionRef_t _ifgen_sessionRef,
1343  uint16_t postTestRegTime
1344  ///< [IN] The ECALL_POST_TEST_REGISTRATION_TIME time value (in seconds)
1345 );
1346 
1347 //--------------------------------------------------------------------------------------------------
1348 /**
1349  * Get the ECALL_MANUAL_DIAL_ATTEMPTS value.
1350  *
1351  * @return
1352  * - LE_OK on success
1353  * - LE_FAULT on failure
1354  */
1355 //--------------------------------------------------------------------------------------------------
1356 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassManualDialAttempts
1357 (
1358  le_msg_SessionRef_t _ifgen_sessionRef,
1359  uint16_t* attemptsPtr
1360  ///< [OUT] the ECALL_MANUAL_DIAL_ATTEMPTS value
1361 );
1362 
1363 //--------------------------------------------------------------------------------------------------
1364 /**
1365  * Get the ECALL_AUTO_DIAL_ATTEMPTS value.
1366  *
1367  * @return
1368  * - LE_OK on success
1369  * - LE_FAULT on failure
1370  */
1371 //--------------------------------------------------------------------------------------------------
1372 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassAutoDialAttempts
1373 (
1374  le_msg_SessionRef_t _ifgen_sessionRef,
1375  uint16_t* attemptsPtr
1376  ///< [OUT] the ECALL_AUTO_DIAL_ATTEMPTS value
1377 );
1378 
1379 //--------------------------------------------------------------------------------------------------
1380 /**
1381  * Get the ECALL_DIAL_DURATION time.
1382  *
1383  * @return
1384  * - LE_OK on success
1385  * - LE_FAULT on failure
1386  */
1387 //--------------------------------------------------------------------------------------------------
1388 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassDialDuration
1389 (
1390  le_msg_SessionRef_t _ifgen_sessionRef,
1391  uint16_t* durationPtr
1392  ///< [OUT] the ECALL_DIAL_DURATION time value (in seconds)
1393 );
1394 
1395 //--------------------------------------------------------------------------------------------------
1396 /**
1397  * Get the ECALL_CCFT time.
1398  *
1399  * @return
1400  * - LE_OK on success
1401  * - LE_FAULT on failure
1402  */
1403 //--------------------------------------------------------------------------------------------------
1404 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassFallbackTime
1405 (
1406  le_msg_SessionRef_t _ifgen_sessionRef,
1407  uint16_t* durationPtr
1408  ///< [OUT] the ECALL_CCFT time value (in minutes)
1409 );
1410 
1411 //--------------------------------------------------------------------------------------------------
1412 /**
1413  * Get the ECALL_AUTO_ANSWER_TIME time.
1414  *
1415  * @return
1416  * - LE_OK on success
1417  * - LE_FAULT on execution failure
1418  */
1419 //--------------------------------------------------------------------------------------------------
1420 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassAutoAnswerTime
1421 (
1422  le_msg_SessionRef_t _ifgen_sessionRef,
1423  uint16_t* autoAnswerTimePtr
1424  ///< [OUT] The ECALL_AUTO_ANSWER_TIME time value (in minutes)
1425 );
1426 
1427 //--------------------------------------------------------------------------------------------------
1428 /**
1429  * Get the ECALL_MSD_MAX_TRANSMISSION_TIME time.
1430  *
1431  * @return
1432  * - LE_OK on success
1433  * - LE_FAULT on failure
1434  * - LE_UNSUPPORTED if the function is not supported by the target
1435  */
1436 //--------------------------------------------------------------------------------------------------
1437 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassMSDMaxTransmissionTime
1438 (
1439  le_msg_SessionRef_t _ifgen_sessionRef,
1440  uint16_t* msdMaxTransTimePtr
1441  ///< [OUT] The ECALL_MSD_MAX_TRANSMISSION_TIME time value (in seconds)
1442 );
1443 
1444 //--------------------------------------------------------------------------------------------------
1445 /**
1446  * Get the ERA-GLONASS ECALL_POST_TEST_REGISTRATION_TIME time.
1447  *
1448  * @return
1449  * - LE_OK on success
1450  * - LE_FAULT on failure
1451  * - LE_UNSUPPORTED if the function is not supported by the target
1452  */
1453 //--------------------------------------------------------------------------------------------------
1454 LE_SHARED le_result_t ifgen_le_ecall_GetEraGlonassPostTestRegistrationTime
1455 (
1456  le_msg_SessionRef_t _ifgen_sessionRef,
1457  uint16_t* postTestRegTimePtr
1458  ///< [OUT] The ECALL_POST_TEST_REGISTRATION_TIME time value (in
1459  ///< seconds).
1460 );
1461 
1462 //--------------------------------------------------------------------------------------------------
1463 /**
1464  * Set the ERA-GLONASS crash severity parameter.
1465  *
1466  * @return
1467  * - LE_OK on success
1468  * - LE_DUPLICATE an MSD has been already imported
1469  * - LE_BAD_PARAMETER bad eCall reference
1470  * - LE_FAULT on other failures
1471  */
1472 //--------------------------------------------------------------------------------------------------
1473 LE_SHARED le_result_t ifgen_le_ecall_SetMsdEraGlonassCrashSeverity
1474 (
1475  le_msg_SessionRef_t _ifgen_sessionRef,
1476  le_ecall_CallRef_t ecallRef,
1477  ///< [IN] eCall reference
1478  uint32_t crashSeverity
1479  ///< [IN] the ERA-GLONASS crash severity parameter
1480 );
1481 
1482 //--------------------------------------------------------------------------------------------------
1483 /**
1484  * Reset the ERA-GLONASS crash severity parameter. Therefore that optional parameter is not included
1485  * in the MSD message.
1486  *
1487  * @return
1488  * - LE_OK on success
1489  * - LE_DUPLICATE an MSD has been already imported
1490  * - LE_BAD_PARAMETER bad eCall reference
1491  * - LE_FAULT on other failures
1492  */
1493 //--------------------------------------------------------------------------------------------------
1494 LE_SHARED le_result_t ifgen_le_ecall_ResetMsdEraGlonassCrashSeverity
1495 (
1496  le_msg_SessionRef_t _ifgen_sessionRef,
1497  le_ecall_CallRef_t ecallRef
1498  ///< [IN] eCall reference
1499 );
1500 
1501 //--------------------------------------------------------------------------------------------------
1502 /**
1503  * Set the ERA-GLONASS diagnostic result using a bit mask.
1504  *
1505  * @return
1506  * - LE_OK on success
1507  * - LE_DUPLICATE an MSD has been already imported
1508  * - LE_BAD_PARAMETER bad eCall reference
1509  * - LE_FAULT on other failures
1510  */
1511 //--------------------------------------------------------------------------------------------------
1512 LE_SHARED le_result_t ifgen_le_ecall_SetMsdEraGlonassDiagnosticResult
1513 (
1514  le_msg_SessionRef_t _ifgen_sessionRef,
1515  le_ecall_CallRef_t ecallRef,
1516  ///< [IN] eCall reference
1517  le_ecall_DiagnosticResultBitMask_t diagnosticResultMask
1518  ///< [IN] ERA-GLONASS diagnostic result bit mask.
1519 );
1520 
1521 //--------------------------------------------------------------------------------------------------
1522 /**
1523  * Reset the ERA-GLONASS diagnostic result bit mask. Optional parameter is not
1524  * included in the MSD message.
1525  *
1526  * @return
1527  * - LE_OK on success
1528  * - LE_DUPLICATE an MSD has been already imported
1529  * - LE_BAD_PARAMETER bad eCall reference
1530  * - LE_FAULT on other failures
1531  */
1532 //--------------------------------------------------------------------------------------------------
1533 LE_SHARED le_result_t ifgen_le_ecall_ResetMsdEraGlonassDiagnosticResult
1534 (
1535  le_msg_SessionRef_t _ifgen_sessionRef,
1536  le_ecall_CallRef_t ecallRef
1537  ///< [IN] eCall reference
1538 );
1539 
1540 //--------------------------------------------------------------------------------------------------
1541 /**
1542  * Set the ERA-GLONASS crash type bit mask
1543  *
1544  * @return
1545  * - LE_OK on success
1546  * - LE_DUPLICATE an MSD has been already imported
1547  * - LE_BAD_PARAMETER bad eCall reference
1548  * - LE_FAULT on other failures
1549  */
1550 //--------------------------------------------------------------------------------------------------
1551 LE_SHARED le_result_t ifgen_le_ecall_SetMsdEraGlonassCrashInfo
1552 (
1553  le_msg_SessionRef_t _ifgen_sessionRef,
1554  le_ecall_CallRef_t ecallRef,
1555  ///< [IN] eCall reference
1556  le_ecall_CrashInfoBitMask_t crashInfoMask
1557  ///< [IN] ERA-GLONASS crash type bit mask.
1558 );
1559 
1560 //--------------------------------------------------------------------------------------------------
1561 /**
1562  * Reset the ERA-GLONASS crash type bit mask. Optional parameter is not included
1563  * in the MSD message.
1564  *
1565  * @return
1566  * - LE_OK on success
1567  * - LE_DUPLICATE an MSD has been already imported
1568  * - LE_BAD_PARAMETER bad eCall reference
1569  * - LE_FAULT on other failures
1570  */
1571 //--------------------------------------------------------------------------------------------------
1572 LE_SHARED le_result_t ifgen_le_ecall_ResetMsdEraGlonassCrashInfo
1573 (
1574  le_msg_SessionRef_t _ifgen_sessionRef,
1575  le_ecall_CallRef_t ecallRef
1576  ///< [IN] eCall reference
1577 );
1578 
1579 //--------------------------------------------------------------------------------------------------
1580 /**
1581  * Set the ERA-GLONASS coordinate system type.
1582  *
1583  * @return
1584  * - LE_OK on success
1585  * - LE_DUPLICATE an MSD has been already imported
1586  * - LE_BAD_PARAMETER bad eCall reference
1587  * - LE_FAULT on other failures
1588  */
1589 //--------------------------------------------------------------------------------------------------
1590 LE_SHARED le_result_t ifgen_le_ecall_SetMsdEraGlonassCoordinateSystemType
1591 (
1592  le_msg_SessionRef_t _ifgen_sessionRef,
1593  le_ecall_CallRef_t ecallRef,
1594  ///< [IN] eCall reference
1595  le_ecall_MsdCoordinateType_t coordinateSystemType
1596  ///< [IN] the ERA-GLONASS coordinate system type
1597 );
1598 
1599 //--------------------------------------------------------------------------------------------------
1600 /**
1601  * Reset the ERA-GLONASS coordinate system type. Therefore that optional parameter is not included
1602  * in the MSD message.
1603  *
1604  * @return
1605  * - LE_OK on success
1606  * - LE_DUPLICATE an MSD has been already imported
1607  * - LE_BAD_PARAMETER bad eCall reference
1608  * - LE_FAULT on other failures
1609  */
1610 //--------------------------------------------------------------------------------------------------
1611 LE_SHARED le_result_t ifgen_le_ecall_ResetMsdEraGlonassCoordinateSystemType
1612 (
1613  le_msg_SessionRef_t _ifgen_sessionRef,
1614  le_ecall_CallRef_t ecallRef
1615  ///< [IN] eCall reference
1616 );
1617 
1618 //--------------------------------------------------------------------------------------------------
1619 /**
1620  * Called to get the termination reason.
1621  *
1622  * @return The termination reason.
1623  *
1624  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1625  * function will not return.
1626  */
1627 //--------------------------------------------------------------------------------------------------
1628 LE_SHARED le_mcc_TerminationReason_t ifgen_le_ecall_GetTerminationReason
1629 (
1630  le_msg_SessionRef_t _ifgen_sessionRef,
1631  le_ecall_CallRef_t ecallRef
1632  ///< [IN] eCall reference.
1633 );
1634 
1635 //--------------------------------------------------------------------------------------------------
1636 /**
1637  * Called to get the platform specific termination code.
1638  *
1639  * @return The platform specific termination code.
1640  *
1641  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1642  * function will not return.
1643  */
1644 //--------------------------------------------------------------------------------------------------
1645 LE_SHARED int32_t ifgen_le_ecall_GetPlatformSpecificTerminationCode
1646 (
1647  le_msg_SessionRef_t _ifgen_sessionRef,
1648  le_ecall_CallRef_t ecallRef
1649  ///< [IN] eCall reference.
1650 );
1651 
1652 //--------------------------------------------------------------------------------------------------
1653 /**
1654  * Terminate NAD registered on the network. After termination of an emergency call the in-vehicle
1655  * system remains registered on the network for a period of time, this API will deregister device
1656  * from network in this period.
1657  *
1658  * @return
1659  * - LE_OK on success
1660  * - LE_FAULT on failure
1661  * - LE_UNSUPPORTED if the function is not supported by the target
1662  */
1663 //--------------------------------------------------------------------------------------------------
1664 LE_SHARED le_result_t ifgen_le_ecall_TerminateRegistration
1665 (
1666  le_msg_SessionRef_t _ifgen_sessionRef
1667 );
1668 /** @} **/
1669 #endif // LE_ECALL_COMMON_H_INCLUDE_GUARD
le_ecall_State_t
Definition: le_ecall_common.h:100
eCall session has lost synchronization and starts over.
Definition: le_ecall_common.h:131
ERA GLONASS standard.
Definition: le_ecall_common.h:89
#define LE_SHARED
Definition: le_basics.h:287
Definition: le_ecall_common.h:71
Unknown state.
Definition: le_ecall_common.h:102
AL-ACK clear-down received.
Definition: le_ecall_common.h:126
LL-NACK received.
Definition: le_ecall_common.h:116
End of the redial period.
Definition: le_ecall_common.h:139
le_result_t
Definition: le_basics.h:46
struct le_ecall_Call * le_ecall_CallRef_t
Definition: le_ecall_common.h:59
Definition: le_ecall_common.h:133
Motorcycles (Class L6e)
Definition: le_ecall_common.h:203
le_ecall_MsdCoordinateType_t
Definition: le_ecall_common.h:307
PAN-EUROPEAN standard.
Definition: le_ecall_common.h:87
MSD transmission has failed.
Definition: le_ecall_common.h:122
LL-ACK received.
Definition: le_ecall_common.h:118
Pull mode (modem/host waits for MSD request from PSAP to send MSD).
Definition: le_ecall_common.h:166
Timeout for Timer T10 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:153
Motorcycles (Class L4e)
Definition: le_ecall_common.h:199
Motorcycles (Class L5e)
Definition: le_ecall_common.h:201
MSD transmission is complete.
Definition: le_ecall_common.h:120
le_ecall_MsdVehicleType_t
Definition: le_ecall_common.h:179
eCall session started.
Definition: le_ecall_common.h:104
Waiting for PSAP start indication.
Definition: le_ecall_common.h:110
Timeout for Timer T2 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:141
Passenger vehicle (Class M1)
Definition: le_ecall_common.h:181
PSAP start indication received.
Definition: le_ecall_common.h:112
Normal mode.
Definition: le_ecall_common.h:69
Heavy duty vehicles (Class N2)
Definition: le_ecall_common.h:189
Motorcycles (Class L7e)
Definition: le_ecall_common.h:205
Push mode (modem/host sends MSD to PSAP right after eCall is connected).
Definition: le_ecall_common.h:168
Timeout for Timer T6 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:147
le_ecall_MsdTxMode_t
Definition: le_ecall_common.h:164
Light commercial vehicles (Class N1)
Definition: le_ecall_common.h:187
Timeout for Timer T7 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:149
le_ecall_SystemStandard_t
Definition: le_ecall_common.h:85
Motorcycles (Class L2e)
Definition: le_ecall_common.h:195
struct le_msg_Session * le_msg_SessionRef_t
Definition: le_messaging.h:860
le_mcc_TerminationReason_t
Definition: le_mcc_common.h:65
Heavy duty vehicles (Class N3)
Definition: le_ecall_common.h:191
Coordinate system type is absent.
Definition: le_ecall_common.h:309
Coordinate system type WGS-84.
Definition: le_ecall_common.h:311
MSD transmission is started.
Definition: le_ecall_common.h:114
Timeout for Timer T9 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:151
Buses and coaches (Class M2)
Definition: le_ecall_common.h:183
struct le_ecall_StateChangeHandler * le_ecall_StateChangeHandlerRef_t
Definition: le_ecall_common.h:324
Coordinate system type PZ-90.
Definition: le_ecall_common.h:313
AL-ACK received.
Definition: le_ecall_common.h:124
le_ecall_OpMode_t
Definition: le_ecall_common.h:67
Motorcycles (Class L1e)
Definition: le_ecall_common.h:193
Timeout for Timer T3 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:143
Unsuccessful eCall session.
Definition: le_ecall_common.h:137
void(* le_ecall_StateChangeHandlerFunc_t)(le_ecall_CallRef_t ecallRef, le_ecall_State_t state, void *contextPtr)
Definition: le_ecall_common.h:334
Definition: le_ecall_common.h:128
Buses and coaches (Class M3)
Definition: le_ecall_common.h:185
Persistent eCall only mode.
Definition: le_ecall_common.h:74
Emergency call is established.
Definition: le_ecall_common.h:106
Timeout for Timer T5 (see CEN-EN 16062, annex A)
Definition: le_ecall_common.h:145
Motorcycles (Class L3e)
Definition: le_ecall_common.h:197
Emergency call is disconnected.
Definition: le_ecall_common.h:108