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