le_mrc_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_mrc Modem Radio Control
14  *
15  * @ref le_mrc_interface.h "API Reference"
16  *
17  * <HR>
18  *
19  * The Modem Radio Control (MRC) APIs is used to control cellular network environments.
20  *
21  * It's important for many M2M apps to know details about cellular network environments (like
22  * network registration and signal quality).
23  * It allows you to limit some M2M services based on the reliability of the network environment, and
24  * provides information to control power consumption (power on or shutdown the radio module).
25  *
26  * @section le_mrc_binding IPC interfaces binding
27  *
28  * All the functions of this API are provided by the @b modemService service.
29  *
30  * Here's a code sample binding to modem services:
31  * @verbatim
32  bindings:
33  {
34  clientExe.clientComponent.le_mrc -> modemService.le_mrc
35  }
36  @endverbatim
37  *
38  * @section le_mrc_power Radio Power Management
39  * le_mrc_SetRadioPower() API allows the application to power up or shutdown the radio module.
40  *
41  * le_mrc_GetRadioPower() API displays radio module power state.
42  *
43  * A sample code can be seen in the following page:
44  * - @subpage c_mrcRadioPower
45  *
46  * @section le_mrc_configuration Radio Configuration preferences
47  *
48  * The following functions let you configure and retrieve the radio configuration preferences:
49  * le_mrc_SetAutomaticRegisterMode(), le_mrc_SetManualRegisterMode() and le_mrc_GetRegisterMode()
50  * let you set/get the selected Scan mode.
51  *
52  * le_mrc_SetBandPreferences(), le_mrc_GetBandPreferences() let you set/get the 2G/3G band
53  * preferences by using a bit mask built with @c le_mrc_BandBitMask_t
54  *
55  * The 2G/3G band preferences can be:
56  * - Band-Class-0-A-System
57  * - Band-Class-0-B-System
58  * - Band-Class-1-All-Blocks
59  * - Band-Class-2-Placeholder
60  * - Band-Class-3-A-System
61  * - Band-Class-4-All-Blocks
62  * - Band-Class-5-All-Blocks
63  * - Band-Class-6
64  * - Band-Class-7
65  * - Band-Class-8
66  * - Band-Class-9
67  * - Band-Class-10
68  * - Band-Class-11
69  * - Band-Class-12
70  * - Band-Class-13
71  * - Band-Class-14
72  * - Band-Class-15
73  * - Band-Class-16
74  * - Band-Class-17
75  * - Band-Class-18
76  * - Band-Class-19
77  * - GSM-DCS-1800
78  * - E-GSM-900 (for Extended GSM 900 band)
79  * - Primary-GSM-900
80  * - GSM-450
81  * - GSM-480
82  * - GSM-750
83  * - GSM-850
84  * - GSMR-900 (for GSM Railways GSM 900 band)
85  * - GSM-PCS-1900
86  * - WCDMA-EU-J-CH-IMT-2100 (for WCDMA Europe, Japan, and China IMT 2100 band)
87  * - WCDMA-US-PCS-1900 (for WCDMA U.S. PCS 1900 band)
88  * - WCDMA-EU-CH-DCS-1800 (for WCDMA Europe and China DCS 1800 band)
89  * - WCDMA-US-1700 (for WCDMA U.S. 1700 band)
90  * - WCDMA-US-850 (for WCDMA U.S. 850 band)
91  * - WCDMA-J-800 (for WCDMA Japan 800 band)
92  * - WCDMA-EU-2600 (for WCDMA Europe 2600 band)
93  * - WCDMA-EU-J-900 (for WCDMA Europe and Japan 900 band)
94  * - WCDMA-J-1700 (for WCDMA Japan 1700 band)
95  *
96  * le_mrc_SetLteBandPreferences(), le_mrc_GetLteBandPreferences() let you set/get the LTE band
97  * preferences by using a bit mask built with @c le_mrc_LteBandBitMask_t.
98  *
99  * The LTE band preferences can be 0 to 43 except 15, 16, 22, 23, and 26 to 32.
100  *
101  * le_mrc_SetTdScdmaBandPreferences(), le_mrc_GetTdScdmaBandPreferences() let you set/get the
102  * TD-SCDMA band preferences by using a bit mask built with @c le_mrc_TdScdmaBandBitMask_t
103  *
104  * The TD-SCDMA band preferences can be 'A' to 'F'
105  *
106  * @warning Ensure to check the supported preferences for your specific platform.
107  *
108  * le_mrc_AddPreferredOperator() , le_mrc_RemovePreferredOperator() to add/remove a preferred
109  * operator by specifying the MCC/MNC and the Radio Access Technology.
110  *
111  * le_mrc_GetPreferredOperatorsList(), le_mrc_GetFirstPreferredOperator(),
112  * le_mrc_GetNextPreferredOperator(), le_mrc_DeletePreferredOperatorsList(),
113  * le_mrc_GetPreferredOperatorDetails() let you retrieve a list of the selected preferred
114  * operators and get their details.
115  *
116  * A sample code can be seen in the following page:
117  * - @subpage c_mrcRadioConfigurationPreferences
118  *
119  * @section le_mrc_AddNetRegRejectHandler Report Network Registration Reject Indication
120  *
121  * The application can register a handler function to report network reject with reject cause,
122  * reject service domain, MNC/MCC code and the Radio Access Technology using
123  * le_mrc_AddNetRegRejectHandler() API (le_mrc_AddNetworkRejectHandler() will be deprecated).
124  *
125  * le_mrc_RemoveNetRegRejectHandler() API uninstalls the handler function.
126  *
127  * @deprecated le_mrc_NetworkRejectHandler() will be removed in near future.
128  * It will be replaced by le_mrc_AddNetRegRejectHandler().
129  *
130  * le_mrc_NetworkRejectHandler Report Network Reject Indication
131  *
132  * The application can register a handler function to report network reject with MNC/MCC code and
133  * the Radio Access Technology using le_mrc_AddNetworkRejectHandler() API.
134  *
135  * le_mrc_RemoveNetworkRejectHandler() API uninstalls the handler function.
136  *
137  * @section le_mrc_capabilities Radio Capabilities
138  *
139  * le_mrc_GetBandCapabilities() let you get the 2G/3G band capabilities by retrieving a bit mask
140  * built with @c le_mrc_BandBitMask_t
141  *
142  * le_mrc_GetLteBandCapabilities() let you get the LTE band capabilities by retrieving a bit mask
143  * built with @c le_mrc_LteBandBitMask_t
144  *
145  * le_mrc_GetTdScdmaBandCapabilities() let you get the TD-SCDMA band capabilities by retrieving
146  * a bit mask built with @c le_mrc_TdScdmaBandBitMask_t
147  *
148  * A sample code can be seen in the following page:
149  * - @subpage c_mrcBandCapabilities
150  *
151  * @section le_mrc_rat Radio Access Technology (RAT)
152  * le_mrc_GetRadioAccessTechInUse() API retrieves the current active Radio Access Technology (RAT).
153  * @note The API returns the RAT only if the device is registered on the network.
154  *
155  * The application can register a handler function to retrieve the Radio Access Technology each time
156  * the RAT changes.
157  *
158  * le_mrc_AddRatChangeHandler() API installs a RAT change handler.
159  *
160  * le_mrc_RemoveRatChangeHandler() API uninstalls the handler function.
161  *
162  * le_mrc_SetRatPreferences(), le_mrc_GetRatPreferences() let you set/get the Radio Access
163  * Technology preferences by using a bit mask built with @c le_mrc_RatBitMask_t.
164  *
165  * The Radio Access Technology preferences can be:
166  * - CDMA (CDMA2000-1X + CDMA2000-HRPD)
167  * - GSM
168  * - UMTS (UMTS)
169  * - TDSCDMA (TD-SCDMA)
170  * - LTE
171  *
172  * @note LE_MRC_BITMASK_RAT_ALL value can be used to select the RAT in automatic mode.
173  *
174  * A sample code can be seen in the following page:
175  * - @subpage c_mrcRAT
176  *
177  * @section le_mrc_registration Network Registration
178  * le_mrc_GetNetRegState() API retrieves the radio module network registration status.
179  *
180  * The application can register a handler function to retrieve the registration status each time the
181  * registration state changes.
182  *
183  * le_mrc_AddNetRegStateEventHandler() API installs a registration state handler.
184  *
185  * le_mrc_RemoveNetRegStateEventHandler() API uninstalls the handler function.
186  * @note If only one handler is registered, the le_mrc_RemoveNetRegStateHandler() API
187  * resets the registration mode to its original value before any handler functions were added.
188  *
189  * le_mrc_SetManualRegisterMode() API registers on a cellular network.
190  *
191  * Call le_mrc_SetManualRegisterModeAsync() function to set the manual registration mode
192  * asynchronously. The function is not blocking. The response will be returned with the
193  * @c le_mrc_ManualSelectionHandlerFunc_t handler function.
194  *
195  * When the network registration fails, the platform specific network registration error code can
196  * be known by using le_mrc_GetPlatformSpecificRegistrationErrorCode() API.
197  * Please refer to @ref platformConstraintsSpecificErrorCodes for platform specific
198  * registration error code description.
199  *
200  * A sample code can be seen in the following page:
201  * - @subpage c_mrcNetworkRegistration
202  *
203  * @section le_mrc_service Packet services state
204  *
205  * le_mrc_GetPacketSwitchedState() API retrieves the current Packet Switched state
206  * @ref le_mrc_NetRegState_t.
207  *
208  * The Packet Switched services state can be:
209  * - NONE
210  * - HOME
211  * - ROAMING
212  *
213  * The application can register a handler function to retrieve the Packet
214  * Switched state each time the service state changes.
215  *
216  * le_mrc_AddPacketSwitchedChangeHandler() API installs a Packet Switched state handler.
217  *
218  * le_mrc_RemovePacketSwitchedChangeHandler() API uninstalls the handler function.
219  *
220  * A sample code can be seen in the following page:
221  * - @subpage c_mrcGetService
222  *
223  * @section le_mrc_signal Signal Quality
224  *
225  * le_mrc_GetSignalQual() retrieves the received signal strength details.
226  *
227  * You must call le_mrc_MeasureSignalMetrics() to measure the signal metrics of the serving cell
228  * (aka the 'serving' cell). It returns a reference of le_mrc_MetricsRef_t type.
229  *
230  * When the signal metrics are no longer needed, you must call le_mrc_DeleteSignalMetrics() to free
231  * all allocated ressources associated with the Metrics object.
232  *
233  * le_mrc_GetRatOfSignalMetrics() returns the Radio Access Technology of the signal measures.
234  *
235  * le_mrc_GetGsmSignalMetrics() the signal strength in dBm and the bit error rate measured on GSM
236  * network.
237  *
238  * le_mrc_GetUmtsSignalMetrics() returns the signal metrics measured on UMTS or TD-SCDMA networks.
239  *
240  * le_mrc_GetLteSignalMetrics() returns the signal metrics measured on LTE network.
241  *
242  * le_mrc_GetCdmaSignalMetrics() returns the signal metrics measured on CDMA network.
243  *
244  * The application can register a handler function to get notifications when the signal strength
245  * changes of a certain threshold value.
246  *
247  * le_mrc_AddSignalStrengthChangeHandler() API installs a signal strength change handler.
248  * The RAT, the lower-range and the upper-range thresholds must be passed as input parameters. These
249  * parameters are updated each time the function is called, the previous thresholds are replaced by
250  * the new ones if the function is called with the same RAT. The event is notified when we cross the
251  * range limits in both direction.
252  *
253  * @warning A fatal error will be thrown if the RAT is not valid and the
254  * le_mrc_AddSignalStrengthChangeHandler function won't return.
255  *
256  * le_mrc_RemoveSignalStrengthChangeHandler() API uninstalls the handler function.
257  *
258  * le_mrc_SetSignalStrengthIndThresholds() API changes or sets new thresholds.
259  *
260  * le_mrc_SetSignalStrengthIndDelta() API sets a signal strength indication delta value for a
261  * specific RAT. The event is notified when the delta range is crossed in both direction.
262  *
263  * A sample code can be seen in the following page:
264  * - @subpage c_mrcQuality
265  *
266  * @section le_mrc_location Serving cell's location information
267  *
268  * le_mrc_GetServingCellId() retrieves the the serving Cell Identifier.
269  *
270  * le_mrc_GetServingCellLocAreaCode() retrieves the Location Area Code of the serving cell.
271  *
272  * le_mrc_GetServingCellLteTracAreaCode() retrieves the Tracking Area Code of the serving cell
273  * (LTE only).
274  *
275  * le_mrc_GetServingCellEarfcn() retrieves the serving cell E-UTRA Absolute Radio Frequency
276  * Channel Number (EARFCN, defined in 3GPP TS 36.101). The EARFCN is in the range from 0 to 262143.
277  *
278  * le_mrc_GetServingCellTimingAdvance() retrieves the serving cell timing advance index value.
279  * UINT32_MAX value is returned if the value is not available. The index value returned is defined
280  * by 3GPP 36.213. The index value is in the range from 0 to 1280.
281  *
282  * le_mrc_GetPhysicalServingLteCellId() retrieves the physical serving cell Id in LTE. The physical
283  * cell Id is in the range from 0 to 503.
284  *
285  * le_mrc_GetServingCellGsmBsic() retrieves the Base Station Identity Code (BSIC) for the serving
286  * cell on GSM network.
287  *
288  * The BSIC is a local colour code (CC) that allows a Mobile Station (MS) to distinguish between
289  * different neighbouring base stations. BSIC is a 6-bit length code structured the following way:
290  * NCC (PLMN colour code) 3 bits + BCC (BS colour code) 3 bits. More information is available
291  * under the 3GPP reference 23.003 (Base Station Identify Code (BSIC) )
292  *
293  * A sample code can be seen in the following page:
294  * - @subpage c_mrcLocationinformation
295  *
296  * @section le_mrc_network_information Current Network Information
297  * le_mrc_GetCurrentNetworkName() retrieves the Current Network Name.
298  * le_mrc_GetCurrentNetworkMccMnc() retrieves the Current Network PLMN information.
299  *
300  * A sample code can be seen in the following page:
301  * - @subpage c_mrcGetCurrentNetwork
302  *
303  * @section le_mrc_networkScan Network Scan
304  *
305  * Call le_mrc_PerformCellularNetworkScan() to fill a list of all network in sight.
306  * You can go through all Scan Information by calling le_mrc_GetFirstCellularNetworkScan() and
307  * le_mrc_GetNextCellularNetworkScan().
308  *
309  * Call le_mrc_PerformCellularNetworkScanAsync() to start a network scan asynchronously. The
310  * function is not blocking. The scan list reference will be returned with the handler function
311  * response (@c le_mrc_CellularNetworkScanHandlerFunc_t).
312  *
313  * For each Scan Information, you can call:
314  *
315  * - le_mrc_GetCellularNetworkMccMnc() to have the operator code.
316  * - le_mrc_GetCellularNetworkName() to get the operator name.
317  * - le_mrc_GetCellularNetworkRat() to get the radio access technology.
318  * - le_mrc_IsCellularNetworkInUse() to check if this is currently in use by the network.
319  * - le_mrc_IsCellularNetworkAvailable() to check if this is available.
320  * - le_mrc_IsCellularNetworkHome() to check if this is in home status.
321  * - le_mrc_IsCellularNetworkForbidden() to check if this is forbidden by the network.
322  *
323  * le_mrc_DeleteCellularNetworkScan() should be called when you do not need the list anymore.
324  *
325  * A sample code can be seen in the following page:
326  * - @subpage c_mrcNetworkScan
327  *
328  * @section le_mrc_PcinetworkScan PCI Network Scan
329  *
330  * Call le_mrc_PerformPciNetworkScan() to fill a list of all neighboring cells.
331  * The Pci scan is used to get the according MCC/MNC for each neightboring cells ID. Not that a cell
332  * may contain more than one MCC/MNC when sevral plmn sharing the same cell.
333  *
334  * You can go through all Scan Information by calling le_mrc_GetFirstPciScanInfo() and
335  * le_mrc_GetNextPciScanInfo(). Note that each cell info contains a list of mcc/mnc, you can go
336  * through all mcc/mnc Information for each cell by calling le_mrc_GetFirstPlmnInfo()
337  * and le_mrc_GetNextPlmnInfo(), this two APIs return a reference to PlmnInformation, then use
338  * le_mrc_GetPciScanMccMnc() by giving this reference as parameter to get the Mcc/Mnc of the Plmn.
339  *
340  * Call le_mrc_PerformPciNetworkScanAsync()to start a pci scan asynchronously. The
341  * function is not blocking. The scan list reference will be returned with the handler function
342  * response (@c le_mrc_PciNetworkScanHandlerFunc_t).
343  *
344  *
345  * For Pci Network Scan Information, you can call:
346  *
347  * - le_mrc_GetPciScanCellId() to get the physical id of each cell.
348  * - le_mrc_GetPciScanGlobalCellId() to get the global id of each cell.
349  * - le_mrc_GetPciScanMccMnc() to get the Mcc/Mnc of each plmn on each cell.
350  * - le_mrc_DeletePciNetworkScan() should be called when you do not need the list anymore.
351  *
352  * A sample code can be seen in the following page:
353  * - @subpage c_mrcPciScan
354  *
355  * @section le_mrc_ngbr Neighboring Cells Information
356  *
357  * @warning The following functions do not apply to CDMA network.
358  *
359  * You must call le_mrc_GetNeighborCellsInfo() to retrieve the neighboring cells
360  * information. It returns a reference of le_mrc_NeighborCellsRef_t type.
361  *
362  * When the neighboring cells information is no longer needed, you must call
363  * le_mrc_DeleteNeighborCellsInfo() to free all allocated resources associated with the
364  * object.
365  *
366  * Then, you can use the following function to get the information:
367  * - le_mrc_GetFirstNeighborCellInfo() and le_mrc_GetFirstNeighborCellInfo() allow to go among
368  * the single cell information retrieved with le_mrc_GetNeighborCellsInfo(). These two functions
369  * return a reference of le_mrc_CellInfoRef_t type.
370  * - le_mrc_GetNeighborCellId() gets the identifier of the cell specified with the
371  * le_mrc_CellInfoRef_t parameter (can be called for any kind of RAT). UINT32_MAX value is
372  * returned if the value is not available.
373  * - le_mrc_GetNeighborCellLocAreaCode() gets the location area code of the cell specified with the
374  * le_mrc_CellInfoRef_t parameter (can be called for any kind of RAT). UINT16_MAX value is
375  * returned if the value is not available.
376  * - le_mrc_GetNeighborCellRxLevel() gets the signal strength (in dBm) of the cell specified with
377  * the le_mrc_CellInfoRef_t parameter (can be called for any kind of RAT).
378  * - le_mrc_GetNeighborCellRat() gets the Radio Access Technology of the cell specified with
379  * the le_mrc_CellInfoRef_t parameter.
380  * - le_mrc_GetNeighborCellUmtsEcIo() gets the Ec/Io (the received energy per chip divided by the
381  * power density in the band measured in dBm on the primary CPICH channel of serving cell) of the
382  * cell specified with the le_mrc_CellInfoRef_t parameter.
383  * - le_mrc_GetNeighborCellLteIntraFreq() gets the RSRP and RSRQ of the Interfrequency of the cell
384  * specified with the le_mrc_CellInfoRef_t parameter.
385  * - le_mrc_GetNeighborCellLteInterFreq() gets the RSRP and RSRQ of the Interfrequency of the cell
386  * specified with the le_mrc_CellInfoRef_t parameter.
387  * - le_mrc_GetNeighborCellEarfcn() gets the neighbor Cell Frequency Channel Number (EARFCN).
388  * The EARFCN is in the range from 0 to 262143.
389  * - le_mrc_GetPhysicalNeighborLteCellId() gets the physical neighbor cell Id in LTE. The physical
390  * cell Id is in the range from 0 to 503.
391  * - le_mrc_GetNeighborCellGsmBsic() retrieves the Base Station Identity Code (BSIC) for the cell
392  * specified with the le_mrc_CellInfoRef_t parameter.
393  *
394  * A sample code can be seen in the following page:
395  * - @subpage c_mrcNeighborCells
396  *
397  * @section le_mrc_jamming Jamming detection
398  *
399  * The jamming detection algorithm is based on power measurements and cell synchronization actions
400  * performed during a GSM network scan procedure.
401  * During this procedure some intermediate results are reported, that allows user to take some
402  * preventive actions if necessary.
403  * This result is reported as a jammed state probability. See @ref le_mrc_JammingStatus_t
404  * enumeration for probability description.
405  * Each time the jamming status changes during the scan procedure, it is reported to the user.
406  * See @ref le_mrc_JammingReport_t enumeration for details.
407  *
408  * The jamming status is reported:
409  * - In an unsolicited way, each time the protocol stack initiates a scan for PLMN selection or
410  * reselection.
411  * - On user demand, when a user PLMN scan is performed.
412  *
413  * Call le_mrc_StartJammingDetection() to launch jamming monitoring.
414  * By registering a handler by calling le_mrc_AddJammingDetectionEventHandler(), the notification
415  * on jamming detection can be sent to the registered application.
416  *
417  * For each jamming detection monitoring, the following APIs can be called:
418  * - le_mrc_StartJammingDetection() to start the jamming monitoring.
419  * - le_mrc_StopJammingDetection() to stop the jamming monitoring.
420  * - le_mrc_AddJammingDetectionEventHandler() to register an event handler.
421  * - le_mrc_RemoveJammingDetectionEventHandler() to remove an event handler.
422  *
423  * @section le_mrc_sar SAR backoff
424  * SAR (Specific Absorption Rate) is a measure of RF energy absorption by the human body.
425  * Users can dynamically select a pre-configured SAR backoff state so they can adjust the SAR
426  * depending on their needs. To manage SAR backoff, these API should be used:
427  * - le_mrc_SetSarBackoffState() to set a new SAR backoff state.
428  * - le_mrc_GetSarBackoffState() to get the current SAR backoff state.
429  * This feature may be unsupported by some targets. Also, the number of supported states may vary
430  * depending on the target. Please refer to @ref platformConstraintsMdc for further details.
431  *
432  * <HR>
433  *
434  * Copyright (C) Sierra Wireless Inc.
435  */
436 /**
437  * @page c_mrcRadioPower Sample code for Radio Power Management
438  *
439  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Radio Power
440  */
441 /**
442  * @page c_mrcRadioConfigurationPreferences Sample code for Radio Configuration Preferences
443  *
444  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Band Preferences
445  *
446  */
447 /**
448  * @page c_mrcRAT Sample code for Radio Access Technology
449  *
450  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" RAT in Use
451  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" RAT Preferences
452  *
453  */
454 /**
455  * @page c_mrcNetworkRegistration Sample code for Network Registration
456  *
457  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Register
458  *
459  */
460 /**
461  * @page c_mrcQuality Sample code for Signal Quality
462  *
463  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Signal Quality
464  *
465  */
466 /**
467  * @page c_mrcLocationinformation Sample code for Location information
468  *
469  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Loc information
470  *
471  */
472 /**
473  * @page c_mrcBandCapabilities Sample code for Band Capabilities
474  *
475  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Band Capabilities
476  *
477  */
478 /**
479  * @page c_mrcGetCurrentNetwork Sample code for Get Current Network Information
480  *
481  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Get Network
482  *
483  */
484 /**
485  * @page c_mrcNetworkScan Sample code for Network Scan
486  *
487  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Network Scan
488  *
489  */
490 /**
491  * @page c_mrcPciScan Sample code for LTE PCI Scan
492  *
493  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" PCI Scan
494  *
495  */
496 /**
497  * @page c_mrcNeighborCells Sample code for Neighboring Cells Information
498  *
499  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Neighbor Cells
500  *
501  */
502 /**
503  * @page c_mrcGetService Sample code for Get the Current Packet Switched state
504  *
505  * @snippet "apps/test/modemServices/mrc/mrcIntegrationTest/mrcTest/le_mrcTest.c" Service State
506  *
507  */
508 /**
509  * @file le_mrc_interface.h
510  *
511  * Legato @ref c_mrc include file.
512  *
513  * Copyright (C) Sierra Wireless Inc.
514  */
515 
516 #ifndef LE_MRC_INTERFACE_H_INCLUDE_GUARD
517 #define LE_MRC_INTERFACE_H_INCLUDE_GUARD
518 
519 
520 #include "legato.h"
521 
522 // Internal includes for this interface
523 #include "le_mrc_common.h"
524 //--------------------------------------------------------------------------------------------------
525 /**
526  * Type for handler called when a server disconnects.
527  */
528 //--------------------------------------------------------------------------------------------------
529 typedef void (*le_mrc_DisconnectHandler_t)(void *);
530 
531 //--------------------------------------------------------------------------------------------------
532 /**
533  *
534  * Connect the current client thread to the service providing this API. Block until the service is
535  * available.
536  *
537  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
538  * called before any other functions in this API. Normally, ConnectService is automatically called
539  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
540  *
541  * This function is created automatically.
542  */
543 //--------------------------------------------------------------------------------------------------
545 (
546  void
547 );
548 
549 //--------------------------------------------------------------------------------------------------
550 /**
551  *
552  * Try to connect the current client thread to the service providing this API. Return with an error
553  * if the service is not available.
554  *
555  * For each thread that wants to use this API, either ConnectService or TryConnectService must be
556  * called before any other functions in this API. Normally, ConnectService is automatically called
557  * for the main thread, but not for any other thread. For details, see @ref apiFilesC_client.
558  *
559  * This function is created automatically.
560  *
561  * @return
562  * - LE_OK if the client connected successfully to the service.
563  * - LE_UNAVAILABLE if the server is not currently offering the service to which the client is
564  * bound.
565  * - LE_NOT_PERMITTED if the client interface is not bound to any service (doesn't have a binding).
566  * - LE_COMM_ERROR if the Service Directory cannot be reached.
567  */
568 //--------------------------------------------------------------------------------------------------
570 (
571  void
572 );
573 
574 //--------------------------------------------------------------------------------------------------
575 /**
576  * Set handler called when server disconnection is detected.
577  *
578  * When a server connection is lost, call this handler then exit with LE_FATAL. If a program wants
579  * to continue without exiting, it should call longjmp() from inside the handler.
580  */
581 //--------------------------------------------------------------------------------------------------
583 (
584  le_mrc_DisconnectHandler_t disconnectHandler,
585  void *contextPtr
586 );
587 
588 //--------------------------------------------------------------------------------------------------
589 /**
590  *
591  * Disconnect the current client thread from the service providing this API.
592  *
593  * Normally, this function doesn't need to be called. After this function is called, there's no
594  * longer a connection to the service, and the functions in this API can't be used. For details, see
595  * @ref apiFilesC_client.
596  *
597  * This function is created automatically.
598  */
599 //--------------------------------------------------------------------------------------------------
601 (
602  void
603 );
604 
605 
606 //--------------------------------------------------------------------------------------------------
607 /**
608  * 2G/3G Band Bit Mask (64 bits)
609  */
610 //--------------------------------------------------------------------------------------------------
611 
612 
613 //--------------------------------------------------------------------------------------------------
614 /**
615  * LTE Band Bit Mask (64 bits)
616  *
617  */
618 //--------------------------------------------------------------------------------------------------
619 
620 
621 //--------------------------------------------------------------------------------------------------
622 /**
623  * TDSCDMA Band Bit Mask
624  *
625  */
626 //--------------------------------------------------------------------------------------------------
627 
628 
629 //--------------------------------------------------------------------------------------------------
630 /**
631  * Reference type for referring to MRC Scan Information objects.
632  */
633 //--------------------------------------------------------------------------------------------------
634 
635 
636 //--------------------------------------------------------------------------------------------------
637 /**
638  * Reference type for Scan Information Listing.
639  */
640 //--------------------------------------------------------------------------------------------------
641 
642 
643 //--------------------------------------------------------------------------------------------------
644 /**
645  * Reference type for PCI Scan Information Listing.
646  */
647 //--------------------------------------------------------------------------------------------------
648 
649 
650 //--------------------------------------------------------------------------------------------------
651 /**
652  * Reference type for PCI Scan Information .
653  */
654 //--------------------------------------------------------------------------------------------------
655 
656 
657 //--------------------------------------------------------------------------------------------------
658 /**
659  * Reference type for PLMN Information .
660  */
661 //--------------------------------------------------------------------------------------------------
662 
663 
664 //--------------------------------------------------------------------------------------------------
665 /**
666  * Reference type for referring to the Preferred Operator objects.
667  */
668 //--------------------------------------------------------------------------------------------------
669 
670 
671 //--------------------------------------------------------------------------------------------------
672 /**
673  * Reference type for Preferred Operator Listing.
674  */
675 //--------------------------------------------------------------------------------------------------
676 
677 
678 //--------------------------------------------------------------------------------------------------
679 /**
680  * Reference type for one Cell Information.
681  */
682 //--------------------------------------------------------------------------------------------------
683 
684 
685 //--------------------------------------------------------------------------------------------------
686 /**
687  * Reference type for all Neighboring Cells Information.
688  */
689 //--------------------------------------------------------------------------------------------------
690 
691 
692 //--------------------------------------------------------------------------------------------------
693 /**
694  * Reference type for the signal metrics.
695  */
696 //--------------------------------------------------------------------------------------------------
697 
698 
699 //--------------------------------------------------------------------------------------------------
700 /**
701  * Network Registration states.
702  */
703 //--------------------------------------------------------------------------------------------------
704 
705 
706 //--------------------------------------------------------------------------------------------------
707 /**
708  * Radio Access Technology enum
709  */
710 //--------------------------------------------------------------------------------------------------
711 
712 
713 //--------------------------------------------------------------------------------------------------
714 /**
715  * Jamming detection report type enum
716  *
717  * @note If the reported status is the final status (end of the procedure), this shall be indicated
718  * within the status report.
719  * @note Other reports, called intermediate reports, gives only intermediate results issuing from
720  * the algorithm
721  */
722 //--------------------------------------------------------------------------------------------------
723 
724 
725 //--------------------------------------------------------------------------------------------------
726 /**
727  * Jamming detection status type enum
728  *
729  * @note The final status can be only NULL or JAMMED.
730  */
731 //--------------------------------------------------------------------------------------------------
732 
733 
734 //--------------------------------------------------------------------------------------------------
735 /**
736  * Radio Bitmask Access Technology Bit Mask
737  */
738 //--------------------------------------------------------------------------------------------------
739 
740 
741 //--------------------------------------------------------------------------------------------------
742 /**
743  * Network Registration reject cause type enum.
744  */
745 //--------------------------------------------------------------------------------------------------
746 
747 
748 //--------------------------------------------------------------------------------------------------
749 /**
750  * Network Registration service domain type enum.
751  */
752 //--------------------------------------------------------------------------------------------------
753 
754 
755 //--------------------------------------------------------------------------------------------------
756 /**
757  * Network registration reject indication structure.
758  */
759 //--------------------------------------------------------------------------------------------------
760 
761 
762 //--------------------------------------------------------------------------------------------------
763 /**
764  * Handler for Network registration state changes.
765  */
766 //--------------------------------------------------------------------------------------------------
767 
768 
769 //--------------------------------------------------------------------------------------------------
770 /**
771  * Reference type used by Add/Remove functions for EVENT 'le_mrc_NetRegStateEvent'
772  */
773 //--------------------------------------------------------------------------------------------------
774 
775 
776 //--------------------------------------------------------------------------------------------------
777 /**
778  * Handler for Radio Access Technology changes.
779  *
780  */
781 //--------------------------------------------------------------------------------------------------
782 
783 
784 //--------------------------------------------------------------------------------------------------
785 /**
786  * Reference type used by Add/Remove functions for EVENT 'le_mrc_RatChange'
787  */
788 //--------------------------------------------------------------------------------------------------
789 
790 
791 //--------------------------------------------------------------------------------------------------
792 /**
793  * Handler for Packet Switched service state changes.
794  *
795  */
796 //--------------------------------------------------------------------------------------------------
797 
798 
799 //--------------------------------------------------------------------------------------------------
800 /**
801  * Reference type used by Add/Remove functions for EVENT 'le_mrc_PacketSwitchedChange'
802  */
803 //--------------------------------------------------------------------------------------------------
804 
805 
806 //--------------------------------------------------------------------------------------------------
807 /**
808  * Handler for Signal Strength value changes.
809  *
810  */
811 //--------------------------------------------------------------------------------------------------
812 
813 
814 //--------------------------------------------------------------------------------------------------
815 /**
816  * Reference type used by Add/Remove functions for EVENT 'le_mrc_SignalStrengthChange'
817  */
818 //--------------------------------------------------------------------------------------------------
819 
820 
821 //--------------------------------------------------------------------------------------------------
822 /**
823  * Handler for cellular asynchronous network scan Sending result.
824  * Returns the reference to the List object. Null pointer if the scan failed.
825  *
826  */
827 //--------------------------------------------------------------------------------------------------
828 
829 
830 //--------------------------------------------------------------------------------------------------
831 /**
832  * Handler for PCI asynchronous network scan Sending result.
833  * Returns the reference to the List object. Null pointer if the scan failed.
834  *
835  */
836 //--------------------------------------------------------------------------------------------------
837 
838 
839 //--------------------------------------------------------------------------------------------------
840 /**
841  * Handler for asynchronous manual selection response
842  *
843  */
844 //--------------------------------------------------------------------------------------------------
845 
846 
847 //--------------------------------------------------------------------------------------------------
848 /**
849  * Handler to report network reject indication.
850  *
851  * @deprecated le_mrc_NetworkRejectHandler() will be removed in near future.
852  * It will be replaced by le_mrc_AddNetRegRejectHandler().
853  *
854  */
855 //--------------------------------------------------------------------------------------------------
856 
857 
858 //--------------------------------------------------------------------------------------------------
859 /**
860  * Reference type used by Add/Remove functions for EVENT 'le_mrc_NetworkReject'
861  */
862 //--------------------------------------------------------------------------------------------------
863 
864 
865 //--------------------------------------------------------------------------------------------------
866 /**
867  * Handler to report network registration reject indication.
868  * NetworkRejectHandler is deprecated.
869  */
870 //--------------------------------------------------------------------------------------------------
871 
872 
873 //--------------------------------------------------------------------------------------------------
874 /**
875  * Reference type used by Add/Remove functions for EVENT 'le_mrc_NetRegReject'
876  */
877 //--------------------------------------------------------------------------------------------------
878 
879 
880 //--------------------------------------------------------------------------------------------------
881 /**
882  * Handler for jamming detection event.
883  */
884 //--------------------------------------------------------------------------------------------------
885 
886 
887 //--------------------------------------------------------------------------------------------------
888 /**
889  * Reference type used by Add/Remove functions for EVENT 'le_mrc_JammingDetectionEvent'
890  */
891 //--------------------------------------------------------------------------------------------------
892 
893 
894 //--------------------------------------------------------------------------------------------------
895 /**
896  * Add handler function for EVENT 'le_mrc_NetRegStateEvent'
897  *
898  * This event provides information on network registration state changes.
899  *
900  * @note <b>multi-app safe</b>
901  */
902 //--------------------------------------------------------------------------------------------------
903 le_mrc_NetRegStateEventHandlerRef_t le_mrc_AddNetRegStateEventHandler
904 (
905  le_mrc_NetRegStateHandlerFunc_t handlerPtr,
906  ///< [IN]
907  void* contextPtr
908  ///< [IN]
909 );
910 
911 //--------------------------------------------------------------------------------------------------
912 /**
913  * Remove handler function for EVENT 'le_mrc_NetRegStateEvent'
914  */
915 //--------------------------------------------------------------------------------------------------
917 (
918  le_mrc_NetRegStateEventHandlerRef_t handlerRef
919  ///< [IN]
920 );
921 
922 //--------------------------------------------------------------------------------------------------
923 /**
924  * Add handler function for EVENT 'le_mrc_RatChange'
925  *
926  * This event provides information on Radio Access Technology changes.
927  *
928  * @note <b>multi-app safe</b>
929  */
930 //--------------------------------------------------------------------------------------------------
931 le_mrc_RatChangeHandlerRef_t le_mrc_AddRatChangeHandler
932 (
933  le_mrc_RatChangeHandlerFunc_t handlerPtr,
934  ///< [IN]
935  void* contextPtr
936  ///< [IN]
937 );
938 
939 //--------------------------------------------------------------------------------------------------
940 /**
941  * Remove handler function for EVENT 'le_mrc_RatChange'
942  */
943 //--------------------------------------------------------------------------------------------------
945 (
946  le_mrc_RatChangeHandlerRef_t handlerRef
947  ///< [IN]
948 );
949 
950 //--------------------------------------------------------------------------------------------------
951 /**
952  * Add handler function for EVENT 'le_mrc_PacketSwitchedChange'
953  *
954  * This event provides information on Packet Switched service changes.
955  *
956  * @note <b>multi-app safe</b>
957  */
958 //--------------------------------------------------------------------------------------------------
959 le_mrc_PacketSwitchedChangeHandlerRef_t le_mrc_AddPacketSwitchedChangeHandler
960 (
961  le_mrc_PacketSwitchedChangeHandlerFunc_t packetHandlerPtr,
962  ///< [IN]
963  void* contextPtr
964  ///< [IN]
965 );
966 
967 //--------------------------------------------------------------------------------------------------
968 /**
969  * Remove handler function for EVENT 'le_mrc_PacketSwitchedChange'
970  */
971 //--------------------------------------------------------------------------------------------------
973 (
974  le_mrc_PacketSwitchedChangeHandlerRef_t handlerRef
975  ///< [IN]
976 );
977 
978 //--------------------------------------------------------------------------------------------------
979 /**
980  * Add handler function for EVENT 'le_mrc_SignalStrengthChange'
981  *
982  * This event provides information on Signal Strength value changes.
983  *
984  * @note <b>NOT multi-app safe</b>
985  */
986 //--------------------------------------------------------------------------------------------------
987 le_mrc_SignalStrengthChangeHandlerRef_t le_mrc_AddSignalStrengthChangeHandler
988 (
989  le_mrc_Rat_t rat,
990  ///< [IN] Radio Access Technology
991  int32_t lowerRangeThreshold,
992  ///< [IN] Lower-range Signal strength threshold in dBm
993  int32_t upperRangeThreshold,
994  ///< [IN] Upper-range Signal strength threshold in dBm
995  le_mrc_SignalStrengthChangeHandlerFunc_t handlerPtr,
996  ///< [IN]
997  void* contextPtr
998  ///< [IN]
999 );
1000 
1001 //--------------------------------------------------------------------------------------------------
1002 /**
1003  * Remove handler function for EVENT 'le_mrc_SignalStrengthChange'
1004  */
1005 //--------------------------------------------------------------------------------------------------
1007 (
1008  le_mrc_SignalStrengthChangeHandlerRef_t handlerRef
1009  ///< [IN]
1010 );
1011 
1012 //--------------------------------------------------------------------------------------------------
1013 /**
1014  * This function sets signal strength indication thresholds for a specific RAT.
1015  *
1016  * @return
1017  * - LE_OK Function succeeded.
1018  * - LE_BAD_PARAMETER Bad parameters
1019  * - LE_FAULT Function failed.
1020  *
1021  * @note <b>NOT multi-app safe</b>
1022  */
1023 //--------------------------------------------------------------------------------------------------
1025 (
1026  le_mrc_Rat_t rat,
1027  ///< [IN] Radio Access Technology
1028  int32_t lowerRangeThreshold,
1029  ///< [IN] Lower-range Signal strength threshold in dBm
1030  int32_t upperRangeThreshold
1031  ///< [IN] Upper-range Signal strength threshold in dBm
1032 );
1033 
1034 //--------------------------------------------------------------------------------------------------
1035 /**
1036  * This function sets a signal strength indication delta for a specific RAT.
1037  *
1038  * @return
1039  * - LE_OK Function succeeded.
1040  * - LE_BAD_PARAMETER Bad parameters.
1041  * - LE_FAULT Function failed.
1042  *
1043  * @note The signal delta is set in units of 0.1 dBm. For example, to set a delta of 10.6 dBm, the
1044  * delta value must be set to 106.
1045  *
1046  * @warning The signal delta resolution is platform dependent. Please refer to
1047  * @ref platformConstraintsMdc section for full details.
1048  */
1049 //--------------------------------------------------------------------------------------------------
1051 (
1052  le_mrc_Rat_t rat,
1053  ///< [IN] Radio Access Technology
1054  uint16_t delta
1055  ///< [IN] Signal delta in units of 0.1 dBm
1056 );
1057 
1058 //--------------------------------------------------------------------------------------------------
1059 /**
1060  * Enable the automatic Selection Register mode.
1061  *
1062  * @return
1063  * - LE_FAULT Function failed.
1064  * - LE_OK Function succeeded.
1065  *
1066  * @note <b>NOT multi-app safe</b>
1067  */
1068 //--------------------------------------------------------------------------------------------------
1070 (
1071  void
1072 );
1073 
1074 //--------------------------------------------------------------------------------------------------
1075 /**
1076  * Set the manual Selection Register mode with the MCC/MNC parameters.
1077  *
1078  * @return
1079  * - LE_FAULT Function failed.
1080  * - LE_OK Function succeeded.
1081  *
1082  * @note If strings are not set, too long (bigger than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN digits), or too
1083  * short (less than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN-1 digits) it's a fatal error, the function
1084  * won't return.
1085  *
1086  * @note <b>NOT multi-app safe</b>
1087  */
1088 //--------------------------------------------------------------------------------------------------
1090 (
1091  const char* LE_NONNULL mcc,
1092  ///< [IN] Mobile Country Code
1093  const char* LE_NONNULL mnc
1094  ///< [IN] Mobile Network Code
1095 );
1096 
1097 //--------------------------------------------------------------------------------------------------
1098 /**
1099  * Set the manual selection register mode asynchronously. This function is not blocking,
1100  * the response will be returned with a handler function.
1101  *
1102  * @note If strings are not set, too long (bigger than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN digits), or too
1103  * short (less than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN-1 digits) it's a fatal error, the function
1104  * won't return.
1105  *
1106  *@note <b>NOT multi-app safe</b>
1107  *
1108  */
1109 //--------------------------------------------------------------------------------------------------
1111 (
1112  const char* LE_NONNULL mcc,
1113  ///< [IN] Mobile Country Code
1114  const char* LE_NONNULL mnc,
1115  ///< [IN] Mobile Network Code
1116  le_mrc_ManualSelectionHandlerFunc_t handlerPtr,
1117  ///< [IN] handler for sending result
1118  void* contextPtr
1119  ///< [IN]
1120 );
1121 
1122 //--------------------------------------------------------------------------------------------------
1123 /**
1124  * Get the selected Selection Register mode.
1125  *
1126  * @return
1127  * - LE_FAULT Function failed.
1128  * - LE_OK Function succeeded.
1129  *
1130  * @note <b>multi-app safe</b>
1131  */
1132 //--------------------------------------------------------------------------------------------------
1134 (
1135  bool* isManualPtrPtr,
1136  ///< [OUT] true if the scan mode is manual, false if the scan mode is automatic.
1137  char* mccPtr,
1138  ///< [OUT] Mobile Country Code
1139  size_t mccPtrSize,
1140  ///< [IN]
1141  char* mncPtr,
1142  ///< [OUT] Mobile Network Code
1143  size_t mncPtrSize
1144  ///< [IN]
1145 );
1146 
1147 //--------------------------------------------------------------------------------------------------
1148 /**
1149  * Get the Packet Switched state.
1150  *
1151  * @return
1152  * - LE_FAULT Function failed.
1153  * - LE_OK Function succeeded.
1154  *
1155  * @note <b>multi-app safe</b>
1156  */
1157 //--------------------------------------------------------------------------------------------------
1159 (
1160  le_mrc_NetRegState_t* statePtr
1161  ///< [OUT] The current Packet switched state.
1162 );
1163 
1164 //--------------------------------------------------------------------------------------------------
1165 /**
1166  * Get the platform specific network registration error code.
1167  *
1168  * Refer to @ref platformConstraintsSpecificErrorCodes for platform specific
1169  * registration error code description.
1170  *
1171  * @return the platform specific registration error code
1172  *
1173  */
1174 //--------------------------------------------------------------------------------------------------
1176 (
1177  void
1178 );
1179 
1180 //--------------------------------------------------------------------------------------------------
1181 /**
1182  * Set the Radio Access Technology preferences by using a bit mask.
1183  *
1184  * @return
1185  * - LE_FAULT Function failed.
1186  * - LE_OK Function succeeded.
1187  * - LE_UNSUPPORTED Not supported by platform.
1188  *
1189  * @note <b>NOT multi-app safe</b>
1190  */
1191 //--------------------------------------------------------------------------------------------------
1193 (
1194  le_mrc_RatBitMask_t ratMask
1195  ///< [IN] Bit mask for the Radio Access Technology preferences.
1196 );
1197 
1198 //--------------------------------------------------------------------------------------------------
1199 /**
1200  * Get the Radio Access Technology preferences
1201  *
1202  * @return
1203  * - LE_FAULT Function failed.
1204  * - LE_OK Function succeeded.
1205  *
1206  * @note <b>multi-app safe</b>
1207  */
1208 //--------------------------------------------------------------------------------------------------
1210 (
1211  le_mrc_RatBitMask_t* ratMaskPtrPtr
1212  ///< [OUT] Bit mask for the Radio Access Technology preferences.
1213 );
1214 
1215 //--------------------------------------------------------------------------------------------------
1216 /**
1217  * Set the 2G/3G Band preferences by using a bit mask.
1218  *
1219  * @return
1220  * - LE_FAULT Function failed.
1221  * - LE_OK Function succeeded.
1222  *
1223  * @note <b>NOT multi-app safe</b>
1224  */
1225 //--------------------------------------------------------------------------------------------------
1227 (
1228  le_mrc_BandBitMask_t bandMask
1229  ///< [IN] Bit mask for 2G/3G Band preferences.
1230 );
1231 
1232 //--------------------------------------------------------------------------------------------------
1233 /**
1234  * Get the Bit mask for 2G/3G Band preferences.
1235  *
1236  * @return
1237  * - LE_FAULT Function failed.
1238  * - LE_OK Function succeeded.
1239  *
1240  * @note <b>multi-app safe</b>
1241  */
1242 //--------------------------------------------------------------------------------------------------
1244 (
1245  le_mrc_BandBitMask_t* bandMaskPtrPtr
1246  ///< [OUT] Bit mask for 2G/3G Band preferences.
1247 );
1248 
1249 //--------------------------------------------------------------------------------------------------
1250 /**
1251  * Set the LTE Band preferences by using a bit mask.
1252  *
1253  * @return
1254  * - LE_FAULT Function failed.
1255  * - LE_OK Function succeeded.
1256  * - LE_UNSUPPORTED The platform doesn't support setting LTE Band preferences.
1257  *
1258  * @note <b>NOT multi-app safe</b>
1259  */
1260 //--------------------------------------------------------------------------------------------------
1262 (
1263  le_mrc_LteBandBitMask_t bandMask
1264  ///< [IN] Bit mask for LTE Band preferences.
1265 );
1266 
1267 //--------------------------------------------------------------------------------------------------
1268 /**
1269  * Get the Bit mask for LTE Band preferences.
1270  *
1271  * @return
1272  * - LE_FAULT Function failed.
1273  * - LE_OK Function succeeded.
1274  *
1275  * @note <b>multi-app safe</b>
1276  */
1277 //--------------------------------------------------------------------------------------------------
1279 (
1280  le_mrc_LteBandBitMask_t* bandMaskPtrPtr
1281  ///< [OUT] Bit mask for LTE Band preferences.
1282 );
1283 
1284 //--------------------------------------------------------------------------------------------------
1285 /**
1286  * Set the TD-SCDMA Band preferences by using a bit mask.
1287  *
1288  * @return
1289  * - LE_OK Function succeeded.
1290  * - LE_FAULT Function failed.
1291  * - LE_UNSUPPORTED The platform doesn't support setting TD-SCDMA Band preferences.
1292  *
1293  * @note <b>NOT multi-app safe</b>
1294  */
1295 //--------------------------------------------------------------------------------------------------
1297 (
1298  le_mrc_TdScdmaBandBitMask_t bandMask
1299  ///< [IN] Bit mask for TD-SCDMA Band preferences.
1300 );
1301 
1302 //--------------------------------------------------------------------------------------------------
1303 /**
1304  * Get the Bit mask for TD-SCDMA Band preferences.
1305  *
1306  * @return
1307  * - LE_OK Function succeeded.
1308  * - LE_FAULT Function failed.
1309  * - LE_UNSUPPORTED The platform doesn't support getting TD-SCDMA Band preferences.
1310  *
1311  * @note <b>multi-app safe</b>
1312  */
1313 //--------------------------------------------------------------------------------------------------
1315 (
1316  le_mrc_TdScdmaBandBitMask_t* bandMaskPtrPtr
1317  ///< [OUT] Bit mask for TD-SCDMA Band preferences.
1318 );
1319 
1320 //--------------------------------------------------------------------------------------------------
1321 /**
1322  * Add a preferred operator by specifying the MCC/MNC and the Radio Access Technology.
1323  *
1324  * @return
1325  * - LE_UNSUPPORTED List of User Preferred operators not available.
1326  * - LE_FAULT Function failed.
1327  * - LE_BAD_PARAMETER RAT mask is invalid.
1328  * - LE_OK Function succeeded.
1329  *
1330  * @note If strings are not set, too long (bigger than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN digits), or too
1331  * short (less than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN-1 digits) it's a fatal error, the function
1332  * won't return.
1333  *
1334  * @note <b>NOT multi-app safe</b>
1335  */
1336 //--------------------------------------------------------------------------------------------------
1338 (
1339  const char* LE_NONNULL mcc,
1340  ///< [IN] Mobile Country Code
1341  const char* LE_NONNULL mnc,
1342  ///< [IN] Mobile Network Code
1343  le_mrc_RatBitMask_t ratMask
1344  ///< [IN] Bit mask for the Radio Access Technology preferences.
1345 );
1346 
1347 //--------------------------------------------------------------------------------------------------
1348 /**
1349  * Remove a preferred operator by specifying the MCC/MNC.
1350  *
1351  * @return
1352  * - LE_UNSUPPORTED List of User Preferred operators not available.
1353  * - LE_NOT_FOUND Operator not found in the User Preferred operators list.
1354  * - LE_FAULT Function failed.
1355  * - LE_OK Function succeeded.
1356  *
1357  * @note If strings are not set, too long (bigger than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN digits), or too
1358  * short (less than LE_MRC_MCC_LEN/LE_MRC_MNC_LEN-1 digits) it's a fatal error, the function
1359  * won't return.
1360  *
1361  * @note <b>NOT multi-app safe</b>
1362  */
1363 //--------------------------------------------------------------------------------------------------
1365 (
1366  const char* LE_NONNULL mcc,
1367  ///< [IN] Mobile Country Code
1368  const char* LE_NONNULL mnc
1369  ///< [IN] Mobile Network Code
1370 );
1371 
1372 //--------------------------------------------------------------------------------------------------
1373 /**
1374  * This function must be called to retrieve a list of the preferred operators.
1375  *
1376  * @return
1377  * - Reference to the List object.
1378  * - Null pointer if there is no preferences list.
1379  *
1380  * @note <b>multi-app safe</b>
1381  */
1382 //--------------------------------------------------------------------------------------------------
1383 le_mrc_PreferredOperatorListRef_t le_mrc_GetPreferredOperatorsList
1384 (
1385  void
1386 );
1387 
1388 //--------------------------------------------------------------------------------------------------
1389 /**
1390  * This function must be called to get the first Operator object reference in the list of the
1391  * preferred operators retrieved with le_mrc_GetPreferredOperators().
1392  *
1393  * @return
1394  * - NULL No operator information found.
1395  * - le_mrc_PreferredOperatorRef The Operator object reference.
1396  *
1397  * @note If the caller is passing a bad reference into this function, it's a fatal error, the
1398  * function won't return.
1399  *
1400  * @note <b>multi-app safe</b>
1401  */
1402 //--------------------------------------------------------------------------------------------------
1403 le_mrc_PreferredOperatorRef_t le_mrc_GetFirstPreferredOperator
1404 (
1405  le_mrc_PreferredOperatorListRef_t preferredOperatorListRef
1406  ///< [IN] The list of the preferred operators.
1407 );
1408 
1409 //--------------------------------------------------------------------------------------------------
1410 /**
1411  * This function must be called to get the next Operator object reference in the list of the
1412  * preferred operators retrieved with le_mrc_GetPreferredOperators().
1413  *
1414  * @return
1415  * - NULL No operator information found.
1416  * - le_mrc_PreferredOperatorRef The Operator object reference.
1417  *
1418  * @note If the caller is passing a bad reference into this function, it's a fatal error, the
1419  * function won't return.
1420  *
1421  * @note <b>multi-app safe</b>
1422  */
1423 //--------------------------------------------------------------------------------------------------
1424 le_mrc_PreferredOperatorRef_t le_mrc_GetNextPreferredOperator
1425 (
1426  le_mrc_PreferredOperatorListRef_t preferredOperatorListRef
1427  ///< [IN] The list of the preferred operators.
1428 );
1429 
1430 //--------------------------------------------------------------------------------------------------
1431 /**
1432  * This function must be called to delete the list of the preferred operators retrieved with
1433  * le_mrc_GetPreferredOperators().
1434  *
1435  * @note On failure, the process exits, so you don't have to worry about checking the returned
1436  * reference for validity.
1437  *
1438  * @note <b>multi-app safe</b>
1439  */
1440 //--------------------------------------------------------------------------------------------------
1442 (
1443  le_mrc_PreferredOperatorListRef_t preferredOperatorListRef
1444  ///< [IN] The list of the preferred operators.
1445 );
1446 
1447 //--------------------------------------------------------------------------------------------------
1448 /**
1449  * This function must be called to get the Operator information details.
1450  *
1451  * @return
1452  * - LE_OK on success
1453  * - LE_OVERFLOW if the MCC or MNC would not fit in buffer
1454  * - LE_FAULT for all other errors
1455  *
1456  * @note <b>multi-app safe</b>
1457  */
1458 //--------------------------------------------------------------------------------------------------
1460 (
1461  le_mrc_PreferredOperatorRef_t preferredOperatorRef,
1462  ///< [IN] Operator object reference.
1463  char* mccPtr,
1464  ///< [OUT] Mobile Country Code.
1465  size_t mccPtrSize,
1466  ///< [IN]
1467  char* mncPtr,
1468  ///< [OUT] Mobile Network Code.
1469  size_t mncPtrSize,
1470  ///< [IN]
1471  le_mrc_RatBitMask_t* ratMaskPtr
1472  ///< [OUT] Bit mask for the RAT preferences.
1473 );
1474 
1475 //--------------------------------------------------------------------------------------------------
1476 /**
1477  * Get the network registration state.
1478  *
1479  * @return LE_FAULT The function failed to get the Network registration state.
1480  * @return LE_BAD_PARAMETER A bad parameter was passed.
1481  * @return LE_OK The function succeeded.
1482  *
1483  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1484  * function won't return.
1485  *
1486  * @note <b>multi-app safe</b>
1487  */
1488 //--------------------------------------------------------------------------------------------------
1490 (
1491  le_mrc_NetRegState_t* statePtr
1492  ///< [OUT] Network Registration state.
1493 );
1494 
1495 //--------------------------------------------------------------------------------------------------
1496 /**
1497  * Get the signal quality.
1498  *
1499  * @return LE_FAULT The function failed to get the Signal Quality information.
1500  * @return LE_BAD_PARAMETER A bad parameter was passed.
1501  * @return LE_OK The function succeeded.
1502  *
1503  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1504  * function won't return.
1505  *
1506  * @note <b>multi-app safe</b>
1507  */
1508 //--------------------------------------------------------------------------------------------------
1510 (
1511  uint32_t* qualityPtr
1512  ///< [OUT] [OUT] Received signal strength quality (0 = no signal strength,
1513  ///< 5 = very good signal strength).
1514 );
1515 
1516 //--------------------------------------------------------------------------------------------------
1517 /**
1518  * Set the power of the Radio Module.
1519  *
1520  * @return LE_BAD_PARAMETER Bad power mode specified.
1521  * @return LE_FAULT Function failed.
1522  * @return LE_OK Function succeed.
1523  *
1524  * @note <b>NOT multi-app safe</b>
1525  */
1526 //--------------------------------------------------------------------------------------------------
1528 (
1529  le_onoff_t power
1530  ///< [IN] The power state.
1531 );
1532 
1533 //--------------------------------------------------------------------------------------------------
1534 /**
1535  * Must be called to get the Radio Module power state.
1536  *
1537  * @return LE_FAULT The function failed to get the Radio Module power state.
1538  * @return LE_BAD_PARAMETER if powerPtr is NULL.
1539  * @return LE_OK The function succeed.
1540  *
1541  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1542  * function won't return.
1543  *
1544  * @note <b>multi-app safe</b>
1545  */
1546 //--------------------------------------------------------------------------------------------------
1548 (
1549  le_onoff_t* powerPtr
1550  ///< [OUT] Power state.
1551 );
1552 
1553 //--------------------------------------------------------------------------------------------------
1554 /**
1555  * This function must be called to perform a cellular network scan.
1556  *
1557  * @return Reference to the List object. Null pointer if the scan failed.
1558  *
1559  * @note <b>multi-app safe</b>
1560  */
1561 //--------------------------------------------------------------------------------------------------
1562 le_mrc_ScanInformationListRef_t le_mrc_PerformCellularNetworkScan
1563 (
1564  le_mrc_RatBitMask_t ratMask
1565  ///< [IN] Radio Access Technology mask
1566 );
1567 
1568 //--------------------------------------------------------------------------------------------------
1569 /**
1570  * This function must be called to perform a PCI network scan.
1571  *
1572  * @return Reference to the List object. Null pointer if the scan failed.
1573  *
1574  * @warning PCI scan is platform dependent. Please refer to @ref platformConstraintsMdc for further
1575  * details.
1576  *
1577  * @note On devices with the watchdog service enabled, the timeout is 4 mins. On those without, the
1578  * timeout is 5 mins.
1579  *
1580  * @note <b>multi-app safe</b>
1581  */
1582 //--------------------------------------------------------------------------------------------------
1583 le_mrc_PciScanInformationListRef_t le_mrc_PerformPciNetworkScan
1584 (
1585  le_mrc_RatBitMask_t ratMask
1586  ///< [IN] Radio Access Technology mask
1587 );
1588 
1589 //--------------------------------------------------------------------------------------------------
1590 /**
1591  * This function must be called to perform a cellular network scan asynchronously. This function
1592  * is not blocking, the response will be returned with a handler function.
1593  *
1594  *@note <b>multi-app safe</b>
1595  *
1596  */
1597 //--------------------------------------------------------------------------------------------------
1599 (
1600  le_mrc_RatBitMask_t ratMask,
1601  ///< [IN] Radio Access Technology mask
1602  le_mrc_CellularNetworkScanHandlerFunc_t handlerPtr,
1603  ///< [IN] handler for sending result.
1604  void* contextPtr
1605  ///< [IN]
1606 );
1607 
1608 //--------------------------------------------------------------------------------------------------
1609 /**
1610  * This function must be called to perform a PCI network scan asynchronously. This function
1611  * is not blocking, the response will be returned with a handler function.
1612  *
1613  * @warning PCI scan is platform dependent. Please refer to @ref platformConstraintsMdc for further
1614  * details.
1615  *
1616  *@note <b>multi-app safe</b>
1617  *
1618  */
1619 //--------------------------------------------------------------------------------------------------
1621 (
1622  le_mrc_RatBitMask_t ratMask,
1623  ///< [IN] Radio Access Technology mask
1624  le_mrc_PciNetworkScanHandlerFunc_t handlerPtr,
1625  ///< [IN] handler for sending result.
1626  void* contextPtr
1627  ///< [IN]
1628 );
1629 
1630 //--------------------------------------------------------------------------------------------------
1631 /**
1632  * This function must be called to get the first Scan Information object reference in the list of
1633  * scan Information retrieved with le_mrc_PerformCellularNetworkScan().
1634  *
1635  * @return NULL No scan information found.
1636  * @return le_mrc_ScanInformationRef_t The Scan Information object reference.
1637  *
1638  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1639  * function won't return.
1640  *
1641  * @note <b>multi-app safe</b>
1642  */
1643 //--------------------------------------------------------------------------------------------------
1644 le_mrc_ScanInformationRef_t le_mrc_GetFirstCellularNetworkScan
1645 (
1646  le_mrc_ScanInformationListRef_t scanInformationListRef
1647  ///< [IN] The list of scan information.
1648 );
1649 
1650 //--------------------------------------------------------------------------------------------------
1651 /**
1652  * This function must be called to get the next Scan Information object reference in the list of
1653  * scan Information retrieved with le_mrc_PerformCellularNetworkScan().
1654  *
1655  * @return NULL No scan information found.
1656  * @return le_mrc_ScanInformationRef_t The Scan Information object reference.
1657  *
1658  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1659  * function won't return.
1660  *
1661  * @note <b>multi-app safe</b>
1662  */
1663 //--------------------------------------------------------------------------------------------------
1664 le_mrc_ScanInformationRef_t le_mrc_GetNextCellularNetworkScan
1665 (
1666  le_mrc_ScanInformationListRef_t scanInformationListRef
1667  ///< [IN] The list of scan information.
1668 );
1669 
1670 //--------------------------------------------------------------------------------------------------
1671 /**
1672  * This function must be called to get the first Pci Scan Information object reference in the list of
1673  * scan Information retrieved with le_mrc_PerformPciNetworkScan().
1674  *
1675  * @return NULL No scan information found.
1676  * @return The Scan Information object reference.
1677  *
1678  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1679  * function won't return.
1680  *
1681  * @note <b>multi-app safe</b>
1682  */
1683 //--------------------------------------------------------------------------------------------------
1684 le_mrc_PciScanInformationRef_t le_mrc_GetFirstPciScanInfo
1685 (
1686  le_mrc_PciScanInformationListRef_t scanInformationListRef
1687  ///< [IN] The list of scan information.
1688 );
1689 
1690 //--------------------------------------------------------------------------------------------------
1691 /**
1692  * This function must be called to get the next Scan Information object reference in the list of
1693  * scan Information retrieved with le_mrc_PerformPciNetworkScan().
1694  *
1695  * @return NULL No scan information found.
1696  * @return The Scan Information object reference.
1697  *
1698  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1699  * function won't return.
1700  *
1701  * @note <b>multi-app safe</b>
1702  */
1703 //--------------------------------------------------------------------------------------------------
1704 le_mrc_PciScanInformationRef_t le_mrc_GetNextPciScanInfo
1705 (
1706  le_mrc_PciScanInformationListRef_t scanInformationListRef
1707  ///< [IN] The list of scan information.
1708 );
1709 
1710 //--------------------------------------------------------------------------------------------------
1711 /**
1712  * This function must be called to get the first Plmn Information object reference in the list of
1713  * Plmn on each cell.
1714  *
1715  * @return NULL No scan information found.
1716  * @return le_mrc_PlmnInformationRef_t The Plmn Information object reference.
1717  *
1718  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1719  * function won't return.
1720  *
1721  */
1722 //--------------------------------------------------------------------------------------------------
1723 le_mrc_PlmnInformationRef_t le_mrc_GetFirstPlmnInfo
1724 (
1725  le_mrc_PciScanInformationRef_t pciScanInformationRef
1726  ///< [IN] [IN] The reference to the cell information.
1727 );
1728 
1729 //--------------------------------------------------------------------------------------------------
1730 /**
1731  * This function must be called to get the next Plmn Information object reference in the list of
1732  * Plmn on each cell.
1733  *
1734  * @return NULL No scan information found.
1735  * @return le_mrc_PlmnInformationRef_t The Plmn Information object reference.
1736  *
1737  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1738  * function won't return.
1739  *
1740  */
1741 //--------------------------------------------------------------------------------------------------
1742 le_mrc_PlmnInformationRef_t le_mrc_GetNextPlmnInfo
1743 (
1744  le_mrc_PciScanInformationRef_t plmnRef
1745  ///< [IN] [IN] The reference to the cell information.
1746 );
1747 
1748 //--------------------------------------------------------------------------------------------------
1749 /**
1750  * This function must be called to get the physical cell id referenced by PciScanInformation which
1751  * is returned by le_mrc_GetFirstPciScanInfo() and le_mrc_GetNextPciScanInfo().
1752  *
1753  * @return The Physical Cell Identifier.
1754  *
1755  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1756  * function won't return.
1757  */
1758 //--------------------------------------------------------------------------------------------------
1759 uint16_t le_mrc_GetPciScanCellId
1760 (
1761  le_mrc_PciScanInformationRef_t pciScanInformationRef
1762  ///< [IN] [IN] The reference to the cell information.
1763 );
1764 
1765 //--------------------------------------------------------------------------------------------------
1766 /**
1767  * This function must be called to get the global cell id referenced by PciScanInformation which is
1768  * returned by le_mrc_GetFirstPciScanInfo() and le_mrc_GetNextPciScanInfo().
1769  *
1770  * @return The Global Cell Identifier.
1771  *
1772  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
1773  * function won't return.
1774  */
1775 //--------------------------------------------------------------------------------------------------
1777 (
1778  le_mrc_PciScanInformationRef_t pciScanInformationRef
1779  ///< [IN] [IN] The reference to the cell information.
1780 );
1781 
1782 //--------------------------------------------------------------------------------------------------
1783 /**
1784  * This function must be called to get the Mcc/Mnc of each PLMN referenced in the list of
1785  * Plmn Information retrieved with le_mrc_GetFirstPlmnInfo() and le_mrc_GetNextPlmnInfo().
1786  *
1787  * @return
1788  * - LE_OK on success
1789  * - LE_OVERFLOW if the MCC or MNC would not fit in buffer
1790  * - LE_FAULT for all other errors
1791  *
1792  *
1793  */
1794 //--------------------------------------------------------------------------------------------------
1796 (
1797  le_mrc_PlmnInformationRef_t plmnRef,
1798  ///< [IN] [IN] The reference to the cell information.
1799  char* mccPtr,
1800  ///< [OUT] Mobile Country Code
1801  size_t mccPtrSize,
1802  ///< [IN]
1803  char* mncPtr,
1804  ///< [OUT] Mobile Network Code
1805  size_t mncPtrSize
1806  ///< [IN]
1807 );
1808 
1809 //--------------------------------------------------------------------------------------------------
1810 /**
1811  * This function must be called to delete the list of the Scan Information retrieved with
1812  * le_mrc_PerformCellularNetworkScan().
1813  *
1814  * @note
1815  * On failure, the process exits, so you don't have to worry about checking the returned
1816  * reference for validity.
1817  *
1818  * @note <b>multi-app safe</b>
1819  */
1820 //--------------------------------------------------------------------------------------------------
1822 (
1823  le_mrc_ScanInformationListRef_t scanInformationListRef
1824  ///< [IN] The list of scan information.
1825 );
1826 
1827 //--------------------------------------------------------------------------------------------------
1828 /**
1829  * This function must be called to delete the list of the Pci Scan Information retrieved with
1830  * le_mrc_PerformPciNetworkScan() or le_mrc_PerformPciNetworkScanAsync().
1831  *
1832  * @note
1833  * On failure, the process exits, so you don't have to worry about checking the returned
1834  * reference for validity.
1835  *
1836  */
1837 //--------------------------------------------------------------------------------------------------
1839 (
1840  le_mrc_PciScanInformationListRef_t scanInformationListRef
1841  ///< [IN] The list of scan information.
1842 );
1843 
1844 //--------------------------------------------------------------------------------------------------
1845 /**
1846  * This function must be called to get the Cellular Network Code [mcc:mnc]
1847  *
1848  * @return
1849  * - LE_OK on success
1850  * - LE_OVERFLOW if the MCC or MNC would not fit in buffer
1851  * - LE_FAULT for all other errors
1852  *
1853  * @note On failure, the process exits, so you don't have to worry about checking the returned
1854  * reference for validity.
1855  *
1856  * @note <b>multi-app safe</b>
1857  */
1858 //--------------------------------------------------------------------------------------------------
1860 (
1861  le_mrc_ScanInformationRef_t scanInformationRef,
1862  ///< [IN] Scan information reference
1863  char* mccPtr,
1864  ///< [OUT] Mobile Country Code
1865  size_t mccPtrSize,
1866  ///< [IN]
1867  char* mncPtr,
1868  ///< [OUT] Mobile Network Code
1869  size_t mncPtrSize
1870  ///< [IN]
1871 );
1872 
1873 //--------------------------------------------------------------------------------------------------
1874 /**
1875  * This function must be called to get the Cellular Network Name.
1876  *
1877  * @return
1878  * - LE_OK on success
1879  * - LE_OVERFLOW if the operator name would not fit in buffer
1880  * - LE_FAULT for all other errors
1881  *
1882  * @note On failure, the process exits, so you don't have to worry about checking the returned
1883  * reference for validity.
1884  *
1885  * @note <b>multi-app safe</b>
1886  */
1887 //--------------------------------------------------------------------------------------------------
1889 (
1890  le_mrc_ScanInformationRef_t scanInformationRef,
1891  ///< [IN] Scan information reference
1892  char* namePtr,
1893  ///< [OUT] Name of operator
1894  size_t namePtrSize
1895  ///< [IN]
1896 );
1897 
1898 //--------------------------------------------------------------------------------------------------
1899 /**
1900  * This function must be called to get the radio access technology of a scanInformationRef.
1901  *
1902  * @return the radio access technology
1903  *
1904  * @note On failure, the process exits.
1905  *
1906  * @note <b>multi-app safe</b>
1907  */
1908 //--------------------------------------------------------------------------------------------------
1909 le_mrc_Rat_t le_mrc_GetCellularNetworkRat
1910 (
1911  le_mrc_ScanInformationRef_t scanInformationRef
1912  ///< [IN] Scan information reference
1913 );
1914 
1915 //--------------------------------------------------------------------------------------------------
1916 /**
1917  * This function must be called to check if a cellular network is currently in use.
1918  *
1919  * @return true The network is in use
1920  * @return false The network isn't in use
1921  *
1922  * @note On failure, the process exits, so you don't have to worry about checking the returned
1923  * reference for validity.
1924  *
1925  * @note <b>multi-app safe</b>
1926  */
1927 //--------------------------------------------------------------------------------------------------
1929 (
1930  le_mrc_ScanInformationRef_t scanInformationRef
1931  ///< [IN] Scan information reference
1932 );
1933 
1934 //--------------------------------------------------------------------------------------------------
1935 /**
1936  * This function must be called to check if a cellular network is available.
1937  *
1938  * @return true The network is available
1939  * @return false The network isn't available
1940  *
1941  * @note On failure, the process exits, so you don't have to worry about checking the returned
1942  * reference for validity.
1943  *
1944  * @note <b>multi-app safe</b>
1945  */
1946 //--------------------------------------------------------------------------------------------------
1948 (
1949  le_mrc_ScanInformationRef_t scanInformationRef
1950  ///< [IN] Scan information reference
1951 );
1952 
1953 //--------------------------------------------------------------------------------------------------
1954 /**
1955  * This function must be called to check if a cellular network is currently in home mode.
1956  *
1957  * @return true The network is home
1958  * @return false The network is roaming
1959  *
1960  * @note On failure, the process exits, so you don't have to worry about checking the returned
1961  * reference for validity.
1962  *
1963  * @note <b>multi-app safe</b>
1964  */
1965 //--------------------------------------------------------------------------------------------------
1967 (
1968  le_mrc_ScanInformationRef_t scanInformationRef
1969  ///< [IN] Scan information reference
1970 );
1971 
1972 //--------------------------------------------------------------------------------------------------
1973 /**
1974  * This function must be called to check if a cellular network is forbidden by the operator.
1975  *
1976  * @return true The network is forbidden
1977  * @return false The network is allowed
1978  *
1979  * @note On failure, the process exits, so you don't have to worry about checking the returned
1980  * reference for validity.
1981  *
1982  * @note <b>multi-app safe</b>
1983  */
1984 //--------------------------------------------------------------------------------------------------
1986 (
1987  le_mrc_ScanInformationRef_t scanInformationRef
1988  ///< [IN] Scan information reference
1989 );
1990 
1991 //--------------------------------------------------------------------------------------------------
1992 /**
1993  * This function must be called to get the current network name information.
1994  *
1995  * @return
1996  * - LE_OK on success
1997  * - LE_BAD_PARAMETER if nameStr is NULL
1998  * - LE_OVERFLOW if the Home Network Name can't fit in nameStr
1999  * - LE_FAULT on any other failure
2000  *
2001  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2002  * function won't return.
2003  *
2004  * @note <b>multi-app safe</b>
2005  */
2006 //--------------------------------------------------------------------------------------------------
2008 (
2009  char* nameStr,
2010  ///< [OUT] the home network Name
2011  size_t nameStrSize
2012  ///< [IN]
2013 );
2014 
2015 //--------------------------------------------------------------------------------------------------
2016 /**
2017  * This function must be called to get the current network PLMN information.
2018  *
2019  * @return
2020  * - LE_OK on success
2021  * - LE_FAULT on any other failure
2022  *
2023  * @note <b>multi-app safe</b>
2024  */
2025 //--------------------------------------------------------------------------------------------------
2027 (
2028  char* mccStr,
2029  ///< [OUT] the mobile country code
2030  size_t mccStrSize,
2031  ///< [IN]
2032  char* mncStr,
2033  ///< [OUT] the mobile network code
2034  size_t mncStrSize
2035  ///< [IN]
2036 );
2037 
2038 //--------------------------------------------------------------------------------------------------
2039 /**
2040  * This function must be called to get the current Radio Access Technology in use.
2041  *
2042  * @return LE_OK Function succeeded.
2043  * @return LE_BAD_PARAMETER Invalid parameter.
2044  * @return LE_FAULT Function failed to get the Radio Access Technology.
2045  *
2046  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2047  * function won't return.
2048  *
2049  * @note The API returns the RAT only if the device is registered on the network.
2050  * le_mrc_GetNetRegState() function can be called first to obtain the network registration
2051  * state.
2052  *
2053  * @note <b>multi-app safe</b>
2054  */
2055 //--------------------------------------------------------------------------------------------------
2057 (
2058  le_mrc_Rat_t* ratPtr
2059  ///< [OUT] The Radio Access Technology.
2060 );
2061 
2062 //--------------------------------------------------------------------------------------------------
2063 /**
2064  * This function must be called to retrieve the Neighboring Cells information. It creates and
2065  * returns a reference to the Neighboring Cells information.
2066  *
2067  * @return A reference to the Neighboring Cells information.
2068  * @return NULL if no Cells Information are available.
2069  *
2070  * @note <b>multi-app safe</b>
2071  */
2072 //--------------------------------------------------------------------------------------------------
2073 le_mrc_NeighborCellsRef_t le_mrc_GetNeighborCellsInfo
2074 (
2075  void
2076 );
2077 
2078 //--------------------------------------------------------------------------------------------------
2079 /**
2080  * This function must be called to delete the Neighboring Cells information.
2081  *
2082  * @note On failure, the process exits, so you don't have to worry about checking the returned
2083  * reference for validity.
2084  *
2085  * @note <b>multi-app safe</b>
2086  */
2087 //--------------------------------------------------------------------------------------------------
2089 (
2090  le_mrc_NeighborCellsRef_t ngbrCellsRef
2091  ///< [IN] Neighboring Cells reference.
2092 );
2093 
2094 //--------------------------------------------------------------------------------------------------
2095 /**
2096  * This function must be called to get the first Cell Information reference in the list of
2097  * Neighboring Cells information retrieved with le_mrc_GetNeighborCellsInfo().
2098  *
2099  * @return NULL No Cell information object found.
2100  * @return le_mrc_CellInfoRef_t The Cell information object reference.
2101  *
2102  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2103  * function won't return.
2104  *
2105  * @note <b>multi-app safe</b>
2106  */
2107 //--------------------------------------------------------------------------------------------------
2108 le_mrc_CellInfoRef_t le_mrc_GetFirstNeighborCellInfo
2109 (
2110  le_mrc_NeighborCellsRef_t ngbrCellsRef
2111  ///< [IN] Neighboring Cells reference.
2112 );
2113 
2114 //--------------------------------------------------------------------------------------------------
2115 /**
2116  * This function must be called to get the next Cell Information reference in the list of
2117  * Neighboring Cells information retrieved with le_mrc_GetNeighborCellsInfo().
2118  *
2119  * @return NULL No Cell information object found.
2120  * @return le_mrc_CellInfoRef_t Cell information object reference.
2121  *
2122  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2123  * function won't return.
2124  *
2125  * @note <b>multi-app safe</b>
2126  */
2127 //--------------------------------------------------------------------------------------------------
2128 le_mrc_CellInfoRef_t le_mrc_GetNextNeighborCellInfo
2129 (
2130  le_mrc_NeighborCellsRef_t ngbrCellsRef
2131  ///< [IN] Neighboring Cells reference.
2132 );
2133 
2134 //--------------------------------------------------------------------------------------------------
2135 /**
2136  * This function must be called to get the Physical Cell Identifier.
2137  *
2138  * @return The Physical Cell Identifier. UINT32_MAX value is returned if the Cell Identifier is not
2139  * available.
2140  *
2141  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2142  * function won't return.
2143  *
2144  * @note <b>multi-app safe</b>
2145  */
2146 //--------------------------------------------------------------------------------------------------
2147 uint32_t le_mrc_GetNeighborCellId
2148 (
2149  le_mrc_CellInfoRef_t ngbrCellInfoRef
2150  ///< [IN] Cell information reference.
2151 );
2152 
2153 //--------------------------------------------------------------------------------------------------
2154 /**
2155  * This function must be called to get the Location Area Code of a cell.
2156  *
2157  * @return The Location Area Code of a cell. UINT16_MAX value is returned if the value is not
2158  * available.
2159  *
2160  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2161  * function won't return.
2162  *
2163  * @note <b>multi-app safe</b>
2164  */
2165 //--------------------------------------------------------------------------------------------------
2167 (
2168  le_mrc_CellInfoRef_t ngbrCellInfoRef
2169  ///< [IN] Cell information reference.
2170 );
2171 
2172 //--------------------------------------------------------------------------------------------------
2173 /**
2174  * This function must be called to get the signal strength of a cell.
2175  *
2176  * @return The signal strength of a cell in dBm.
2177  *
2178  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2179  * function won't return.
2180  *
2181  * @note <b>multi-app safe</b>
2182  */
2183 //--------------------------------------------------------------------------------------------------
2185 (
2186  le_mrc_CellInfoRef_t ngbrCellInfoRef
2187  ///< [IN] Cell information reference.
2188 );
2189 
2190 //--------------------------------------------------------------------------------------------------
2191 /**
2192  * This function must be called to get the Radio Access Technology of a cell.
2193  *
2194  * @return The Radio Access Technology of a cell.
2195  *
2196  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2197  * function won't return.
2198  *
2199  * @note <b>multi-app safe</b>
2200  */
2201 //--------------------------------------------------------------------------------------------------
2202 le_mrc_Rat_t le_mrc_GetNeighborCellRat
2203 (
2204  le_mrc_CellInfoRef_t ngbrCellInfoRef
2205  ///< [IN] Cell information reference.
2206 );
2207 
2208 //--------------------------------------------------------------------------------------------------
2209 /**
2210  * This function must be called to get the Ec/Io; the received energy per chip divided by the power
2211  * density in the band measured in dBm on the primary CPICH channel of serving cell (negative value)
2212  *
2213  * @return
2214  * - The Ec/Io of a cell given in dB with 1 decimal place. (only applicable for UMTS network).
2215  * - INT32_MAX when the value isn't available.
2216  *
2217  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2218  * function won't return.
2219  *
2220  * @note <b>multi-app safe</b>
2221  */
2222 //--------------------------------------------------------------------------------------------------
2224 (
2225  le_mrc_CellInfoRef_t ngbrCellInfoRef
2226  ///< [IN] Cell information reference.
2227 );
2228 
2229 //--------------------------------------------------------------------------------------------------
2230 /**
2231  * This function must be called to get the RSRP and RSRQ of the Intrafrequency of a LTE cell.
2232  *
2233  * @return
2234  * - LE_OK on success
2235  * - LE_FAULT on failure
2236  *
2237  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2238  * function won't return.
2239  *
2240  * @note <b>multi-app safe</b>
2241  */
2242 //--------------------------------------------------------------------------------------------------
2244 (
2245  le_mrc_CellInfoRef_t ngbrCellInfoRef,
2246  ///< [IN] Cell information reference.
2247  int32_t* rsrqPtr,
2248  ///< [OUT] Reference Signal Received Quality value in dB with 1 decimal
2249  ///< place
2250  int32_t* rsrpPtr
2251  ///< [OUT] Reference Signal Receiver Power value in dBm with 1 decimal
2252  ///< place
2253 );
2254 
2255 //--------------------------------------------------------------------------------------------------
2256 /**
2257  * This function must be called to get the RSRP and RSRQ of the Interfrequency of a LTE cell.
2258  *
2259  * @return
2260  * - LE_OK on success
2261  * - LE_FAULT on failure
2262  *
2263  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2264  * function won't return.
2265  *
2266  * @note <b>multi-app safe</b>
2267  */
2268 //--------------------------------------------------------------------------------------------------
2270 (
2271  le_mrc_CellInfoRef_t ngbrCellInfoRef,
2272  ///< [IN] Cell information reference.
2273  int32_t* rsrqPtr,
2274  ///< [OUT] Reference Signal Received Quality value in dB with 1 decimal
2275  ///< place
2276  int32_t* rsrpPtr
2277  ///< [OUT] Reference Signal Receiver Power value in dBm with 1 decimal
2278  ///< place
2279 );
2280 
2281 //--------------------------------------------------------------------------------------------------
2282 /**
2283  * This function must be called to measure the signal metrics. It creates and returns a reference
2284  * to the signal metrics.
2285  *
2286  * @return A reference to the signal metrics.
2287  * @return NULL if no signal metrics are available.
2288  *
2289  * @note <b>multi-app safe</b>
2290  */
2291 //--------------------------------------------------------------------------------------------------
2292 le_mrc_MetricsRef_t le_mrc_MeasureSignalMetrics
2293 (
2294  void
2295 );
2296 
2297 //--------------------------------------------------------------------------------------------------
2298 /**
2299  * This function must be called to delete the the signal metrics.
2300  *
2301  * @note On failure, the process exits, so you don't have to worry about checking the returned
2302  * reference for validity.
2303  *
2304  * @note <b>multi-app safe</b>
2305  */
2306 //--------------------------------------------------------------------------------------------------
2308 (
2309  le_mrc_MetricsRef_t MetricsRef
2310  ///< [IN] Signal metrics reference.
2311 );
2312 
2313 //--------------------------------------------------------------------------------------------------
2314 /**
2315  * This function returns the Radio Access Technology of the signal metrics.
2316  *
2317  * @return The Radio Access Technology of the signal measure.
2318  *
2319  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2320  * function won't return.
2321  *
2322  * @note <b>multi-app safe</b>
2323  */
2324 //--------------------------------------------------------------------------------------------------
2325 le_mrc_Rat_t le_mrc_GetRatOfSignalMetrics
2326 (
2327  le_mrc_MetricsRef_t MetricsRef
2328  ///< [IN] Signal metrics reference.
2329 );
2330 
2331 //--------------------------------------------------------------------------------------------------
2332 /**
2333  * This function returns the signal strength in dBm and the bit error rate measured on GSM network.
2334  *
2335  * @return
2336  * - LE_OK on success
2337  * - LE_FAULT on failure
2338  *
2339  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2340  * function won't return.
2341  *
2342  * @note <b>multi-app safe</b>
2343  */
2344 //--------------------------------------------------------------------------------------------------
2346 (
2347  le_mrc_MetricsRef_t MetricsRef,
2348  ///< [IN] Signal metrics reference.
2349  int32_t* rssiPtr,
2350  ///< [OUT] Signal strength in dBm
2351  uint32_t* berPtr
2352  ///< [OUT] Bit error rate.
2353 );
2354 
2355 //--------------------------------------------------------------------------------------------------
2356 /**
2357  * This function returns the signal metrics measured on UMTS or TD-SCDMA networks.
2358  *
2359  * @return
2360  * - LE_OK on success
2361  * - LE_FAULT on failure
2362  *
2363  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2364  * function won't return.
2365  *
2366  * @note <b>multi-app safe</b>
2367  */
2368 //--------------------------------------------------------------------------------------------------
2370 (
2371  le_mrc_MetricsRef_t MetricsRef,
2372  ///< [IN] Signal metrics reference.
2373  int32_t* ssPtr,
2374  ///< [OUT] Signal strength in dBm
2375  uint32_t* blerPtr,
2376  ///< [OUT] Block error rate
2377  int32_t* ecioPtr,
2378  ///< [OUT] Ec/Io value in dB with 1 decimal place (-15 = -1.5 dB) (Negative
2379  ///< value)
2380  int32_t* rscpPtr,
2381  ///< [OUT] Measured RSCP in dBm (negative value, value INT32_MAX means
2382  ///< that RSCP is not available)
2383  int32_t* sinrPtr
2384  ///< [OUT] Measured SINR in dB (only applicable for TD-SCDMA network, value
2385  ///< INT32_MAX means that the SINR is not available)
2386 );
2387 
2388 //--------------------------------------------------------------------------------------------------
2389 /**
2390  * This function returns the signal metrics measured on LTE network.
2391  *
2392  * @return
2393  * - LE_OK on success
2394  * - LE_FAULT on failure
2395  * - sinrPtr and ioPtr return INT32_MAX when the value isn't available.
2396  *
2397  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2398  * function won't return.
2399  *
2400  * @note <b>multi-app safe</b>
2401  */
2402 //--------------------------------------------------------------------------------------------------
2404 (
2405  le_mrc_MetricsRef_t MetricsRef,
2406  ///< [IN] Signal metrics reference.
2407  int32_t* ssPtr,
2408  ///< [OUT] Signal strength in dBm
2409  uint32_t* blerPtr,
2410  ///< [OUT] Block error rate
2411  int32_t* rsrqPtr,
2412  ///< [OUT] RSRQ value in dB as measured by L1 with 1 decimal place
2413  int32_t* rsrpPtr,
2414  ///< [OUT] Current RSRP in dBm as measured by L1 with 1 decimal place
2415  int32_t* snrPtr
2416  ///< [OUT] SNR level in dB with 1 decimal place (15 = 1.5 dB)
2417 );
2418 
2419 //--------------------------------------------------------------------------------------------------
2420 /**
2421  * This function returns the signal metrics measured on CDMA network.
2422  *
2423  * @return
2424  * - LE_OK on success
2425  * - LE_FAULT on failure
2426  * - rscpPtr and sinrPtr return INT32_MAX when the value isn't available.
2427  *
2428  * @note If the caller is passing a bad pointer into this function, it's a fatal error, the
2429  * function won't return.
2430  *
2431  * @note <b>multi-app safe</b>
2432  */
2433 //--------------------------------------------------------------------------------------------------
2435 (
2436  le_mrc_MetricsRef_t MetricsRef,
2437  ///< [IN] Signal metrics reference.
2438  int32_t* ssPtr,
2439  ///< [OUT] Signal strength in dBm
2440  uint32_t* erPtr,
2441  ///< [OUT] Frame/Packet error rate
2442  int32_t* ecioPtr,
2443  ///< [OUT] ECIO value in dB with 1 decimal place (-15 = -1.5 dB) (Negative
2444  ///< value)
2445  int32_t* sinrPtr,
2446  ///< [OUT] SINR level in dB with 1 decimal place, (only applicable for
2447  ///< 1xEV-DO, value INT32_MAX means that the value is not available)
2448  int32_t* ioPtr
2449  ///< [OUT] Received IO in dBm (only applicable for 1xEV-DO, value INT32_MAX
2450  ///< means that the value is not available)
2451 );
2452 
2453 //--------------------------------------------------------------------------------------------------
2454 /**
2455  * This function must be called to get the serving Cell Identifier.
2456  *
2457  * @return The Cell Identifier. UINT32_MAX value is returned if the value is not available.
2458  *
2459  * @note When the module is in UMTS network, the API returns the serving UTRAN Cell Identity (UC-Id)
2460  * which is used to identify the cell uniquely.
2461  * It is composed of the Controlling Radio Network Controller Identifier (CRNC-Id, 12 bits) and the
2462  * Cell Identifier (C-Id, 16 bits). (3GPP 25.401, section 6.1.5)
2463  * The Cell Identifier is coded in the lower 2 bytes of the 4 bytes UC-Id and the CRNC-Id is coded
2464  * in the upper 2 bytes.
2465  * Example: the API returns 7807609 -> 0x772279 (CRNC-Id = 0x77 , cell ID = 0x2279)
2466  *
2467  * @note <b>multi-app safe</b>
2468  */
2469 //--------------------------------------------------------------------------------------------------
2470 uint32_t le_mrc_GetServingCellId
2471 (
2472  void
2473 );
2474 
2475 //--------------------------------------------------------------------------------------------------
2476 /**
2477  * This function must be called to get the Location Area Code of the serving cell.
2478  *
2479  * @return The Location Area Code. UINT32_MAX value is returned if the value is not available.
2480  *
2481  * @note <b>multi-app safe</b>
2482  */
2483 //--------------------------------------------------------------------------------------------------
2485 (
2486  void
2487 );
2488 
2489 //--------------------------------------------------------------------------------------------------
2490 /**
2491  * This function must be called to get the Tracking Area Code of the serving cell (LTE only).
2492  *
2493  * @return The Tracking Area Code. UINT16_MAX value is returned if the value is not available.
2494  *
2495  * @note <b>multi-app safe</b>
2496  */
2497 //--------------------------------------------------------------------------------------------------
2499 (
2500  void
2501 );
2502 
2503 //--------------------------------------------------------------------------------------------------
2504 /**
2505  * Get the Bit mask for 2G/3G Band capabilities.
2506  *
2507  * @return
2508  * - LE_OK on success
2509  * - LE_FAULT on failure
2510  * - LE_UNSUPPORTED Unable to get the 2G/3G Band capabilities on this platform
2511  *
2512  * @note <b>multi-app safe</b>
2513  */
2514 //--------------------------------------------------------------------------------------------------
2516 (
2517  le_mrc_BandBitMask_t* bandMaskPtrPtr
2518  ///< [OUT] Bit mask for 2G/3G Band capabilities.
2519 );
2520 
2521 //--------------------------------------------------------------------------------------------------
2522 /**
2523  * Get the Bit mask for LTE Band capabilities.
2524  *
2525  * @return
2526  * - LE_OK on success
2527  * - LE_FAULT on failure
2528  * - LE_UNSUPPORTED Unable to get the LTE Band capabilities on this platform
2529  *
2530  * @note <b>multi-app safe</b>
2531  */
2532 //--------------------------------------------------------------------------------------------------
2534 (
2535  le_mrc_LteBandBitMask_t* bandMaskPtrPtr
2536  ///< [OUT] Bit mask for LTE Band capabilities.
2537 );
2538 
2539 //--------------------------------------------------------------------------------------------------
2540 /**
2541  * Get the Bit mask for TD-SCDMA Band capabilities.
2542  *
2543  * @return
2544  * - LE_OK on success
2545  * - LE_FAULT on failure
2546  * - LE_UNSUPPORTED Unable to get the TD-SCDMA Band Capabilities on this platform
2547  *
2548  * @note <b>multi-app safe</b>
2549  */
2550 //--------------------------------------------------------------------------------------------------
2552 (
2553  le_mrc_TdScdmaBandBitMask_t* bandMaskPtrPtr
2554  ///< [OUT] Bit mask for TD-SCDMA Band capabilities.
2555 );
2556 
2557 //--------------------------------------------------------------------------------------------------
2558 /**
2559  * Add handler function for EVENT 'le_mrc_NetworkReject'
2560  *
2561  * Event to report network reject indication.
2562  *
2563  */
2564 //--------------------------------------------------------------------------------------------------
2565 le_mrc_NetworkRejectHandlerRef_t le_mrc_AddNetworkRejectHandler
2566 (
2567  le_mrc_NetworkRejectHandlerFunc_t handlerPtr,
2568  ///< [IN]
2569  void* contextPtr
2570  ///< [IN]
2571 );
2572 
2573 //--------------------------------------------------------------------------------------------------
2574 /**
2575  * Remove handler function for EVENT 'le_mrc_NetworkReject'
2576  */
2577 //--------------------------------------------------------------------------------------------------
2579 (
2580  le_mrc_NetworkRejectHandlerRef_t handlerRef
2581  ///< [IN]
2582 );
2583 
2584 //--------------------------------------------------------------------------------------------------
2585 /**
2586  * Add handler function for EVENT 'le_mrc_NetRegReject'
2587  *
2588  * Event to report network registration reject indication.
2589  * NetworkReject will be deprecated.
2590  */
2591 //--------------------------------------------------------------------------------------------------
2592 le_mrc_NetRegRejectHandlerRef_t le_mrc_AddNetRegRejectHandler
2593 (
2594  le_mrc_NetRegRejectHandlerFunc_t handlerPtr,
2595  ///< [IN]
2596  void* contextPtr
2597  ///< [IN]
2598 );
2599 
2600 //--------------------------------------------------------------------------------------------------
2601 /**
2602  * Remove handler function for EVENT 'le_mrc_NetRegReject'
2603  */
2604 //--------------------------------------------------------------------------------------------------
2606 (
2607  le_mrc_NetRegRejectHandlerRef_t handlerRef
2608  ///< [IN]
2609 );
2610 
2611 //--------------------------------------------------------------------------------------------------
2612 /**
2613  * Add handler function for EVENT 'le_mrc_JammingDetectionEvent'
2614  *
2615  * This event provides information on jamming detection.
2616  */
2617 //--------------------------------------------------------------------------------------------------
2618 le_mrc_JammingDetectionEventHandlerRef_t le_mrc_AddJammingDetectionEventHandler
2619 (
2620  le_mrc_JammingDetectionHandlerFunc_t handlerPtr,
2621  ///< [IN]
2622  void* contextPtr
2623  ///< [IN]
2624 );
2625 
2626 //--------------------------------------------------------------------------------------------------
2627 /**
2628  * Remove handler function for EVENT 'le_mrc_JammingDetectionEvent'
2629  */
2630 //--------------------------------------------------------------------------------------------------
2632 (
2633  le_mrc_JammingDetectionEventHandlerRef_t handlerRef
2634  ///< [IN]
2635 );
2636 
2637 //--------------------------------------------------------------------------------------------------
2638 /**
2639  * Start the jamming detection monitoring.
2640  *
2641  * @warning The jamming detection feature might be limited by the platform.
2642  * Please refer to the platform documentation @ref platformConstraintsMdc.
2643  *
2644  * @return
2645  * - LE_OK The function succeeded.
2646  * - LE_FAULT The function failed.
2647  * - LE_DUPLICATE The feature is already activated and an activation is requested.
2648  * - LE_UNSUPPORTED The feature is not supported.
2649  */
2650 //--------------------------------------------------------------------------------------------------
2652 (
2653  void
2654 );
2655 
2656 //--------------------------------------------------------------------------------------------------
2657 /**
2658  * Stop the jamming detection monitoring.
2659  *
2660  * @return
2661  * - LE_OK The function succeeded.
2662  * - LE_FAULT The function failed or the application did not start the jamming detection.
2663  * - LE_UNSUPPORTED The feature is not supported.
2664  */
2665 //--------------------------------------------------------------------------------------------------
2667 (
2668  void
2669 );
2670 
2671 //--------------------------------------------------------------------------------------------------
2672 /**
2673  * Set the SAR backoff state
2674  *
2675  * @warning The SAR backoff feature might be unsupported by some platforms.
2676  * Please refer to the platform documentation @ref platformConstraintsMdc.
2677  *
2678  * @return
2679  * - LE_OK The function succeeded.
2680  * - LE_FAULT The function failed.
2681  * - LE_UNSUPPORTED The feature is not supported.
2682  * - LE_OUT_OF_RANGE The provided index is out of range.
2683  */
2684 //--------------------------------------------------------------------------------------------------
2686 (
2687  uint8_t state
2688  ///< [IN] New state to enable. By default, SAR is disabled (state = 0).
2689  ///< Refer to @ref platformConstraitsMdc for the number of maximum states.
2690 );
2691 
2692 //--------------------------------------------------------------------------------------------------
2693 /**
2694  * Get the SAR backoff state
2695  *
2696  * @warning The SAR backoff feature might be unsupported by some platforms.
2697  * Please refer to the platform documentation @ref platformConstraintsMdc.
2698  *
2699  * @return
2700  * - LE_OK The function succeeded.
2701  * - LE_FAULT The function failed.
2702  * - LE_UNSUPPORTED The feature is not supported.
2703  */
2704 //--------------------------------------------------------------------------------------------------
2706 (
2707  uint8_t* statePtr
2708  ///< [OUT] Current state. By default, SAR is disabled (state = 0).
2709  ///< Refer to @ref platformConstraitsMdc for the number of maximum states.
2710 );
2711 
2712 //--------------------------------------------------------------------------------------------------
2713 /**
2714  * Get the serving cell radio frequency channel number. The EARFCN is in the range from 0 to 262143.
2715  *
2716  * @return The serving cell frequency channel number. UINT32_MAX value is returned if the value is
2717  * not available.
2718  */
2719 //--------------------------------------------------------------------------------------------------
2721 (
2722  void
2723 );
2724 
2725 //--------------------------------------------------------------------------------------------------
2726 /**
2727  * Get the neighbor cell radio frequency channel number. The EARFCN is in the range from 0
2728  * to 262143.
2729  *
2730  * @return The neighbor cell frequency channel number. UINT32_MAX value is returned if the value is
2731  * not available.
2732  */
2733 //--------------------------------------------------------------------------------------------------
2735 (
2736  le_mrc_CellInfoRef_t ngbrCellInfoRef
2737  ///< [IN] The cell information reference
2738 );
2739 
2740 //--------------------------------------------------------------------------------------------------
2741 /**
2742  * Get the serving cell timing advance index value. Timing advance index value is in the range
2743  * from 0 to 1280.
2744  *
2745  * @return The serving cell timing advance index value. UINT32_MAX value is returned if the value
2746  * is not available.
2747  */
2748 //--------------------------------------------------------------------------------------------------
2750 (
2751  void
2752 );
2753 
2754 //--------------------------------------------------------------------------------------------------
2755 /**
2756  * Get the physical serving cell Id. The physical cell Id is in the range from 0 to 503.
2757  *
2758  * @return The physical serving cell Id. UINT16_MAX value is returned if the value is
2759  * not available.
2760  */
2761 //--------------------------------------------------------------------------------------------------
2763 (
2764  void
2765 );
2766 
2767 //--------------------------------------------------------------------------------------------------
2768 /**
2769  * Get the neighbor physical cell Id. The physical cell Id is in the range from 0 to 503.
2770  *
2771  * @return The physical serving cell Id. UINT16_MAX value is returned if the value is
2772  * not available.
2773  */
2774 //--------------------------------------------------------------------------------------------------
2776 (
2777  le_mrc_CellInfoRef_t ngbrCellInfoRef
2778  ///< [IN] The cell information reference
2779 );
2780 
2781 //--------------------------------------------------------------------------------------------------
2782 /**
2783  * Get the Base Station Identity Code (BSIC) for the serving cell on GSM network.
2784  *
2785  * @return LE_OK The function succeeded.
2786  * @return LE_BAD_PARAMETER Bad parameter passed to the function
2787  * @return LE_FAULT The function failed.
2788  * @return LE_UNAVAILABLE The BSIC is not available. The BSIC value is set to UINT8_MAX.
2789  */
2790 //--------------------------------------------------------------------------------------------------
2792 (
2793  uint8_t* BSICPtr
2794  ///< [OUT] The BSIC value
2795 );
2796 
2797 //--------------------------------------------------------------------------------------------------
2798 /**
2799  * Get the Base Station Identity Code (BSIC) for a neighbour cell on GSM network.
2800  *
2801  * @return LE_OK The function succeeded.
2802  * @return LE_BAD_PARAMETER Bad parameter passed to the function
2803  * @return LE_FAULT The function failed.
2804  * @return LE_UNAVAILABLE The BSIC is not available. The BSIC value is set to UINT8_MAX.
2805  */
2806 //--------------------------------------------------------------------------------------------------
2808 (
2809  le_mrc_CellInfoRef_t ngbrCellInfoRef,
2810  ///< [IN] The cell information reference.
2811  uint8_t* bsicPtr
2812  ///< [OUT] The BSIC value
2813 );
2814 
2815 #endif // LE_MRC_INTERFACE_H_INCLUDE_GUARD
le_result_t le_mrc_GetLteBandCapabilities(le_mrc_LteBandBitMask_t *bandMaskPtrPtr)
uint32_t le_mrc_GetNeighborCellId(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_result_t le_mrc_GetPreferredOperatorDetails(le_mrc_PreferredOperatorRef_t preferredOperatorRef, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize, le_mrc_RatBitMask_t *ratMaskPtr)
le_result_t le_mrc_GetGsmSignalMetrics(le_mrc_MetricsRef_t MetricsRef, int32_t *rssiPtr, uint32_t *berPtr)
le_result_t le_mrc_GetSignalQual(uint32_t *qualityPtr)
uint16_t le_mrc_GetServingCellLteTracAreaCode(void)
void le_mrc_DeleteNeighborCellsInfo(le_mrc_NeighborCellsRef_t ngbrCellsRef)
le_mrc_CellInfoRef_t le_mrc_GetNextNeighborCellInfo(le_mrc_NeighborCellsRef_t ngbrCellsRef)
void le_mrc_RemovePacketSwitchedChangeHandler(le_mrc_PacketSwitchedChangeHandlerRef_t handlerRef)
le_result_t le_mrc_GetNetRegState(le_mrc_NetRegState_t *statePtr)
le_mrc_RatChangeHandlerRef_t le_mrc_AddRatChangeHandler(le_mrc_RatChangeHandlerFunc_t handlerPtr, void *contextPtr)
le_result_t le_mrc_SetAutomaticRegisterMode(void)
le_result_t le_mrc_SetSignalStrengthIndThresholds(le_mrc_Rat_t rat, int32_t lowerRangeThreshold, int32_t upperRangeThreshold)
le_result_t le_mrc_RemovePreferredOperator(const char *LE_NONNULL mcc, const char *LE_NONNULL mnc)
le_mrc_SignalStrengthChangeHandlerRef_t le_mrc_AddSignalStrengthChangeHandler(le_mrc_Rat_t rat, int32_t lowerRangeThreshold, int32_t upperRangeThreshold, le_mrc_SignalStrengthChangeHandlerFunc_t handlerPtr, void *contextPtr)
le_result_t le_mrc_GetRadioPower(le_onoff_t *powerPtr)
uint32_t le_mrc_GetServingCellId(void)
le_mrc_NetRegStateEventHandlerRef_t le_mrc_AddNetRegStateEventHandler(le_mrc_NetRegStateHandlerFunc_t handlerPtr, void *contextPtr)
void(* le_mrc_DisconnectHandler_t)(void *)
Definition: le_mrc_interface.h:529
le_result_t
Definition: le_basics.h:45
le_result_t le_mrc_SetRadioPower(le_onoff_t power)
le_mrc_PlmnInformationRef_t le_mrc_GetFirstPlmnInfo(le_mrc_PciScanInformationRef_t pciScanInformationRef)
le_result_t le_mrc_GetCurrentNetworkMccMnc(char *mccStr, size_t mccStrSize, char *mncStr, size_t mncStrSize)
le_result_t le_mrc_SetTdScdmaBandPreferences(le_mrc_TdScdmaBandBitMask_t bandMask)
le_result_t le_mrc_GetPacketSwitchedState(le_mrc_NetRegState_t *statePtr)
le_result_t le_mrc_GetNeighborCellGsmBsic(le_mrc_CellInfoRef_t ngbrCellInfoRef, uint8_t *bsicPtr)
le_mrc_Rat_t le_mrc_GetRatOfSignalMetrics(le_mrc_MetricsRef_t MetricsRef)
le_result_t le_mrc_GetTdScdmaBandPreferences(le_mrc_TdScdmaBandBitMask_t *bandMaskPtrPtr)
void le_mrc_DeleteSignalMetrics(le_mrc_MetricsRef_t MetricsRef)
le_mrc_CellInfoRef_t le_mrc_GetFirstNeighborCellInfo(le_mrc_NeighborCellsRef_t ngbrCellsRef)
le_result_t le_mrc_GetCdmaSignalMetrics(le_mrc_MetricsRef_t MetricsRef, int32_t *ssPtr, uint32_t *erPtr, int32_t *ecioPtr, int32_t *sinrPtr, int32_t *ioPtr)
le_result_t le_mrc_SetManualRegisterMode(const char *LE_NONNULL mcc, const char *LE_NONNULL mnc)
le_result_t le_mrc_GetNeighborCellLteIntraFreq(le_mrc_CellInfoRef_t ngbrCellInfoRef, int32_t *rsrqPtr, int32_t *rsrpPtr)
uint32_t le_mrc_GetNeighborCellEarfcn(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_mrc_PlmnInformationRef_t le_mrc_GetNextPlmnInfo(le_mrc_PciScanInformationRef_t plmnRef)
le_result_t le_mrc_TryConnectService(void)
le_mrc_NetRegRejectHandlerRef_t le_mrc_AddNetRegRejectHandler(le_mrc_NetRegRejectHandlerFunc_t handlerPtr, void *contextPtr)
uint16_t le_mrc_GetPhysicalServingLteCellId(void)
le_result_t le_mrc_SetSignalStrengthIndDelta(le_mrc_Rat_t rat, uint16_t delta)
le_result_t le_mrc_GetRatPreferences(le_mrc_RatBitMask_t *ratMaskPtrPtr)
le_mrc_ScanInformationListRef_t le_mrc_PerformCellularNetworkScan(le_mrc_RatBitMask_t ratMask)
le_result_t le_mrc_SetBandPreferences(le_mrc_BandBitMask_t bandMask)
le_result_t le_mrc_SetRatPreferences(le_mrc_RatBitMask_t ratMask)
void le_mrc_DeleteCellularNetworkScan(le_mrc_ScanInformationListRef_t scanInformationListRef)
int32_t le_mrc_GetNeighborCellRxLevel(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_mrc_PacketSwitchedChangeHandlerRef_t le_mrc_AddPacketSwitchedChangeHandler(le_mrc_PacketSwitchedChangeHandlerFunc_t packetHandlerPtr, void *contextPtr)
le_result_t le_mrc_GetNeighborCellLteInterFreq(le_mrc_CellInfoRef_t ngbrCellInfoRef, int32_t *rsrqPtr, int32_t *rsrpPtr)
le_result_t le_mrc_GetServingCellGsmBsic(uint8_t *BSICPtr)
void le_mrc_RemoveSignalStrengthChangeHandler(le_mrc_SignalStrengthChangeHandlerRef_t handlerRef)
le_result_t le_mrc_SetSarBackoffState(uint8_t state)
le_mrc_NeighborCellsRef_t le_mrc_GetNeighborCellsInfo(void)
le_result_t le_mrc_GetPciScanMccMnc(le_mrc_PlmnInformationRef_t plmnRef, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
le_mrc_Rat_t le_mrc_GetCellularNetworkRat(le_mrc_ScanInformationRef_t scanInformationRef)
uint32_t le_mrc_GetPciScanGlobalCellId(le_mrc_PciScanInformationRef_t pciScanInformationRef)
void le_mrc_RemoveRatChangeHandler(le_mrc_RatChangeHandlerRef_t handlerRef)
uint32_t le_mrc_GetServingCellTimingAdvance(void)
void le_mrc_RemoveNetRegRejectHandler(le_mrc_NetRegRejectHandlerRef_t handlerRef)
le_result_t le_mrc_GetSarBackoffState(uint8_t *statePtr)
uint32_t le_mrc_GetServingCellLocAreaCode(void)
le_mrc_PreferredOperatorRef_t le_mrc_GetFirstPreferredOperator(le_mrc_PreferredOperatorListRef_t preferredOperatorListRef)
le_mrc_PciScanInformationRef_t le_mrc_GetFirstPciScanInfo(le_mrc_PciScanInformationListRef_t scanInformationListRef)
void le_mrc_PerformCellularNetworkScanAsync(le_mrc_RatBitMask_t ratMask, le_mrc_CellularNetworkScanHandlerFunc_t handlerPtr, void *contextPtr)
le_result_t le_mrc_GetLteSignalMetrics(le_mrc_MetricsRef_t MetricsRef, int32_t *ssPtr, uint32_t *blerPtr, int32_t *rsrqPtr, int32_t *rsrpPtr, int32_t *snrPtr)
void le_mrc_RemoveNetworkRejectHandler(le_mrc_NetworkRejectHandlerRef_t handlerRef)
le_mrc_PciScanInformationRef_t le_mrc_GetNextPciScanInfo(le_mrc_PciScanInformationListRef_t scanInformationListRef)
int32_t le_mrc_GetPlatformSpecificRegistrationErrorCode(void)
le_mrc_PreferredOperatorRef_t le_mrc_GetNextPreferredOperator(le_mrc_PreferredOperatorListRef_t preferredOperatorListRef)
void le_mrc_SetManualRegisterModeAsync(const char *LE_NONNULL mcc, const char *LE_NONNULL mnc, le_mrc_ManualSelectionHandlerFunc_t handlerPtr, void *contextPtr)
LE_FULL_API void le_mrc_SetServerDisconnectHandler(le_mrc_DisconnectHandler_t disconnectHandler, void *contextPtr)
le_result_t le_mrc_GetTdScdmaBandCapabilities(le_mrc_TdScdmaBandBitMask_t *bandMaskPtrPtr)
le_result_t le_mrc_GetRegisterMode(bool *isManualPtrPtr, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
le_result_t le_mrc_SetLteBandPreferences(le_mrc_LteBandBitMask_t bandMask)
bool le_mrc_IsCellularNetworkForbidden(le_mrc_ScanInformationRef_t scanInformationRef)
int32_t le_mrc_GetNeighborCellUmtsEcIo(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_result_t le_mrc_GetCellularNetworkMccMnc(le_mrc_ScanInformationRef_t scanInformationRef, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
le_mrc_ScanInformationRef_t le_mrc_GetNextCellularNetworkScan(le_mrc_ScanInformationListRef_t scanInformationListRef)
le_result_t le_mrc_GetCurrentNetworkName(char *nameStr, size_t nameStrSize)
le_result_t le_mrc_GetRadioAccessTechInUse(le_mrc_Rat_t *ratPtr)
#define LE_FULL_API
Definition: le_apiFeatures.h:40
le_mrc_PreferredOperatorListRef_t le_mrc_GetPreferredOperatorsList(void)
le_result_t le_mrc_GetLteBandPreferences(le_mrc_LteBandBitMask_t *bandMaskPtrPtr)
le_result_t le_mrc_AddPreferredOperator(const char *LE_NONNULL mcc, const char *LE_NONNULL mnc, le_mrc_RatBitMask_t ratMask)
le_result_t le_mrc_GetBandCapabilities(le_mrc_BandBitMask_t *bandMaskPtrPtr)
bool le_mrc_IsCellularNetworkHome(le_mrc_ScanInformationRef_t scanInformationRef)
le_mrc_PciScanInformationListRef_t le_mrc_PerformPciNetworkScan(le_mrc_RatBitMask_t ratMask)
le_result_t le_mrc_GetCellularNetworkName(le_mrc_ScanInformationRef_t scanInformationRef, char *namePtr, size_t namePtrSize)
void le_mrc_ConnectService(void)
void le_mrc_DeletePreferredOperatorsList(le_mrc_PreferredOperatorListRef_t preferredOperatorListRef)
le_mrc_JammingDetectionEventHandlerRef_t le_mrc_AddJammingDetectionEventHandler(le_mrc_JammingDetectionHandlerFunc_t handlerPtr, void *contextPtr)
le_result_t le_mrc_StartJammingDetection(void)
le_result_t le_mrc_StopJammingDetection(void)
le_result_t le_mrc_GetUmtsSignalMetrics(le_mrc_MetricsRef_t MetricsRef, int32_t *ssPtr, uint32_t *blerPtr, int32_t *ecioPtr, int32_t *rscpPtr, int32_t *sinrPtr)
void le_mrc_DisconnectService(void)
bool le_mrc_IsCellularNetworkInUse(le_mrc_ScanInformationRef_t scanInformationRef)
void le_mrc_PerformPciNetworkScanAsync(le_mrc_RatBitMask_t ratMask, le_mrc_PciNetworkScanHandlerFunc_t handlerPtr, void *contextPtr)
uint32_t le_mrc_GetNeighborCellLocAreaCode(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_mrc_MetricsRef_t le_mrc_MeasureSignalMetrics(void)
uint32_t le_mrc_GetServingCellEarfcn(void)
bool le_mrc_IsCellularNetworkAvailable(le_mrc_ScanInformationRef_t scanInformationRef)
void le_mrc_DeletePciNetworkScan(le_mrc_PciScanInformationListRef_t scanInformationListRef)
uint16_t le_mrc_GetPhysicalNeighborLteCellId(le_mrc_CellInfoRef_t ngbrCellInfoRef)
uint16_t le_mrc_GetPciScanCellId(le_mrc_PciScanInformationRef_t pciScanInformationRef)
void le_mrc_RemoveJammingDetectionEventHandler(le_mrc_JammingDetectionEventHandlerRef_t handlerRef)
le_mrc_NetworkRejectHandlerRef_t le_mrc_AddNetworkRejectHandler(le_mrc_NetworkRejectHandlerFunc_t handlerPtr, void *contextPtr)
le_result_t le_mrc_GetBandPreferences(le_mrc_BandBitMask_t *bandMaskPtrPtr)
void le_mrc_RemoveNetRegStateEventHandler(le_mrc_NetRegStateEventHandlerRef_t handlerRef)
le_mrc_ScanInformationRef_t le_mrc_GetFirstCellularNetworkScan(le_mrc_ScanInformationListRef_t scanInformationListRef)
le_mrc_Rat_t le_mrc_GetNeighborCellRat(le_mrc_CellInfoRef_t ngbrCellInfoRef)
le_onoff_t
Definition: le_basics.h:95