le_mdc_interface.h

Go to the documentation of this file.
1 
2 
3 /*
4  * ====================== WARNING ======================
5  *
6  * THE CONTENTS OF THIS FILE HAVE BEEN AUTO-GENERATED.
7  * DO NOT MODIFY IN ANY WAY.
8  *
9  * ====================== WARNING ======================
10  */
11 
12 /**
13  * @page c_mdc Modem Data Control
14  *
15  * @ref le_mdc_interface.h "API Reference"
16  *
17  * <HR>
18  *
19  * A data session is useful for applications that need to send or receive data over a network
20  * where SMS messages are insufficient. To start a data session, a data profile must
21  * be configured as specified by the target network.
22  *
23  * The Modem Data Control (mdc) API is used to manage data profiles and data sessions.
24  *
25  * @section le_mdc_binding IPC interfaces binding
26  *
27  * All the functions of this API are provided by the @b modemService service.
28  *
29  * Here's a code sample binding to modem services:
30  * @verbatim
31  bindings:
32  {
33  clientExe.clientComponent.le_mdc -> modemService.le_mdc
34  }
35  @endverbatim
36  *
37  * @section le_mdc_profile Data Profiles
38  *
39  * If a pre-defined data profile has been configured then this profile can
40  * be loaded using le_mdc_GetProfile().
41  * le_mdc_GetProfile() must be called with @c LE_MDC_DEFAULT_PROFILE to retrieve the default index
42  * used by the modem for data connection.
43  * le_mdc_GetProfile() must be called with @c LE_MDC_SIMTOOLKIT_BIP_DEFAULT_PROFILE to retrieve the
44  * default index used by the modem for Bearer Independent Protocol (BIP).
45  * The maximum number of data profiles supported is modem dependent and can be retrieved with
46  * le_mdc_NumProfiles().
47  *
48  * @note le_mdc_GetProfile() creates a new profile if the profile's index can't be found.
49  *
50  * @warning 0 is not a valid index.
51  *
52  * A pre-defined data profile can be retrieved using le_mdc_GetProfileFromApn() thanks to its
53  * APN.
54  *
55  * A default APN can be set for a defined profile with le_mdc_SetDefaultAPN(), based on the SIM
56  * identification number (ICCID). If no match is found in the database using the ICCID, the search
57  * falls back on the home network (MCC/MNC) to determine the default APN.
58  *
59  * @warning Ensure to check the list of supported data profiles for your specific platform.
60  *
61  * The following data profile parameters can be retrieved:
62  * - Packet Data Protocol using le_mdc_GetPDP().
63  * - Access Point Name using le_mdc_GetAPN().
64  * - Authentication settings using le_mdc_GetAuthentication().
65  *
66  * The following data profile parameters can be set:
67  * - Packet Data Protocol using le_mdc_SetPDP().
68  * - Access Point Name using le_mdc_SetAPN().
69  * - Authentication settings using le_mdc_SetAuthentication().
70  *
71  * @warning The maximum APN length might be limited by the platform.
72  * Please refer to the platform documentation.
73  *
74  * A sample code can be seen in the following page:
75  * - @subpage c_mdcDataProfiles
76  *
77  * @section le_mdc_session Data Sessions
78  *
79  * @subsection le_mdc_session_MO Mobile Originated (MO-PDP context activation)
80  *
81  * le_mdc_MapProfileOnNetworkInterface() may be used to map a data session with a network interface.
82  * To take effect, this API has to be called before starting the data session. Otherwise, the
83  * mapping will be taken into account at the next start of the data profile.
84  *
85  * A data session can be started using le_mdc_StartSession(). To start a data session, a
86  * data profile must be created and written to the modem, or an existing data profile
87  * can be used. A data session can be stopped using le_mdc_StopSession(). The number of
88  * simultaneous data sessions supported is dependent on the modem, but cannot be more than the
89  * maximum number of supported profiles.
90  *
91  * A data session can be started using le_mdc_StartSessionAsync() and stopped using
92  * le_mdc_StopSessionAsync(). These functions are not blocking. The response will be returned
93  * with the @c le_mdc_SessionHandlerFunc_t handler function.
94  *
95  * The current state of a data session can be queried using le_mdc_GetSessionState(). An application
96  * can also a register handler to be notified when the session state changes. The handler
97  * can be managed using le_mdc_AddSessionStateHandler() and le_mdc_RemoveSessionStateHandler().
98  *
99  * @subsection le_mdc_session_MT Mobile Terminated (MT-PDP context activation)
100  * To be notified by the MT-PDP context request, the application has to subscribe to the state
101  * handler using le_mdc_AddMtPdpSessionStateHandler().
102  * When the incoming MT-PDP context request is notified,
103  * the application takes responsibility to trigger the data session for that MT PDP request using
104  * le_mdc_StartSession(). That data session can be stopped using le_mdc_StopSession().
105  *
106  * The network interface settings of that MT-PDP context can be retrieved using the provided
107  * Data Profile.
108  * Please refer to @ref le_mdc_session_networkItf.
109  *
110  * A data session can be rejected using le_mdc_RejectMtPdpSession().
111  * The number of simultaneous data sessions supported is dependent on the modem,
112  * but cannot be more than the maximum number of supported profiles.
113  *
114  * The handler can be released using le_mdc_RemoveMtPdpSessionStateHandler().
115  *
116  * @warning The MT-PDP context activation feature is not supported on all platforms. Please refer to
117  * @ref MT-PDP_context section for full details.
118  *
119  * @subsection le_mdc_session_networkItf Network interface settings
120  * Once a data session starts, a Linux network interface is created. It's the application's
121  * responsibility to configure the network interface, usually through a DHCP client. Query the
122  * interface name using le_mdc_GetInterfaceName(). The IP Preference can be checked with
123  * le_mdc_IsIPv4() or le_mdc_IsIPv6() when the profile is connected. The IP address for the
124  * current data session
125  * can be retrieved by le_mdc_GetIPv4Address() or le_mdc_GetIPv6Address(). The Gateway and
126  * DNS
127  * addresses can be retrieved using le_mdc_GetIPv4GatewayAddress(),
128  * le_mdc_GetIPv4DNSAddresses() or le_mdc_GetIPv6GatewayAddress(), le_mdc_GetIPv6DNSAddresses().
129  * The Access Point Name can be retrieved by le_mdc_GetAPN(). The Data bearer
130  * Technology can be retrieved by le_mdc_GetDataBearerTechnology().
131  *
132  * le_mdc_GetDisconnectionReason() or le_mdc_GetPlatformSpecificDisconnectionCode() let you get
133  * the reason for disconnection of data session by retrieving the call end failure code
134  * from @c le_mdc_ProfileRef_t.
135  *
136  * le_mdc_GetPlatformSpecificFailureConnectionReason() let you get the data session connection
137  * failure reason by retrieving the call connection failure code and type from
138  * @c le_mdc_ProfileRef_t.
139  *
140  * Please refer to @ref platformConstraintsSpecificErrorCodes for platform specific
141  * disconnection code description.
142  *
143  * A sample code can be seen in the following page:
144  * - @subpage c_mdcDataSessions
145  *
146  * @section le_mdc_dataStatistics Data Statistics
147  *
148  * The amount of received and transmitted data can be retrieved through le_mdc_GetBytesCounters().
149  * The returned values correspond to the number of received and transmitted
150  * bytes since the last call to le_mdc_ResetBytesCounter().
151  *
152  * The data statistics collection can be enabled with le_mdc_StartBytesCounter() and disabled
153  * without resetting the counters with le_mdc_StopBytesCounter().
154  *
155  * @note The data statistics collection activation and the data counters are persistent even after
156  * a reboot of the platform.
157  *
158  * A sample code can be seen in the following page:
159  * - @subpage c_mdcDataStatistics
160  *
161  * <HR>
162  *
163  * Copyright (C) Sierra Wireless Inc.
164  */
165 /**
166  * @page c_mdcDataProfiles Sample code for Data Profiles
167  *
168  * @snippet "apps/test/modemServices/mdc/mdcIntegrationTest/mdcTestComp/mdcTest.c" Profiles
169  */
170 /**
171  * @page c_mdcDataSessions Sample code for network interface settings
172  *
173  * @snippet "apps/test/modemServices/mdc/mdcIntegrationTest/mdcTestComp/mdcTest.c" Sessions
174  */
175 /**
176  * @page c_mdcDataStatistics Sample code for Data Statistics
177  *
178  * @snippet "apps/test/modemServices/mdc/mdcIntegrationTest/mdcTestComp/mdcTest.c" Statistics
179  */
180 /**
181  * @file le_mdc_interface.h
182  *
183  * Legato @ref c_mdc include file.
184  *
185  * Copyright (C) Sierra Wireless Inc.
186  */
187 
188 #ifndef LE_MDC_INTERFACE_H_INCLUDE_GUARD
189 #define LE_MDC_INTERFACE_H_INCLUDE_GUARD
190 
191 
192 #include "legato.h"
193 
194 
195 //--------------------------------------------------------------------------------------------------
196 /**
197  * Type for handler called when a server disconnects.
198  */
199 //--------------------------------------------------------------------------------------------------
200 typedef void (*le_mdc_DisconnectHandler_t)(void *);
201 
202 //--------------------------------------------------------------------------------------------------
203 /**
204  *
205  * Connect the current client thread to the service providing this API. Block until the service is
206  * available.
207  *
208  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
209  * called before any other functions in this API. Normally, ConnectService is automatically called
210  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
211  *
212  * This function is created automatically.
213  */
214 //--------------------------------------------------------------------------------------------------
216 (
217  void
218 );
219 
220 //--------------------------------------------------------------------------------------------------
221 /**
222  *
223  * Try to connect the current client thread to the service providing this API. Return with an error
224  * if the service is not available.
225  *
226  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
227  * called before any other functions in this API. Normally, ConnectService is automatically called
228  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
229  *
230  * This function is created automatically.
231  *
232  * @return
233  * - LE_OK if the client connected successfully to the service.
234  * - LE_UNAVAILABLE if the server is not currently offering the service to which the client is
235  * bound.
236  * - LE_NOT_PERMITTED if the client interface is not bound to any service (doesn't have a binding).
237  * - LE_COMM_ERROR if the Service Directory cannot be reached.
238  */
239 //--------------------------------------------------------------------------------------------------
241 (
242  void
243 );
244 
245 //--------------------------------------------------------------------------------------------------
246 /**
247  * Set handler called when server disconnection is detected.
248  *
249  * When a server connection is lost, call this handler then exit with LE_FATAL. If a program wants
250  * to continue without exiting, it should call longjmp() from inside the handler.
251  */
252 //--------------------------------------------------------------------------------------------------
254 (
255  le_mdc_DisconnectHandler_t disconnectHandler,
256  void *contextPtr
257 );
258 
259 //--------------------------------------------------------------------------------------------------
260 /**
261  *
262  * Disconnect the current client thread from the service providing this API.
263  *
264  * Normally, this function doesn't need to be called. After this function is called, there's no
265  * longer a connection to the service, and the functions in this API can't be used. For details, see
266  * @ref apiFilesC_client.
267  *
268  * This function is created automatically.
269  */
270 //--------------------------------------------------------------------------------------------------
272 (
273  void
274 );
275 
276 
277 //--------------------------------------------------------------------------------------------------
278 /**
279  * Maximum number of bytes in a interface name (not including the null-terminator).
280  */
281 //--------------------------------------------------------------------------------------------------
282 #define LE_MDC_INTERFACE_NAME_MAX_LEN 20
283 
284 //--------------------------------------------------------------------------------------------------
285 /**
286  * Maximum number of bytes in a profile name (including the null-terminator).
287  */
288 //--------------------------------------------------------------------------------------------------
289 #define LE_MDC_INTERFACE_NAME_MAX_BYTES 21
290 
291 //--------------------------------------------------------------------------------------------------
292 /**
293  * Maximum number of bytes in an IPv4 address (not including the null-terminator).
294  */
295 //--------------------------------------------------------------------------------------------------
296 #define LE_MDC_IPV4_ADDR_MAX_LEN 15
297 
298 //--------------------------------------------------------------------------------------------------
299 /**
300  * Maximum number of bytes in an IPv4 address (including the null-terminator).
301  */
302 //--------------------------------------------------------------------------------------------------
303 #define LE_MDC_IPV4_ADDR_MAX_BYTES 16
304 
305 //--------------------------------------------------------------------------------------------------
306 /**
307  * Maximum number of bytes in an IPv6 address (not including the null-terminator).
308  */
309 //--------------------------------------------------------------------------------------------------
310 #define LE_MDC_IPV6_ADDR_MAX_LEN 45
311 
312 //--------------------------------------------------------------------------------------------------
313 /**
314  * Maximum number of bytes in an IPv6 address (including the null-terminator).
315  */
316 //--------------------------------------------------------------------------------------------------
317 #define LE_MDC_IPV6_ADDR_MAX_BYTES 46
318 
319 //--------------------------------------------------------------------------------------------------
320 /**
321  * Maximum number of bytes in a apn name (not including the null-terminator).
322  */
323 //--------------------------------------------------------------------------------------------------
324 #define LE_MDC_APN_NAME_MAX_LEN 100
325 
326 //--------------------------------------------------------------------------------------------------
327 /**
328  * Maximum number of bytes in a apn name (including the null-terminator).
329  */
330 //--------------------------------------------------------------------------------------------------
331 #define LE_MDC_APN_NAME_MAX_BYTES 101
332 
333 //--------------------------------------------------------------------------------------------------
334 /**
335  * Maximum number of bytes in a user name (not including the null-terminator).
336  */
337 //--------------------------------------------------------------------------------------------------
338 #define LE_MDC_USER_NAME_MAX_LEN 64
339 
340 //--------------------------------------------------------------------------------------------------
341 /**
342  * Maximum number of bytes in a user name (including the null-terminator).
343  */
344 //--------------------------------------------------------------------------------------------------
345 #define LE_MDC_USER_NAME_MAX_BYTES 65
346 
347 //--------------------------------------------------------------------------------------------------
348 /**
349  * Maximum number of bytes in a password name (not including the null-terminator).
350  */
351 //--------------------------------------------------------------------------------------------------
352 #define LE_MDC_PASSWORD_NAME_MAX_LEN 100
353 
354 //--------------------------------------------------------------------------------------------------
355 /**
356  * Maximum number of bytes in a password name (including the null-terminator).
357  */
358 //--------------------------------------------------------------------------------------------------
359 #define LE_MDC_PASSWORD_NAME_MAX_BYTES 101
360 
361 //--------------------------------------------------------------------------------------------------
362 /**
363  * Default profile definition.
364  */
365 //--------------------------------------------------------------------------------------------------
366 #define LE_MDC_DEFAULT_PROFILE -1
367 
368 //--------------------------------------------------------------------------------------------------
369 /**
370  * Default profile definition for Bearer Independent Protocol (BIP).
371  */
372 //--------------------------------------------------------------------------------------------------
373 #define LE_MDC_SIMTOOLKIT_BIP_DEFAULT_PROFILE -2
374 
375 //--------------------------------------------------------------------------------------------------
376 /**
377  * @deprecated LE_MDC_DISC_USER_AUTHENTIFICATION_FAILURE is deprecated.
378  * LE_MDC_DISC_USER_AUTHENTICATION_FAILURE should be used instead.
379  */
380 //--------------------------------------------------------------------------------------------------
381 #define LE_MDC_DISC_USER_AUTHENTIFICATION_FAILURE 7
382 
383 //--------------------------------------------------------------------------------------------------
384 /**
385  * Reference to a modem data connection profile.
386  */
387 //--------------------------------------------------------------------------------------------------
388 typedef struct le_mdc_Profile* le_mdc_ProfileRef_t;
389 
390 
391 //--------------------------------------------------------------------------------------------------
392 /**
393  * Enumeration of data bearer technologies.
394  */
395 //--------------------------------------------------------------------------------------------------
396 typedef enum
397 {
399  ///< Unknown
401  ///< GSM
403  ///< GPRS
405  ///< Enhanced GPRS (EDGE)
407  ///< WCDMA (UMTS)
409  ///< HSPA
411  ///< HSPA+
413  ///< Dual Cell - HSPA+
415  ///< HSDPA
417  ///< HSUPA
419  ///< Dual Cell - HSUPA
421  ///< Dual Cell - HSPA
423  ///< LTE
425  ///< LTE FDD
427  ///< LTE TDD
429  ///< LTE CA DL
431  ///< LTE CA UL
433  ///< TD-SCDMA
435  ///< CDMA2000 1X
437  ///< CDMA2000 HRPD (1xEV-DO)
439  ///< CDMA2000 HRPD (1xEV-DO RevA)
441  ///< CDMA2000 EHRPD
443  ///< IS95 1X
445  ///< HDR REV0 DPA
447  ///< HDR REVA DPA
449  ///< HDR REVB DPA
451  ///< HDR REVA MPA
453  ///< HDR REVB MPA
455  ///< HDR REVA EMPA
457  ///< HDR REVB EMPA
459  ///< HDR REVB MMPA
461  ///< HDR EVDO FMC
463  ///< 64 QAM
465  ///< S2B
466 }
468 
469 
470 //--------------------------------------------------------------------------------------------------
471 /**
472  * Enumeration of Packet Data Protocol.
473  */
474 //--------------------------------------------------------------------------------------------------
475 typedef enum
476 {
478  ///< Unknown
480  ///< IPv4
482  ///< IPv6
484  ///< IPv4 and IPv6
485 }
487 
488 
489 //--------------------------------------------------------------------------------------------------
490 /**
491  * Authentication bit mask.
492  */
493 //--------------------------------------------------------------------------------------------------
494 typedef enum
495 {
496  LE_MDC_AUTH_NONE = 0x1, ///< no authentication
497  LE_MDC_AUTH_PAP = 0x2, ///< PAP protocol
498  LE_MDC_AUTH_CHAP = 0x4 ///< CHAP protocol
499 }
501 
502 
503 //--------------------------------------------------------------------------------------------------
504 /**
505  * Enumeration of connection state.
506  */
507 //--------------------------------------------------------------------------------------------------
508 typedef enum
509 {
511  ///< Data session is disconnected
513  ///< Authenticating data session
515  ///< Data session is connected
517  ///< Suspending data session
519  ///< Incoming data session (MT-PDP context request)
520 }
522 
523 
524 //--------------------------------------------------------------------------------------------------
525 /**
526  * Enumeration of the possible reasons for the disconnection.
527  */
528 //--------------------------------------------------------------------------------------------------
529 typedef enum
530 {
532  ///< Modem has no service
534  ///< cf. 3GPP 24.008 Annex I1
536  ///< cf. 3GPP 24.008 Annex I1
538  ///< cf. 3GPP 24.008 Annex I1
540  ///< cf. 3GPP 24.008 Annex I1
542  ///< cf. 3GPP 24.008 Annex I1
544  ///< cf. 3GPP 24.008 Annex I1
546  ///< cf. 3GPP 24.008 Annex I1
548  ///< cf. 3GPP 24.008 Annex I1
550  ///< cf. 3GPP 24.008 Annex I1
552  ///< cf. 3GPP 24.008 Annex I1
554  ///< cf. 3GPP 24.008 Annex I1
556  ///< cf. 3GPP 24.008 Annex I1
558  ///< cf. 3GPP 24.008 Annex I1
560  ///< cf. 3GPP 24.008 Annex I1
562  ///< cf. 3GPP 24.008 Annex I1
564  ///< cf. 3GPP 24.008 Annex I1
566  ///< cf. 3GPP 24.008 Annex I1
568  ///< cf. 3GPP 24.008 Annex I1
570  ///< cf. 3GPP 24.008 Annex I1
572  ///< cf. 3GPP 24.008 Annex I1
574  ///< cf. 3GPP 24.008 Annex I1
576  ///< cf. 3GPP 24.008 Annex I1
578  ///< cf. 3GPP 24.008 Annex I1
580  ///< cf. 3GPP 24.008 Annex I1
582  ///< cf. 3GPP 24.008 Annex I1
584  ///< cf. 3GPP 24.008 Annex I1
586  ///< cf. 3GPP 24.008 Annex I1
588  ///< cf. 3GPP 24.008 Annex I1
590  ///< cf. 3GPP 24.008 Annex I1
592  ///< cf. 3GPP 24.008 Annex I1
594  ///< cf. 3GPP 24.008 Annex I1
596  ///< cf. 3GPP 24.008 Annex I1
598  ///< cf. 3GPP 24.008 Annex I1
600  ///< cf. 3GPP 24.008 Annex I1
602  ///< cf. 3GPP 24.008 Annex I2
604  ///< cf. 3GPP 24.008 Annex I2
606  ///< cf. 3GPP 24.008 Annex I2
608  ///< cf. 3GPP 24.008 Annex I2
610  ///< cf. 3GPP 24.008 Annex I2
612  ///< cf. 3GPP 24.008 Annex I2
614  ///< cf. 3GPP 24.008 Annex I2
616  ///< cf. 3GPP 24.008 Annex I2
618  ///< cf. 3GPP 24.008 Annex I2
620  ///< Platform specific code.
622  ///< Undefined reason.
623 }
625 
626 
627 //--------------------------------------------------------------------------------------------------
628 /**
629  * Reference type used by Add/Remove functions for EVENT 'le_mdc_SessionState'
630  */
631 //--------------------------------------------------------------------------------------------------
632 typedef struct le_mdc_SessionStateHandler* le_mdc_SessionStateHandlerRef_t;
633 
634 
635 //--------------------------------------------------------------------------------------------------
636 /**
637  * Reference type used by Add/Remove functions for EVENT 'le_mdc_MtPdpSessionState'
638  */
639 //--------------------------------------------------------------------------------------------------
640 typedef struct le_mdc_MtPdpSessionStateHandler* le_mdc_MtPdpSessionStateHandlerRef_t;
641 
642 
643 //--------------------------------------------------------------------------------------------------
644 /**
645  * Handler for Data session connection state changes.
646  */
647 //--------------------------------------------------------------------------------------------------
648 typedef void (*le_mdc_SessionStateHandlerFunc_t)
649 (
650  le_mdc_ProfileRef_t profileRef,
651  ///< Profile reference
652  le_mdc_ConState_t ConnectionState,
653  ///< Data session connection state.
654  void* contextPtr
655  ///<
656 );
657 
658 //--------------------------------------------------------------------------------------------------
659 /**
660  * Handler for MT-PDP Data session connection state changes.
661  */
662 //--------------------------------------------------------------------------------------------------
664 (
665  le_mdc_ConState_t ConnectionState,
666  ///< MT-PDP Data session connection state.
667  void* contextPtr
668  ///<
669 );
670 
671 //--------------------------------------------------------------------------------------------------
672 /**
673  * Handler for asynchronous session start and stop result response
674  *
675  */
676 //--------------------------------------------------------------------------------------------------
677 typedef void (*le_mdc_SessionHandlerFunc_t)
678 (
679  le_mdc_ProfileRef_t profileRef,
680  ///< Profile reference
681  le_result_t result,
682  ///< Session start or stop result response
683  void* contextPtr
684  ///<
685 );
686 
687 //--------------------------------------------------------------------------------------------------
688 /**
689  * Add handler function for EVENT 'le_mdc_SessionState'
690  *
691  * This event provides information on data session connection state changes for the given profileRef.
692  *
693  */
694 //--------------------------------------------------------------------------------------------------
696 (
697  le_mdc_ProfileRef_t profileRef,
698  ///< [IN] The profile object of interest
700  ///< [IN]
701  void* contextPtr
702  ///< [IN]
703 );
704 
705 //--------------------------------------------------------------------------------------------------
706 /**
707  * Remove handler function for EVENT 'le_mdc_SessionState'
708  */
709 //--------------------------------------------------------------------------------------------------
711 (
713  ///< [IN]
714 );
715 
716 //--------------------------------------------------------------------------------------------------
717 /**
718  * Add handler function for EVENT 'le_mdc_MtPdpSessionState'
719  *
720  * This event provides information on data session connection state changes for the given profileRef.
721  *
722  */
723 //--------------------------------------------------------------------------------------------------
725 (
727  ///< [IN]
728  void* contextPtr
729  ///< [IN]
730 );
731 
732 //--------------------------------------------------------------------------------------------------
733 /**
734  * Remove handler function for EVENT 'le_mdc_MtPdpSessionState'
735  */
736 //--------------------------------------------------------------------------------------------------
738 (
740  ///< [IN]
741 );
742 
743 //--------------------------------------------------------------------------------------------------
744 /**
745  * Get Profile Reference for index
746  *
747  * @note Create a new profile if the profile's index can't be found.
748  *
749  * @warning 0 is not a valid index.
750  *
751  * @warning Ensure to check the list of supported data profiles for your specific platform.
752  *
753  * @return
754  * - Reference to the data profile
755  * - NULL if the profile index does not exist
756  */
757 //--------------------------------------------------------------------------------------------------
759 (
760  uint32_t index
761  ///< [IN] index of the profile.
762 );
763 
764 //--------------------------------------------------------------------------------------------------
765 /**
766  * Get the index for the given Profile.
767  *
768  * @return
769  * - index of the profile in the modem
770  *
771  * @note
772  * The process exits, if an invalid profile object is given
773  */
774 //--------------------------------------------------------------------------------------------------
775 uint32_t le_mdc_GetProfileIndex
776 (
777  le_mdc_ProfileRef_t profileRef
778  ///< [IN] Query this profile object
779 );
780 
781 //--------------------------------------------------------------------------------------------------
782 /**
783  * Start profile data session.
784  *
785  * @return
786  * - LE_OK on success
787  * - LE_BAD_PARAMETER if input parameter is incorrect
788  * - LE_DUPLICATE if the data session is already connected for the given profile
789  * - LE_FAULT for other failures
790  *
791  * @note
792  * The process exits, if an invalid profile object is given
793  */
794 //--------------------------------------------------------------------------------------------------
796 (
797  le_mdc_ProfileRef_t profileRef
798  ///< [IN] Start data session for this profile object
799 );
800 
801 //--------------------------------------------------------------------------------------------------
802 /**
803  * Start profile data session.
804  *
805  * @note
806  * The process exits, if an invalid profile object is given
807  */
808 //--------------------------------------------------------------------------------------------------
810 (
811  le_mdc_ProfileRef_t profileRef,
812  ///< [IN] Start data session for this profile object
813  le_mdc_SessionHandlerFunc_t handlerPtr,
814  ///< [IN] Handler for start data session result
815  void* contextPtr
816  ///< [IN]
817 );
818 
819 //--------------------------------------------------------------------------------------------------
820 /**
821  * Stop profile data session.
822  *
823  * @return
824  * - LE_OK on success
825  * - LE_BAD_PARAMETER if the input parameter is not valid
826  * - LE_FAULT for other failures
827  *
828  * @note
829  * The process exits, if an invalid profile object is given
830  *
831  * @warning The MT-PDP context activation feature is not supported on all platforms. Please refer to
832  * @ref MT-PDP_context section for full details.
833  */
834 //--------------------------------------------------------------------------------------------------
836 (
837  le_mdc_ProfileRef_t profileRef
838  ///< [IN] Stop data session for this profile object
839 );
840 
841 //--------------------------------------------------------------------------------------------------
842 /**
843  * Stop profile data session.
844  *
845  * @note
846  * The process exits, if an invalid profile object is given
847  */
848 //--------------------------------------------------------------------------------------------------
850 (
851  le_mdc_ProfileRef_t profileRef,
852  ///< [IN] Stop data session for this profile object
853  le_mdc_SessionHandlerFunc_t handlerPtr,
854  ///< [IN] Handler for stop data session result
855  void* contextPtr
856  ///< [IN]
857 );
858 
859 //--------------------------------------------------------------------------------------------------
860 /**
861  * Reject MT-PDP profile data session.
862  *
863  * @return
864  * - LE_OK on success
865  * - LE_BAD_PARAMETER if the input parameter is not valid
866  * - LE_UNSUPPORTED if not supported by the target
867  * - LE_FAULT for other failures
868  *
869  * @note
870  * The process exits, if an invalid profile object is given
871  *
872  * @warning The MT-PDP context activation feature is not supported on all platforms. Please refer to
873  * @ref MT-PDP_context section for full details.
874  */
875 //--------------------------------------------------------------------------------------------------
877 (
878  le_mdc_ProfileRef_t profileRef
879  ///< [IN] Reject MT-PDP data session for this profile object
880 );
881 
882 //--------------------------------------------------------------------------------------------------
883 /**
884  * Get the current data session state.
885  *
886  * @return
887  * - LE_OK on success
888  * - LE_BAD_PARAMETER if an input parameter is not valid
889  * - LE_FAULT on failure
890  *
891  * @note
892  * The process exits, if an invalid profile object is given
893  */
894 //--------------------------------------------------------------------------------------------------
896 (
897  le_mdc_ProfileRef_t profileRef,
898  ///< [IN] Query this profile object
899  le_mdc_ConState_t* connectionStatePtr
900  ///< [OUT] The data session state
901 );
902 
903 //--------------------------------------------------------------------------------------------------
904 /**
905  * Get the network interface name, if the data session is connected.
906  *
907  * @return
908  * - LE_OK on success
909  * - LE_OVERFLOW if the interface name would not fit in interfaceNameStr
910  * - LE_FAULT for all other errors
911  *
912  * @note
913  * The process exits, if an invalid profile object is given
914  */
915 //--------------------------------------------------------------------------------------------------
917 (
918  le_mdc_ProfileRef_t profileRef,
919  ///< [IN] Query this profile object
920  char* interfaceName,
921  ///< [OUT] The name of the network interface
922  size_t interfaceNameSize
923  ///< [IN]
924 );
925 
926 //--------------------------------------------------------------------------------------------------
927 /**
928  * Get the IPv4 address for the given profile, if the data session is connected and has an IPv4
929  * address.
930  *
931  * @return
932  * - LE_OK on success
933  * - LE_OVERFLOW if the IP address would not fit in ipAddrStr
934  * - LE_FAULT for all other errors
935  *
936  * @note
937  * The process exits, if an invalid profile object is given
938  */
939 //--------------------------------------------------------------------------------------------------
941 (
942  le_mdc_ProfileRef_t profileRef,
943  ///< [IN] Query this profile object
944  char* ipAddr,
945  ///< [OUT] The IP address in dotted format
946  size_t ipAddrSize
947  ///< [IN]
948 );
949 
950 //--------------------------------------------------------------------------------------------------
951 /**
952  * Get the gateway IPv4 address for the given profile, if the data session is connected and has an
953  * IPv4 address.
954  *
955  * @return
956  * - LE_OK on success
957  * - LE_OVERFLOW if the IP address would not fit in gatewayAddrStr
958  * - LE_FAULT for all other errors
959  *
960  * @note
961  * The process exits, if an invalid profile object is given
962  */
963 //--------------------------------------------------------------------------------------------------
965 (
966  le_mdc_ProfileRef_t profileRef,
967  ///< [IN] Query this profile object
968  char* gatewayAddr,
969  ///< [OUT] The gateway IP address in dotted format
970  size_t gatewayAddrSize
971  ///< [IN]
972 );
973 
974 //--------------------------------------------------------------------------------------------------
975 /**
976  * Get the primary/secondary DNS v4 addresses for the given profile, if the data session is
977  * connected and has an IPv4 address.
978  *
979  * @return
980  * - LE_OK on success
981  * - LE_OVERFLOW if the IP address would not fit in buffer
982  * - LE_FAULT for all other errors
983  *
984  * @note
985  * - If only one DNS address is available, then it will be returned, and an empty string will
986  * be returned for the unavailable address
987  * - The process exits, if an invalid profile object is given
988  */
989 //--------------------------------------------------------------------------------------------------
991 (
992  le_mdc_ProfileRef_t profileRef,
993  ///< [IN] Query this profile object
994  char* dns1AddrStr,
995  ///< [OUT] The primary DNS IP address in dotted format
996  size_t dns1AddrStrSize,
997  ///< [IN]
998  char* dns2AddrStr,
999  ///< [OUT] The secondary DNS IP address in dotted format
1000  size_t dns2AddrStrSize
1001  ///< [IN]
1002 );
1003 
1004 //--------------------------------------------------------------------------------------------------
1005 /**
1006  * Get the IPv6 address for the given profile, if the data session is connected and has an IPv6
1007  * address.
1008  *
1009  * @return
1010  * - LE_OK on success
1011  * - LE_OVERFLOW if the IP address would not fit in ipAddrStr
1012  * - LE_FAULT for all other errors
1013  *
1014  * @note
1015  * The process exits, if an invalid profile object is given
1016  */
1017 //--------------------------------------------------------------------------------------------------
1019 (
1020  le_mdc_ProfileRef_t profileRef,
1021  ///< [IN] Query this profile object
1022  char* ipAddr,
1023  ///< [OUT] The IP address in dotted format
1024  size_t ipAddrSize
1025  ///< [IN]
1026 );
1027 
1028 //--------------------------------------------------------------------------------------------------
1029 /**
1030  * Get the gateway IPv6 address for the given profile, if the data session is connected and has an
1031  * IPv6 address.
1032  *
1033  * @return
1034  * - LE_OK on success
1035  * - LE_OVERFLOW if the IP address would not fit in gatewayAddrStr
1036  * - LE_FAULT for all other errors
1037  *
1038  * @note
1039  * The process exits, if an invalid profile object is given
1040  */
1041 //--------------------------------------------------------------------------------------------------
1043 (
1044  le_mdc_ProfileRef_t profileRef,
1045  ///< [IN] Query this profile object
1046  char* gatewayAddr,
1047  ///< [OUT] The gateway IP address in dotted format
1048  size_t gatewayAddrSize
1049  ///< [IN]
1050 );
1051 
1052 //--------------------------------------------------------------------------------------------------
1053 /**
1054  * Get the primary/secondary DNS v6 addresses, if the data session is connected and has an IPv6
1055  * address.
1056  *
1057  * @return
1058  * - LE_OK on success
1059  * - LE_OVERFLOW if the IP address can't fit in buffer
1060  * - LE_FAULT for all other errors
1061  *
1062  * @note
1063  * - If only one DNS address is available, it will be returned, and an empty string will
1064  * be returned for the unavailable address.
1065  * - The process exits, if an invalid profile object is given
1066  */
1067 //--------------------------------------------------------------------------------------------------
1069 (
1070  le_mdc_ProfileRef_t profileRef,
1071  ///< [IN] Query this profile object
1072  char* dns1AddrStr,
1073  ///< [OUT] The primary DNS IP address in dotted format
1074  size_t dns1AddrStrSize,
1075  ///< [IN]
1076  char* dns2AddrStr,
1077  ///< [OUT] The secondary DNS IP address in dotted format
1078  size_t dns2AddrStrSize
1079  ///< [IN]
1080 );
1081 
1082 //--------------------------------------------------------------------------------------------------
1083 /**
1084  * Allow the caller to know if the given profile is actually supporting IPv4, if the data session
1085  * is connected.
1086  *
1087  * @return TRUE if PDP type is IPv4, FALSE otherwise.
1088  *
1089  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1090  * function will not return.
1091  */
1092 //--------------------------------------------------------------------------------------------------
1093 bool le_mdc_IsIPv4
1094 (
1095  le_mdc_ProfileRef_t profileRef
1096  ///< [IN] Query this profile object
1097 );
1098 
1099 //--------------------------------------------------------------------------------------------------
1100 /**
1101  * Allow the caller to know if the given profile is actually supporting IPv6, if the data session
1102  * is connected.
1103  *
1104  * @return TRUE if PDP type is IPv6, FALSE otherwise.
1105  *
1106  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1107  * function will not return.
1108  */
1109 //--------------------------------------------------------------------------------------------------
1110 bool le_mdc_IsIPv6
1111 (
1112  le_mdc_ProfileRef_t profileRef
1113  ///< [IN] Query this profile object
1114 );
1115 
1116 //--------------------------------------------------------------------------------------------------
1117 /**
1118  * Get the Data Bearer Technology for the given profile, if the data session is connected.
1119  *
1120  * @return
1121  * - LE_OK on success
1122  * - LE_FAULT for all other errors
1123  *
1124  * @note
1125  * The process exits, if an invalid profile object is given
1126  */
1127 //--------------------------------------------------------------------------------------------------
1129 (
1130  le_mdc_ProfileRef_t profileRef,
1131  ///< [IN] Query this profile object
1132  le_mdc_DataBearerTechnology_t* downlinkDataBearerTechPtrPtr,
1133  ///< [OUT] downlink data bearer technology
1134  le_mdc_DataBearerTechnology_t* uplinkDataBearerTechPtrPtr
1135  ///< [OUT] uplink data bearer technology
1136 );
1137 
1138 //--------------------------------------------------------------------------------------------------
1139 /**
1140  * Get number of bytes received/transmitted without error since the last reset.
1141  *
1142  * @return
1143  * - LE_OK on success
1144  * - LE_FAULT for all other errors
1145  *
1146  * @note
1147  * - The process exits, if an invalid pointer is given
1148  */
1149 //--------------------------------------------------------------------------------------------------
1151 (
1152  uint64_t* rxBytesPtr,
1153  ///< [OUT] bytes amount received since the last counter reset
1154  uint64_t* txBytesPtr
1155  ///< [OUT] bytes amount transmitted since the last counter reset
1156 );
1157 
1158 //--------------------------------------------------------------------------------------------------
1159 /**
1160  * Reset received/transmitted data flow statistics
1161  *
1162  * @return
1163  * - LE_OK on success
1164  * - LE_FAULT for all other errors
1165  */
1166 //--------------------------------------------------------------------------------------------------
1168 (
1169  void
1170 );
1171 
1172 //--------------------------------------------------------------------------------------------------
1173 /**
1174  * Stop collecting received/transmitted data flow statistics
1175  *
1176  * @return
1177  * - LE_OK on success
1178  * - LE_FAULT for all other errors
1179  */
1180 //--------------------------------------------------------------------------------------------------
1182 (
1183  void
1184 );
1185 
1186 //--------------------------------------------------------------------------------------------------
1187 /**
1188  * Start collecting received/transmitted data flow statistics
1189  *
1190  * @return
1191  * - LE_OK on success
1192  * - LE_FAULT for all other errors
1193  */
1194 //--------------------------------------------------------------------------------------------------
1196 (
1197  void
1198 );
1199 
1200 //--------------------------------------------------------------------------------------------------
1201 /**
1202  * Set the Packet Data Protocol (PDP) for the given profile.
1203  *
1204  * @return
1205  * - LE_OK on success
1206  * - LE_BAD_PARAMETER if the PDP is not supported
1207  * - LE_FAULT if the data session is currently connected for the given profile
1208  *
1209  * @note
1210  * The process exits, if an invalid profile object is given
1211  */
1212 //--------------------------------------------------------------------------------------------------
1214 (
1215  le_mdc_ProfileRef_t profileRef,
1216  ///< [IN] Query this profile object
1217  le_mdc_Pdp_t pdp
1218  ///< [IN] The Packet Data Protocol
1219 );
1220 
1221 //--------------------------------------------------------------------------------------------------
1222 /**
1223  * Get the Packet Data Protocol (PDP) for the given profile.
1224  *
1225  * @return
1226  * - packet data protocol value
1227  *
1228  * @note
1229  * The process exits, if an invalid profile object is given
1230  */
1231 //--------------------------------------------------------------------------------------------------
1233 (
1234  le_mdc_ProfileRef_t profileRef
1235  ///< [IN] Query this profile object
1236 );
1237 
1238 //--------------------------------------------------------------------------------------------------
1239 /**
1240  * Set the Access Point Name (APN) for the given profile.
1241  *
1242  * The APN must be an ASCII string.
1243  *
1244  * @return
1245  * - LE_OK on success
1246  * - LE_BAD_PARAMETER if an input parameter is not valid
1247  * - LE_FAULT if the data session is currently connected for the given profile
1248  *
1249  * @note If APN is too long (max APN_NAME_MAX_LEN digits), it is a fatal error, the
1250  * function will not return.
1251  *
1252  * @warning The maximum APN length might be limited by the platform.
1253  * Please refer to the platform documentation @ref platformConstraintsMdc.
1254  *
1255  * @note
1256  * The process exits, if an invalid profile object is given
1257  */
1258 //--------------------------------------------------------------------------------------------------
1260 (
1261  le_mdc_ProfileRef_t profileRef,
1262  ///< [IN] Query this profile object
1263  const char* LE_NONNULL apnStr
1264  ///< [IN] The Access Point Name
1265 );
1266 
1267 //--------------------------------------------------------------------------------------------------
1268 /**
1269  * Set the Access Point Name (APN) for the given profile according to the SIM identification
1270  * number (ICCID). If no APN is found using the ICCID, fall back on the home network (MCC/MNC)
1271  * to determine the default APN.
1272  *
1273  * @return
1274  * - LE_OK on success
1275  * - LE_BAD_PARAMETER if an input parameter is not valid
1276  * - LE_FAULT for all other errors
1277  *
1278  * @note
1279  * The process exits if an invalid profile object is given
1280  */
1281 //--------------------------------------------------------------------------------------------------
1283 (
1284  le_mdc_ProfileRef_t profileRef
1285  ///< [IN] Query this profile object
1286 );
1287 
1288 //--------------------------------------------------------------------------------------------------
1289 /**
1290  * Get the Access Point Name (APN) for the given profile.
1291  *
1292  * @return
1293  * - LE_OK on success
1294  * - LE_BAD_PARAMETER if an input parameter is not valid
1295  * - LE_OVERFLOW if the APN is is too long
1296  * - LE_FAULT on failed
1297  *
1298  * @note
1299  * The process exits, if an invalid profile object is given
1300  */
1301 //--------------------------------------------------------------------------------------------------
1303 (
1304  le_mdc_ProfileRef_t profileRef,
1305  ///< [IN] Query this profile object
1306  char* apnStr,
1307  ///< [OUT] The Access Point Name
1308  size_t apnStrSize
1309  ///< [IN]
1310 );
1311 
1312 //--------------------------------------------------------------------------------------------------
1313 /**
1314  * Set authentication property
1315  *
1316  * @return
1317  * - LE_OK on success
1318  *
1319  * @note
1320  * - The process exits, if userName or password are NULL when type is not PA_MDC_AUTH_NONE
1321  * - The process exits, if an invalid profile object is given
1322  * @note If userName is too long (max USER_NAME_MAX_LEN digits), it is a fatal error, the
1323  * function will not return.
1324  * @note If password is too long (max PASSWORD_NAME_MAX_LEN digits), it is a fatal error, the
1325  * function will not return.
1326  * @note Both PAP and CHAP authentication can be set for 3GPP network: in this case, the device
1327  * decides which authentication procedure is performed. For example, the device can have a
1328  * policy to select the most secure authentication mechanism.
1329  *
1330  */
1331 //--------------------------------------------------------------------------------------------------
1333 (
1334  le_mdc_ProfileRef_t profileRef,
1335  ///< [IN] Query this profile object
1336  le_mdc_Auth_t type,
1337  ///< [IN] Authentication type
1338  const char* LE_NONNULL userName,
1339  ///< [IN] UserName used by authentication
1340  const char* LE_NONNULL password
1341  ///< [IN] Password used by authentication
1342 );
1343 
1344 //--------------------------------------------------------------------------------------------------
1345 /**
1346  * Get authentication property
1347  *
1348  * @return
1349  * - LE_OK on success
1350  * - LE_BAD_PARAMETER if an input parameter is not valid
1351  * - LE_OVERFLOW userName or password are too small
1352  * - LE_FAULT on failed
1353  *
1354  * @note
1355  * The process exits, if an invalid profile object is given
1356  */
1357 //--------------------------------------------------------------------------------------------------
1359 (
1360  le_mdc_ProfileRef_t profileRef,
1361  ///< [IN] Query this profile object
1362  le_mdc_Auth_t* typePtr,
1363  ///< [OUT] Authentication type
1364  char* userName,
1365  ///< [OUT] UserName used by authentication
1366  size_t userNameSize,
1367  ///< [IN]
1368  char* password,
1369  ///< [OUT] Password used by authentication
1370  size_t passwordSize
1371  ///< [IN]
1372 );
1373 
1374 //--------------------------------------------------------------------------------------------------
1375 /**
1376  * Get the number of profiles on the modem.
1377  *
1378  * @return
1379  * - number of profiles existing on modem
1380  */
1381 //--------------------------------------------------------------------------------------------------
1382 uint32_t le_mdc_NumProfiles
1383 (
1384  void
1385 );
1386 
1387 //--------------------------------------------------------------------------------------------------
1388 /**
1389  * Get a profile selected by its APN
1390  *
1391  * @return
1392  * - LE_OK on success
1393  * - LE_BAD_PARAMETER if an input parameter is not valid
1394  * - LE_NOT_FOUND if the requested APN is not found
1395  */
1396 //--------------------------------------------------------------------------------------------------
1398 (
1399  const char* LE_NONNULL apnStr,
1400  ///< [IN] The Access Point Name
1401  le_mdc_ProfileRef_t* profileRefPtr
1402  ///< [OUT] profile reference
1403 );
1404 
1405 //--------------------------------------------------------------------------------------------------
1406 /**
1407  * Called to get the disconnection reason.
1408  *
1409  * @return The disconnection reason.
1410  *
1411  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1412  * function will not return.
1413  */
1414 //--------------------------------------------------------------------------------------------------
1416 (
1417  le_mdc_ProfileRef_t profileRef
1418  ///< [IN] profile reference
1419 );
1420 
1421 //--------------------------------------------------------------------------------------------------
1422 /**
1423  * Called to get the platform specific disconnection code.
1424  *
1425  * Refer to @ref platformConstraintsSpecificErrorCodes for platform specific
1426  * disconnection code description.
1427  *
1428  * @return The platform specific disconnection code.
1429  *
1430  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1431  * function will not return.
1432  */
1433 //--------------------------------------------------------------------------------------------------
1435 (
1436  le_mdc_ProfileRef_t profileRef
1437  ///< [IN] profile reference
1438 );
1439 
1440 //--------------------------------------------------------------------------------------------------
1441 /**
1442  * Called to get the platform specific connection failure reason.
1443  *
1444  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1445  * function will not return.
1446  */
1447 //--------------------------------------------------------------------------------------------------
1449 (
1450  le_mdc_ProfileRef_t profileRef,
1451  ///< [IN] profile reference
1452  int32_t* failureTypePtr,
1453  ///< [OUT] platform specific failure type
1454  int32_t* failureCodePtr
1455  ///< [OUT] platform specific failure code
1456 );
1457 
1458 //--------------------------------------------------------------------------------------------------
1459 /**
1460  * Map a profile on a network interface
1461  *
1462  * * @return
1463  * - LE_OK on success
1464  * - LE_UNSUPPORTED if not supported by the target
1465  * - LE_FAULT for all other errors
1466  *
1467  */
1468 //--------------------------------------------------------------------------------------------------
1470 (
1471  le_mdc_ProfileRef_t profileRef,
1472  ///< [IN] Profile reference
1473  const char* LE_NONNULL interfaceName
1474  ///< [IN] Network interface name
1475 );
1476 
1477 #endif // LE_MDC_INTERFACE_H_INCLUDE_GUARD
le_result_t le_mdc_GetSessionState(le_mdc_ProfileRef_t profileRef, le_mdc_ConState_t *connectionStatePtr)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:585
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:545
le_mdc_SessionStateHandlerRef_t le_mdc_AddSessionStateHandler(le_mdc_ProfileRef_t profileRef, le_mdc_SessionStateHandlerFunc_t handlerPtr, void *contextPtr)
Suspending data session.
Definition: le_mdc_interface.h:516
Data session is disconnected.
Definition: le_mdc_interface.h:510
le_mdc_DataBearerTechnology_t
Definition: le_mdc_interface.h:396
le_mdc_Pdp_t le_mdc_GetPDP(le_mdc_ProfileRef_t profileRef)
void le_mdc_StartSessionAsync(le_mdc_ProfileRef_t profileRef, le_mdc_SessionHandlerFunc_t handlerPtr, void *contextPtr)
HDR REVB MPA.
Definition: le_mdc_interface.h:452
Dual Cell - HSPA+.
Definition: le_mdc_interface.h:412
le_result_t le_mdc_GetDataBearerTechnology(le_mdc_ProfileRef_t profileRef, le_mdc_DataBearerTechnology_t *downlinkDataBearerTechPtrPtr, le_mdc_DataBearerTechnology_t *uplinkDataBearerTechPtrPtr)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:573
le_result_t le_mdc_SetAPN(le_mdc_ProfileRef_t profileRef, const char *LE_NONNULL apnStr)
Data session is connected.
Definition: le_mdc_interface.h:514
Dual Cell - HSUPA.
Definition: le_mdc_interface.h:418
struct le_mdc_SessionStateHandler * le_mdc_SessionStateHandlerRef_t
Definition: le_mdc_interface.h:632
IPv4 and IPv6.
Definition: le_mdc_interface.h:483
le_result_t
Definition: le_basics.h:35
bool le_mdc_IsIPv4(le_mdc_ProfileRef_t profileRef)
IPv4.
Definition: le_mdc_interface.h:479
64 QAM
Definition: le_mdc_interface.h:462
Incoming data session (MT-PDP context request)
Definition: le_mdc_interface.h:518
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:617
Platform specific code.
Definition: le_mdc_interface.h:619
LTE TDD.
Definition: le_mdc_interface.h:426
le_mdc_Pdp_t
Definition: le_mdc_interface.h:475
le_mdc_DisconnectionReason_t
Definition: le_mdc_interface.h:529
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:611
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:567
le_result_t le_mdc_GetIPv4GatewayAddress(le_mdc_ProfileRef_t profileRef, char *gatewayAddr, size_t gatewayAddrSize)
HSUPA.
Definition: le_mdc_interface.h:416
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:599
le_result_t le_mdc_StopSession(le_mdc_ProfileRef_t profileRef)
le_result_t le_mdc_GetAPN(le_mdc_ProfileRef_t profileRef, char *apnStr, size_t apnStrSize)
void le_mdc_SetServerDisconnectHandler(le_mdc_DisconnectHandler_t disconnectHandler, void *contextPtr)
le_result_t le_mdc_GetIPv4DNSAddresses(le_mdc_ProfileRef_t profileRef, char *dns1AddrStr, size_t dns1AddrStrSize, char *dns2AddrStr, size_t dns2AddrStrSize)
le_result_t le_mdc_GetIPv6Address(le_mdc_ProfileRef_t profileRef, char *ipAddr, size_t ipAddrSize)
Undefined reason.
Definition: le_mdc_interface.h:621
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:615
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:539
void le_mdc_ConnectService(void)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:535
Authenticating data session.
Definition: le_mdc_interface.h:512
no authentication
Definition: le_mdc_interface.h:496
struct le_mdc_Profile * le_mdc_ProfileRef_t
Definition: le_mdc_interface.h:388
void le_mdc_StopSessionAsync(le_mdc_ProfileRef_t profileRef, le_mdc_SessionHandlerFunc_t handlerPtr, void *contextPtr)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:563
HDR REVB EMPA.
Definition: le_mdc_interface.h:456
HSPA+.
Definition: le_mdc_interface.h:410
S2B.
Definition: le_mdc_interface.h:464
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:605
le_result_t le_mdc_GetInterfaceName(le_mdc_ProfileRef_t profileRef, char *interfaceName, size_t interfaceNameSize)
le_result_t le_mdc_SetPDP(le_mdc_ProfileRef_t profileRef, le_mdc_Pdp_t pdp)
CHAP protocol.
Definition: le_mdc_interface.h:498
WCDMA (UMTS)
Definition: le_mdc_interface.h:406
void(* le_mdc_MtPdpSessionStateHandlerFunc_t)(le_mdc_ConState_t ConnectionState, void *contextPtr)
Definition: le_mdc_interface.h:664
HDR REVA DPA.
Definition: le_mdc_interface.h:446
HSPA.
Definition: le_mdc_interface.h:408
bool le_mdc_IsIPv6(le_mdc_ProfileRef_t profileRef)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:589
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:559
IS95 1X.
Definition: le_mdc_interface.h:442
Enhanced GPRS (EDGE)
Definition: le_mdc_interface.h:404
IPv6.
Definition: le_mdc_interface.h:481
Unknown.
Definition: le_mdc_interface.h:477
LTE FDD.
Definition: le_mdc_interface.h:424
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:583
Unknown.
Definition: le_mdc_interface.h:398
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:569
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:571
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:587
Dual Cell - HSPA.
Definition: le_mdc_interface.h:420
le_result_t le_mdc_GetBytesCounters(uint64_t *rxBytesPtr, uint64_t *txBytesPtr)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:555
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:609
CDMA2000 HRPD (1xEV-DO)
Definition: le_mdc_interface.h:436
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:597
le_mdc_DisconnectionReason_t le_mdc_GetDisconnectionReason(le_mdc_ProfileRef_t profileRef)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:577
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:607
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:603
void(* le_mdc_DisconnectHandler_t)(void *)
Definition: le_mdc_interface.h:200
le_result_t le_mdc_GetAuthentication(le_mdc_ProfileRef_t profileRef, le_mdc_Auth_t *typePtr, char *userName, size_t userNameSize, char *password, size_t passwordSize)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:553
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:537
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:613
void le_mdc_GetPlatformSpecificFailureConnectionReason(le_mdc_ProfileRef_t profileRef, int32_t *failureTypePtr, int32_t *failureCodePtr)
void le_mdc_RemoveSessionStateHandler(le_mdc_SessionStateHandlerRef_t handlerRef)
void le_mdc_RemoveMtPdpSessionStateHandler(le_mdc_MtPdpSessionStateHandlerRef_t handlerRef)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:551
le_result_t le_mdc_TryConnectService(void)
HDR REVB MMPA.
Definition: le_mdc_interface.h:458
le_mdc_ProfileRef_t le_mdc_GetProfile(uint32_t index)
Modem has no service.
Definition: le_mdc_interface.h:531
int32_t le_mdc_GetPlatformSpecificDisconnectionCode(le_mdc_ProfileRef_t profileRef)
LTE CA DL.
Definition: le_mdc_interface.h:428
HDR REVA EMPA.
Definition: le_mdc_interface.h:454
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:533
HDR EVDO FMC.
Definition: le_mdc_interface.h:460
CDMA2000 EHRPD.
Definition: le_mdc_interface.h:440
le_result_t le_mdc_StartSession(le_mdc_ProfileRef_t profileRef)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:595
le_result_t le_mdc_ResetBytesCounter(void)
void le_mdc_DisconnectService(void)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:575
struct le_mdc_MtPdpSessionStateHandler * le_mdc_MtPdpSessionStateHandlerRef_t
Definition: le_mdc_interface.h:640
le_result_t le_mdc_GetIPv4Address(le_mdc_ProfileRef_t profileRef, char *ipAddr, size_t ipAddrSize)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:581
HDR REVB DPA.
Definition: le_mdc_interface.h:448
HSDPA.
Definition: le_mdc_interface.h:414
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:593
le_result_t le_mdc_StartBytesCounter(void)
le_mdc_MtPdpSessionStateHandlerRef_t le_mdc_AddMtPdpSessionStateHandler(le_mdc_SessionStateHandlerFunc_t handlerPtr, void *contextPtr)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:541
le_result_t le_mdc_GetIPv6GatewayAddress(le_mdc_ProfileRef_t profileRef, char *gatewayAddr, size_t gatewayAddrSize)
le_mdc_ConState_t
Definition: le_mdc_interface.h:508
LTE.
Definition: le_mdc_interface.h:422
le_mdc_Auth_t
Definition: le_mdc_interface.h:494
le_result_t le_mdc_SetAuthentication(le_mdc_ProfileRef_t profileRef, le_mdc_Auth_t type, const char *LE_NONNULL userName, const char *LE_NONNULL password)
GPRS.
Definition: le_mdc_interface.h:402
le_result_t le_mdc_GetProfileFromApn(const char *LE_NONNULL apnStr, le_mdc_ProfileRef_t *profileRefPtr)
HDR REVA MPA.
Definition: le_mdc_interface.h:450
PAP protocol.
Definition: le_mdc_interface.h:497
uint32_t le_mdc_GetProfileIndex(le_mdc_ProfileRef_t profileRef)
uint32_t le_mdc_NumProfiles(void)
le_result_t le_mdc_SetDefaultAPN(le_mdc_ProfileRef_t profileRef)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:543
LTE CA UL.
Definition: le_mdc_interface.h:430
le_result_t le_mdc_StopBytesCounter(void)
le_result_t le_mdc_RejectMtPdpSession(le_mdc_ProfileRef_t profileRef)
void(* le_mdc_SessionHandlerFunc_t)(le_mdc_ProfileRef_t profileRef, le_result_t result, void *contextPtr)
Definition: le_mdc_interface.h:678
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:591
CDMA2000 HRPD (1xEV-DO RevA)
Definition: le_mdc_interface.h:438
void(* le_mdc_SessionStateHandlerFunc_t)(le_mdc_ProfileRef_t profileRef, le_mdc_ConState_t ConnectionState, void *contextPtr)
Definition: le_mdc_interface.h:649
GSM.
Definition: le_mdc_interface.h:400
HDR REV0 DPA.
Definition: le_mdc_interface.h:444
TD-SCDMA.
Definition: le_mdc_interface.h:432
le_result_t le_mdc_MapProfileOnNetworkInterface(le_mdc_ProfileRef_t profileRef, const char *LE_NONNULL interfaceName)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:565
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:579
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:561
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:557
cf. 3GPP 24.008 Annex I2
Definition: le_mdc_interface.h:601
CDMA2000 1X.
Definition: le_mdc_interface.h:434
le_result_t le_mdc_GetIPv6DNSAddresses(le_mdc_ProfileRef_t profileRef, char *dns1AddrStr, size_t dns1AddrStrSize, char *dns2AddrStr, size_t dns2AddrStrSize)
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:549
cf. 3GPP 24.008 Annex I1
Definition: le_mdc_interface.h:547