le_sms_common.h

Go to the documentation of this file.
1 
2 /*
3  * ====================== WARNING ======================
4  *
5  * THE CONTENTS OF THIS FILE HAVE BEEN AUTO-GENERATED.
6  * DO NOT MODIFY IN ANY WAY.
7  *
8  * ====================== WARNING ======================
9  */
10 /**
11  * @file le_sms_common.h
12  *
13  * Type definitions for le_sms.
14  *
15  */
16 #ifndef LE_SMS_COMMON_H_INCLUDE_GUARD
17 #define LE_SMS_COMMON_H_INCLUDE_GUARD
18 
19 
20 #include "legato.h"
21 
22 // Interface specific includes
23 #include "le_mdmDefs_common.h"
24 
25 #define IFGEN_LE_SMS_PROTOCOL_ID "f41f0fb09505171f88106e1b61be8284"
26 #define IFGEN_LE_SMS_MSG_SIZE 271
27 /** @addtogroup le_sms
28  * @{ **/
29 
30 
31 //--------------------------------------------------------------------------------------------------
32 /**
33  * Time stamp string length.
34  * The string format is "yy/MM/dd,hh:mm:ss+/-zz" (Year/Month/Day,Hour:Min:Seconds+/-TimeZone).
35  * One extra byte is added for the null character.
36  */
37 //--------------------------------------------------------------------------------------------------
38 #define LE_SMS_TIMESTAMP_MAX_LEN 20
39 
40 //--------------------------------------------------------------------------------------------------
41 /**
42  * Time stamp string length (including the null-terminator).
43  */
44 //--------------------------------------------------------------------------------------------------
45 #define LE_SMS_TIMESTAMP_MAX_BYTES 21
46 
47 //--------------------------------------------------------------------------------------------------
48 /**
49  * The text message can be up to 160 characters long.
50  * One extra byte is added for the null character.
51  */
52 //--------------------------------------------------------------------------------------------------
53 #define LE_SMS_TEXT_MAX_LEN 160
54 
55 //--------------------------------------------------------------------------------------------------
56 /**
57  * Test message string length (including the null-terminator).
58  */
59 //--------------------------------------------------------------------------------------------------
60 #define LE_SMS_TEXT_MAX_BYTES 161
61 
62 //--------------------------------------------------------------------------------------------------
63 /**
64  * The raw binary message can be up to 140 bytes long.
65  */
66 //--------------------------------------------------------------------------------------------------
67 #define LE_SMS_BINARY_MAX_BYTES 140
68 
69 //--------------------------------------------------------------------------------------------------
70 /**
71  * The UCS2 message can be up to 140 bytes long (70 characters).
72  */
73 //--------------------------------------------------------------------------------------------------
74 #define LE_SMS_UCS2_MAX_BYTES 140
75 
76 //--------------------------------------------------------------------------------------------------
77 /**
78  * The UCS2 message can be up to 70 characters (140 bytes long).
79  */
80 //--------------------------------------------------------------------------------------------------
81 #define LE_SMS_UCS2_MAX_CHARS 70
82 
83 //--------------------------------------------------------------------------------------------------
84 /**
85  * The PDU payload bytes long.
86  */
87 //--------------------------------------------------------------------------------------------------
88 #define LE_SMS_PDU_MAX_PAYLOAD 140
89 
90 //--------------------------------------------------------------------------------------------------
91 /**
92  * The PDU message can be up to 36 (header) + 140 (payload) bytes long for GSM.
93  */
94 //--------------------------------------------------------------------------------------------------
95 #define LE_SMS_GSM_PDU_MAX_BYTES 176
96 
97 //--------------------------------------------------------------------------------------------------
98 /**
99  * The PDU message can be up to 255 bytes long for CDMA.
100  */
101 //--------------------------------------------------------------------------------------------------
102 #define LE_SMS_PDU_MAX_BYTES 255
103 
104 //--------------------------------------------------------------------------------------------------
105 /**
106  * Message Format.
107  */
108 //--------------------------------------------------------------------------------------------------
109 typedef enum
110 {
112  ///< PDU message format.
114  ///< Text message format.
116  ///< Binary message format.
118  ///< UCS2 message format.
120  ///< Unknown message format.
121 }
123 
124 
125 //--------------------------------------------------------------------------------------------------
126 /**
127  * Message Type.
128  */
129 //--------------------------------------------------------------------------------------------------
130 typedef enum
131 {
133  ///< SMS mobile terminated message.
135  ///< SMS mobile originated message.
137  ///< SMS Cell Broadcast message.
139  ///< SMS Status Report.
140 }
142 
143 
144 //--------------------------------------------------------------------------------------------------
145 /**
146  * Message Status.
147  */
148 //--------------------------------------------------------------------------------------------------
149 typedef enum
150 {
152  ///< Message present in the message storage has been read.
154  ///< Message present in the message storage has not been read.
156  ///< Message saved in the message storage has been sent.
158  ///< Message saved in the message storage has not been sent.
160  ///< Message has been sent.
162  ///< Message has been in the sending pool.
164  ///< Message has not been sent.
166  ///< Message sending has Failed.
168  ///< Message sending has Failed due to timeout.
170  ///< Unknown message status.
171 }
173 
174 
175 //--------------------------------------------------------------------------------------------------
176 /**
177  * CDMA Cell broadcast message languages.
178  */
179 //--------------------------------------------------------------------------------------------------
180 typedef enum
181 {
183  ///< Unknow or Unspecified language.
185  ///< English language.
187  ///< French language.
189  ///< Spanish language.
191  ///< Japanese language.
193  ///< Korean language.
195  ///< Chinese language.
197  ///< Hebrew language.
198  LE_SMS_LANGUAGE_MAX = 8
199  ///<
200 }
202 
203 
204 //--------------------------------------------------------------------------------------------------
205 /**
206  * CDMA Cell broadcast Service Categories.
207  */
208 //--------------------------------------------------------------------------------------------------
209 typedef enum
210 {
212  ///< Unknown or Unspecified.
214  ///< Emergency Broadcast.
216  ///< Administrative.
218  ///< Maintenance.
220  ///< General News Local.
222  ///< General News Regional.
224  ///< General News National.
226  ///< General News International.
228  ///< Business News Local.
230  ///< Business News Regional.
232  ///< Business News National.
234  ///< Business News International.
236  ///< Sports News Local.
238  ///< Sports News Regional.
240  ///< Sports News National.
242  ///< Sports News International.
244  ///< Entertainment News Local.
246  ///< Entertainment News Regional.
248  ///< Entertainment News National.
250  ///< Entertainment News International.
252  ///< Local weather.
254  ///< Area Traffic Reports.
256  ///< Local Airplane Flight Schedules.
258  ///< Restaurants.
260  ///< Lodgings.
262  ///< Retail Directory.
264  ///< Advertisements.
266  ///< Stock Quotes.
268  ///< Employment Opportunities.
270  ///< Medical/Health/Hospitals.
272  ///< Technology News.
274  ///< Multicategory.
276  ///< Card Application Toolkit Protocol Teleservice.
277  LE_SMS_CDMA_SVC_CAT_MAX = 33
278  ///<
279 }
281 
282 
283 //--------------------------------------------------------------------------------------------------
284 /**
285  * SMS storage area.
286  */
287 //--------------------------------------------------------------------------------------------------
288 typedef enum
289 {
291  ///< Non volatile memory storage.
293  ///< Sim SMS storage.
295  ///< Undefined storage.
296 }
298 
299 
300 //--------------------------------------------------------------------------------------------------
301 /**
302  * 3GPP2 Message Error code when the message sending has failed.
303  */
304 //--------------------------------------------------------------------------------------------------
305 typedef enum
306 {
308  ///< The SMS Destination Address is valid but is not.
309  ///< currently allocated to an SMS terminal.
311  ///< The SMS Destination Address is invalid.
313  ///< The network transmission failed due to lack of
314  ///< a network resource or link capacity.
316  ///< A network node failed, a link failed, or a
317  ///< required operation failed.
319  ///< The SMS_TeleserviceIdentifier is not known, is
320  ///< not supported, or is not authorized by an
321  ///< addressed functional entity.
323  ///< A network problem other than identified above.
325  ///< The addressed MS-based SME is known, but it
326  ///< does not respond to a page.
328  ///< The destination MS-based SME is SMS capable,
329  ///< but is currently engaged in a call, a service,
330  ///< or a call mode that precludes the use of SMS,
331  ///< or the destination SME is congested.
333  ///< The destination SME does not acknowledge receipt
334  ///< of the SMS delivery.
336  ///< A required terminal resource is not available to
337  ///< process this message.
339  ///< Delivery is not currently possible.
341  ///< The addressed destination is out of
342  ///< service for an extended period of time.
344  ///< The MS-based SME is no longer at the
345  ///< temporary SMS routing address.
347  ///< A terminal problem other than described above.
349  ///< There is no channel available or there is
350  ///< radio congestion at this time.
352  ///< The MS for an MS-based SME is operating in a
353  ///< mode that does not support SMS at this time.
355  ///< A radio interface problem to an MS-based SME
356  ///< other than described above.
358  ///< The size of a parameter or field is not
359  ///< what is expected.
361  ///< The originating MIN is not recognized.
363  ///< The destination is not authorized to receive
364  ///< the SMS message.
366  ///< The originating supplementary service is
367  ///< not known or supported.
369  ///< The originating supplementary service is
370  ///< not known or supported.
372  ///< An optional parameter that is required
373  ///< for a particular function.
375  ///< A parameter is missing that is mandatory.
376  ///< for a particular message.
378  ///< A known parameter has an unknown or
379  ///< unsupported value.
381  ///< A known parameter has a known but unexpected
382  ///< value.
384  ///< The User Data size is too large for access
385  ///< technology, transport network, or call
386  ///< mode, etc
388  ///< Other general problems.
390  ///< Platform specific code.
392  ///< Undefined reason.
393 }
395 
396 
397 //--------------------------------------------------------------------------------------------------
398 /**
399  * Message Error code when the message sending has failed.
400  */
401 //--------------------------------------------------------------------------------------------------
402 typedef enum
403 {
405  ///< Unassigned (unallocated) number
407  ///< Operator determined barring
409  ///< Call barred
411  ///< Reserved
413  ///< Short message transfer rejected
415  ///< Memory capacity exceeded
417  ///< Destination out of order
419  ///< Unidentified subscriber
421  ///< Facility rejected
423  ///< Unknown subscriber
425  ///< Network out of order
427  ///< Temporary failure
429  ///< Congestion
431  ///< Resources unavailable, unspecified
433  ///< Resources facility not subscribed
435  ///< Resources facility not implemented
437  ///< Invalid short message transfer
438  ///< reference value
440  ///< Sementically incorect message
442  ///< Invalid mandatory information
444  ///< Message type nonexistent or not implemented
446  ///< Message not compatible with short message
447  ///< protocol state
449  ///< Information element nonexistent
450  ///< or not implemented
452  ///< Protocol error, unspecified
454  ///< Interworking, unspecified
456  ///< Telematic interworking not supported
458  ///< Short Message Type 0 not supported
460  ///< Cannot replace short message
462  ///< Unspecified TP-PID error
464  ///< Data coding scheme (alphabet)
465  ///< not supported
467  ///< Message class not supported
469  ///< Unspecified TP-DCS error
471  ///< Command cannot be actioned
473  ///< Command unsupported
475  ///< Unspecified TP-Command error
477  ///< TPDU not supported
479  ///< SC busy
481  ///< No SC subscription
483  ///< SC system failure
485  ///< Invalid SME address
487  ///< Destination SME barred
489  ///< SM Rejected-Duplicate SM
491  ///< TP-VPF not supported
493  ///< TP-VP not supporte
495  ///< (U)SIM SMS storage full
497  ///< No SMS storage capability in (U)SIM
499  ///< Error in MS
501  ///< Memory capacity exceeded
503  ///< (U)SIM Application Toolkit busy
505  ///< (U)SIM data download error
507  ///< Unspecified error cause
509  ///< Platform specific code.
511  ///< Undefined reason.
512 }
514 
515 
516 //--------------------------------------------------------------------------------------------------
517 /**
518  * Declare a reference type for referring to SMS Message objects.
519  */
520 //--------------------------------------------------------------------------------------------------
521 typedef struct le_sms_Msg* le_sms_MsgRef_t;
522 
523 
524 //--------------------------------------------------------------------------------------------------
525 /**
526  * Opaque type for SMS Message Listing.
527  */
528 //--------------------------------------------------------------------------------------------------
529 typedef struct le_sms_MsgList* le_sms_MsgListRef_t;
530 
531 
532 //--------------------------------------------------------------------------------------------------
533 /**
534  * Reference type used by Add/Remove functions for EVENT 'le_sms_RxMessage'
535  */
536 //--------------------------------------------------------------------------------------------------
537 typedef struct le_sms_RxMessageHandler* le_sms_RxMessageHandlerRef_t;
538 
539 
540 //--------------------------------------------------------------------------------------------------
541 /**
542  * Reference type used by Add/Remove functions for EVENT 'le_sms_FullStorageEvent'
543  */
544 //--------------------------------------------------------------------------------------------------
545 typedef struct le_sms_FullStorageEventHandler* le_sms_FullStorageEventHandlerRef_t;
546 
547 
548 //--------------------------------------------------------------------------------------------------
549 /**
550  * Handler for Sending result.
551  */
552 //--------------------------------------------------------------------------------------------------
553 typedef void (*le_sms_CallbackResultFunc_t)
554 (
555  le_sms_MsgRef_t msgRef,
556  ///< Reference to the message object.
557  le_sms_Status_t status,
558  ///< Status result.
559  void* contextPtr
560  ///<
561 );
562 
563 //--------------------------------------------------------------------------------------------------
564 /**
565  * Handler for New Message.
566  *
567  */
568 //--------------------------------------------------------------------------------------------------
569 typedef void (*le_sms_RxMessageHandlerFunc_t)
570 (
571  le_sms_MsgRef_t msgRef,
572  ///< Message reference.
573  void* contextPtr
574  ///<
575 );
576 
577 //--------------------------------------------------------------------------------------------------
578 /**
579  * Handler for full storage indication.
580  *
581  */
582 //--------------------------------------------------------------------------------------------------
583 typedef void (*le_sms_FullStorageHandlerFunc_t)
584 (
585  le_sms_Storage_t storage,
586  ///< storage parameter.
587  void* contextPtr
588  ///<
589 );
590 
591 
592 //--------------------------------------------------------------------------------------------------
593 /**
594  * Get if this client bound locally.
595  */
596 //--------------------------------------------------------------------------------------------------
597 LE_SHARED bool ifgen_le_sms_HasLocalBinding
598 (
599  void
600 );
601 
602 
603 //--------------------------------------------------------------------------------------------------
604 /**
605  * Init data that is common across all threads
606  */
607 //--------------------------------------------------------------------------------------------------
608 LE_SHARED void ifgen_le_sms_InitCommonData
609 (
610  void
611 );
612 
613 
614 //--------------------------------------------------------------------------------------------------
615 /**
616  * Perform common initialization and open a session
617  */
618 //--------------------------------------------------------------------------------------------------
619 LE_SHARED le_result_t ifgen_le_sms_OpenSession
620 (
621  le_msg_SessionRef_t _ifgen_sessionRef,
622  bool isBlocking
623 );
624 
625 //--------------------------------------------------------------------------------------------------
626 /**
627  * Add handler function for EVENT 'le_sms_RxMessage'
628  *
629  * This event provides information on new received messages.
630  *
631  */
632 //--------------------------------------------------------------------------------------------------
633 LE_SHARED le_sms_RxMessageHandlerRef_t ifgen_le_sms_AddRxMessageHandler
634 (
635  le_msg_SessionRef_t _ifgen_sessionRef,
637  ///< [IN]
638  void* contextPtr
639  ///< [IN]
640 );
641 
642 //--------------------------------------------------------------------------------------------------
643 /**
644  * Remove handler function for EVENT 'le_sms_RxMessage'
645  */
646 //--------------------------------------------------------------------------------------------------
647 LE_SHARED void ifgen_le_sms_RemoveRxMessageHandler
648 (
649  le_msg_SessionRef_t _ifgen_sessionRef,
651  ///< [IN]
652 );
653 
654 //--------------------------------------------------------------------------------------------------
655 /**
656  * Add handler function for EVENT 'le_sms_FullStorageEvent'
657  *
658  * This event provides information on full storage indication.
659  *
660  */
661 //--------------------------------------------------------------------------------------------------
662 LE_SHARED le_sms_FullStorageEventHandlerRef_t ifgen_le_sms_AddFullStorageEventHandler
663 (
664  le_msg_SessionRef_t _ifgen_sessionRef,
666  ///< [IN]
667  void* contextPtr
668  ///< [IN]
669 );
670 
671 //--------------------------------------------------------------------------------------------------
672 /**
673  * Remove handler function for EVENT 'le_sms_FullStorageEvent'
674  */
675 //--------------------------------------------------------------------------------------------------
676 LE_SHARED void ifgen_le_sms_RemoveFullStorageEventHandler
677 (
678  le_msg_SessionRef_t _ifgen_sessionRef,
680  ///< [IN]
681 );
682 
683 //--------------------------------------------------------------------------------------------------
684 /**
685  * Create an SMS Message data structure.
686  *
687  * @return Reference to the new Message object.
688  *
689  * @note
690  * On failure, the process exits, so you don't have to worry about checking the returned
691  * reference for validity.
692  */
693 //--------------------------------------------------------------------------------------------------
694 LE_SHARED le_sms_MsgRef_t ifgen_le_sms_Create
695 (
696  le_msg_SessionRef_t _ifgen_sessionRef
697 );
698 
699 //--------------------------------------------------------------------------------------------------
700 /**
701  * Set the Telephone destination number.
702  *
703  * Telephone number is defined in ITU-T recommendations E.164/E.163.
704  * E.164 numbers can have a maximum of fifteen digits and are usually written with a '+' prefix.
705  *
706  * @return LE_NOT_PERMITTED Message is Read-Only.
707  * @return LE_BAD_PARAMETER Telephone destination number length is equal to zero.
708  * @return LE_OK Function succeeded.
709  *
710  * @note If telephone destination number is too long is too long (max LE_MDMDEFS_PHONE_NUM_MAX_LEN
711  * digits), it is a fatal error, the function will not return.
712  *
713  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
714  * function will not return.
715  */
716 //--------------------------------------------------------------------------------------------------
717 LE_SHARED le_result_t ifgen_le_sms_SetDestination
718 (
719  le_msg_SessionRef_t _ifgen_sessionRef,
720  le_sms_MsgRef_t msgRef,
721  ///< [IN] Reference to the message object.
722  const char* LE_NONNULL dest
723  ///< [IN] Telephone number string.
724 );
725 
726 //--------------------------------------------------------------------------------------------------
727 /**
728  * This function must be called to set the Text Message content.
729  *
730  * @return LE_NOT_PERMITTED Message is Read-Only.
731  * @return LE_BAD_PARAMETER Text message length is equal to zero.
732  * @return LE_OK Function succeeded.
733  *
734  * @note Text Message is encoded in ASCII format (ISO8859-15) and characters have to exist in
735  * the GSM 23.038 7 bit alphabet.
736  *
737  * @note If message is too long (max LE_SMS_TEXT_MAX_LEN digits), it is a fatal error, the
738  * function will not return.
739  *
740  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
741  * function will not return.
742  */
743 //--------------------------------------------------------------------------------------------------
744 LE_SHARED le_result_t ifgen_le_sms_SetText
745 (
746  le_msg_SessionRef_t _ifgen_sessionRef,
747  le_sms_MsgRef_t msgRef,
748  ///< [IN] Reference to the message object.
749  const char* LE_NONNULL text
750  ///< [IN] SMS text.
751 );
752 
753 //--------------------------------------------------------------------------------------------------
754 /**
755  * Set the binary message content.
756  *
757  * @return LE_NOT_PERMITTED Message is Read-Only.
758  * @return LE_BAD_PARAMETER Length of the data is equal to zero.
759  * @return LE_OK Function succeeded.
760  *
761  * @note If length of the data is too long (max LE_SMS_BINARY_MAX_BYTES bytes), it is a fatal
762  * error, the function will not return.
763  *
764  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
765  * function will not return.
766  */
767 //--------------------------------------------------------------------------------------------------
768 LE_SHARED le_result_t ifgen_le_sms_SetBinary
769 (
770  le_msg_SessionRef_t _ifgen_sessionRef,
771  le_sms_MsgRef_t msgRef,
772  ///< [IN] Reference to the message object.
773  const uint8_t* binPtr,
774  ///< [IN] Binary data.
775  size_t binSize
776  ///< [IN]
777 );
778 
779 //--------------------------------------------------------------------------------------------------
780 /**
781  * Set the UCS2 message content (16-bit format).
782  *
783  * @return
784  * - LE_NOT_PERMITTED Message is Read-Only.
785  * - LE_BAD_PARAMETER Length of the data is equal to zero.
786  * - LE_OK Function succeeded.
787  *
788  * @note If length of the data is too long (max LE_SMS_UCS2_MAX_CHARS), it is a fatal
789  * error, the function will not return.
790  *
791  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
792  * function will not return.
793  */
794 //--------------------------------------------------------------------------------------------------
795 LE_SHARED le_result_t ifgen_le_sms_SetUCS2
796 (
797  le_msg_SessionRef_t _ifgen_sessionRef,
798  le_sms_MsgRef_t msgRef,
799  ///< [IN] Reference to the message object.
800  const uint16_t* ucs2Ptr,
801  ///< [IN] UCS2 message.
802  size_t ucs2Size
803  ///< [IN]
804 );
805 
806 //--------------------------------------------------------------------------------------------------
807 /**
808  * Set the PDU message content.
809  *
810  * @return LE_NOT_PERMITTED Message is Read-Only.
811  * @return LE_BAD_PARAMETER Length of the data is equal to zero.
812  * @return LE_OK Function succeeded.
813  *
814  * @note If length of the data is too long (max LE_SMS_PDU_MAX_BYTES bytes), it is a fatal error,
815  * the function will not return.
816  *
817  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
818  * function will not return.
819  */
820 //--------------------------------------------------------------------------------------------------
821 LE_SHARED le_result_t ifgen_le_sms_SetPDU
822 (
823  le_msg_SessionRef_t _ifgen_sessionRef,
824  le_sms_MsgRef_t msgRef,
825  ///< [IN] Reference to the message object.
826  const uint8_t* pduPtr,
827  ///< [IN] PDU message.
828  size_t pduSize
829  ///< [IN]
830 );
831 
832 //--------------------------------------------------------------------------------------------------
833 /**
834  * Send an SMS message.
835  *
836  * Verifies first if the parameters are valid, then it checks the modem state can support
837  * message sending.
838  *
839  * @return LE_FORMAT_ERROR Message content is invalid.
840  * @return LE_FAULT Function failed to send the message.
841  * @return LE_OK Function succeeded.
842  * @return LE_TIMEOUT Timeout before the complete sending.
843  *
844  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
845  * function will not return.
846  */
847 //--------------------------------------------------------------------------------------------------
848 LE_SHARED le_result_t ifgen_le_sms_Send
849 (
850  le_msg_SessionRef_t _ifgen_sessionRef,
851  le_sms_MsgRef_t msgRef
852  ///< [IN] Reference to the message object.
853 );
854 
855 //--------------------------------------------------------------------------------------------------
856 /**
857  * Send an asynchronous SMS message.
858  *
859  * Verifies first if the parameters are valid, then it checks the modem state can support
860  * message sending.
861  *
862  * @return LE_FORMAT_ERROR Message content is invalid.
863  * @return LE_FAULT Function failed to send the message.
864  * @return LE_OK Function succeeded.
865  * @return LE_TIMEOUT Timeout before the complete sending.
866  *
867  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
868  * function will not return.
869  */
870 //--------------------------------------------------------------------------------------------------
871 LE_SHARED le_result_t ifgen_le_sms_SendAsync
872 (
873  le_msg_SessionRef_t _ifgen_sessionRef,
874  le_sms_MsgRef_t msgRef,
875  ///< [IN] Reference to the message object.
876  le_sms_CallbackResultFunc_t handlerPtr,
877  ///< [IN] CallBack for sending result.
878  void* contextPtr
879  ///< [IN]
880 );
881 
882 //--------------------------------------------------------------------------------------------------
883 /**
884  * Get the error code when a 3GPP2 message sending has Failed.
885  *
886  * @return The error code
887  *
888  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
889  * function will not return.
890  *
891  * @note It is only applicable for 3GPP2 message sending failure, otherwise
892  * LE_SMS_ERROR_3GPP2_MAX is returned.
893  */
894 //--------------------------------------------------------------------------------------------------
895 LE_SHARED le_sms_ErrorCode3GPP2_t ifgen_le_sms_Get3GPP2ErrorCode
896 (
897  le_msg_SessionRef_t _ifgen_sessionRef,
898  le_sms_MsgRef_t msgRef
899  ///< [IN] Reference to the message object.
900 );
901 
902 //--------------------------------------------------------------------------------------------------
903 /**
904  * Get the Radio Protocol and the Transfer Protocol error code when a 3GPP message sending has
905  * failed.
906  *
907  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
908  * function will not return.
909  *
910  * @note It is only applicable for 3GPP message sending failure, otherwise
911  * LE_SMS_ERROR_3GPP_MAX is returned.
912  */
913 //--------------------------------------------------------------------------------------------------
914 LE_SHARED void ifgen_le_sms_GetErrorCode
915 (
916  le_msg_SessionRef_t _ifgen_sessionRef,
917  le_sms_MsgRef_t msgRef,
918  ///< [IN] Reference to the message object.
919  le_sms_ErrorCode_t* rpCausePtr,
920  ///< [OUT] Radio Protocol cause code.
921  le_sms_ErrorCode_t* tpCausePtr
922  ///< [OUT] Transfer Protocol cause code.
923 );
924 
925 //--------------------------------------------------------------------------------------------------
926 /**
927  * Called to get the platform specific error code.
928  *
929  * Refer to @ref platformConstraintsSpecificErrorCodes for platform specific error code description.
930  *
931  * @return The platform specific error code.
932  *
933  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
934  * function will not return.
935  */
936 //--------------------------------------------------------------------------------------------------
937 LE_SHARED int32_t ifgen_le_sms_GetPlatformSpecificErrorCode
938 (
939  le_msg_SessionRef_t _ifgen_sessionRef,
940  le_sms_MsgRef_t msgRef
941  ///< [IN] Reference to the message object.
942 );
943 
944 //--------------------------------------------------------------------------------------------------
945 /**
946  * Create and asynchronously send a text message.
947  *
948  * @return
949  * - le_sms_Msg Reference to the new Message object pooled.
950  * - NULL Not possible to pool a new message.
951  *
952  * @note If telephone destination number is too long is too long (max LE_MDMDEFS_PHONE_NUM_MAX_LEN
953  * digits), it is a fatal error, the function will not return.
954  * @note If message is too long (max LE_SMS_TEXT_MAX_LEN digits), it is a fatal error, the
955  * function will not return.
956  */
957 //--------------------------------------------------------------------------------------------------
958 LE_SHARED le_sms_MsgRef_t ifgen_le_sms_SendText
959 (
960  le_msg_SessionRef_t _ifgen_sessionRef,
961  const char* LE_NONNULL destStr,
962  ///< [IN] Telephone number string.
963  const char* LE_NONNULL textStr,
964  ///< [IN] SMS text.
965  le_sms_CallbackResultFunc_t handlerPtr,
966  ///< [IN] CallBack for sending result.
967  void* contextPtr
968  ///< [IN]
969 );
970 
971 //--------------------------------------------------------------------------------------------------
972 /**
973  * Create and asynchronously send a PDU message.
974  *
975  * @return
976  * - le_sms_Msg Reference to the new Message object pooled.
977  * - NULL Not possible to pool a new message.
978  *
979  */
980 //--------------------------------------------------------------------------------------------------
981 LE_SHARED le_sms_MsgRef_t ifgen_le_sms_SendPdu
982 (
983  le_msg_SessionRef_t _ifgen_sessionRef,
984  const uint8_t* pduPtr,
985  ///< [IN] PDU message.
986  size_t pduSize,
987  ///< [IN]
988  le_sms_CallbackResultFunc_t handlerPtr,
989  ///< [IN] CallBack for sending result.
990  void* contextPtr
991  ///< [IN]
992 );
993 
994 //--------------------------------------------------------------------------------------------------
995 /**
996  * Delete a Message data structure.
997  *
998  * It deletes the Message data structure and all the allocated memory is freed. If several
999  * users own the Message object (e.g., several handler functions registered for
1000  * SMS message reception), the Message object will only be deleted if one User
1001  * owns the Message object.
1002  *
1003  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1004  * function will not return.
1005  */
1006 //--------------------------------------------------------------------------------------------------
1007 LE_SHARED void ifgen_le_sms_Delete
1008 (
1009  le_msg_SessionRef_t _ifgen_sessionRef,
1010  le_sms_MsgRef_t msgRef
1011  ///< [IN] Reference to the message object.
1012 );
1013 
1014 //--------------------------------------------------------------------------------------------------
1015 /**
1016  * Get the message format.
1017  *
1018  * @return Message format.
1019  *
1020  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1021  * function will not return.
1022  *
1023  */
1024 //--------------------------------------------------------------------------------------------------
1025 LE_SHARED le_sms_Format_t ifgen_le_sms_GetFormat
1026 (
1027  le_msg_SessionRef_t _ifgen_sessionRef,
1028  le_sms_MsgRef_t msgRef
1029  ///< [IN] Reference to the message object.
1030 );
1031 
1032 //--------------------------------------------------------------------------------------------------
1033 /**
1034  * Get the message type.
1035  *
1036  * @return Message type.
1037  *
1038  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1039  * function will not return.
1040  */
1041 //--------------------------------------------------------------------------------------------------
1042 LE_SHARED le_sms_Type_t ifgen_le_sms_GetType
1043 (
1044  le_msg_SessionRef_t _ifgen_sessionRef,
1045  le_sms_MsgRef_t msgRef
1046  ///< [IN] Reference to the message object.
1047 );
1048 
1049 //--------------------------------------------------------------------------------------------------
1050 /**
1051  * Get the Cell Broadcast Message Identifier.
1052  *
1053  * @return
1054  * - LE_FAULT Message is not a cell broadcast type.
1055  * - LE_OK Function succeeded.
1056  *
1057  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1058  * function will not return.
1059  */
1060 //--------------------------------------------------------------------------------------------------
1061 LE_SHARED le_result_t ifgen_le_sms_GetCellBroadcastId
1062 (
1063  le_msg_SessionRef_t _ifgen_sessionRef,
1064  le_sms_MsgRef_t msgRef,
1065  ///< [IN] Reference to the message object.
1066  uint16_t* messageIdPtr
1067  ///< [OUT] Cell Broadcast Message Identifier.
1068 );
1069 
1070 //--------------------------------------------------------------------------------------------------
1071 /**
1072  * Get the Cell Broadcast Message Serial Number.
1073  *
1074  * @return
1075  * - LE_FAULT Message is not a cell broadcast type.
1076  * - LE_OK Function succeeded.
1077  *
1078  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1079  * function will not return.
1080  */
1081 //--------------------------------------------------------------------------------------------------
1082 LE_SHARED le_result_t ifgen_le_sms_GetCellBroadcastSerialNumber
1083 (
1084  le_msg_SessionRef_t _ifgen_sessionRef,
1085  le_sms_MsgRef_t msgRef,
1086  ///< [IN] Reference to the message object.
1087  uint16_t* serialNumberPtr
1088  ///< [OUT] Cell Broadcast Serial Number.
1089 );
1090 
1091 //--------------------------------------------------------------------------------------------------
1092 /**
1093  * Get the Sender Telephone number.
1094  *
1095  * Output parameter is updated with the Telephone number. If the Telephone number string exceeds
1096  * the value of 'len' parameter, LE_OVERFLOW error code is returned and 'tel' is filled until
1097  * 'len-1' characters and a null-character is implicitly appended at the end of 'tel'.
1098  *
1099  * @return LE_NOT_PERMITTED Message is not a received message.
1100  * @return LE_OVERFLOW Telephone number length exceed the maximum length.
1101  * @return LE_OK Function succeeded.
1102  *
1103  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1104  * function will not return.
1105  */
1106 //--------------------------------------------------------------------------------------------------
1107 LE_SHARED le_result_t ifgen_le_sms_GetSenderTel
1108 (
1109  le_msg_SessionRef_t _ifgen_sessionRef,
1110  le_sms_MsgRef_t msgRef,
1111  ///< [IN] Reference to the message object.
1112  char* tel,
1113  ///< [OUT] Telephone number string.
1114  size_t telSize
1115  ///< [IN]
1116 );
1117 
1118 //--------------------------------------------------------------------------------------------------
1119 /**
1120  * Get the Service Center Time Stamp string.
1121  *
1122  * Output parameter is updated with the Time Stamp string. If the Time Stamp string exceeds the
1123  * value of 'len' parameter, a LE_OVERFLOW error code is returned and 'timestamp' is filled until
1124  * 'len-1' characters and a null-character is implicitly appended at the end of 'timestamp'.
1125  *
1126  * @return LE_NOT_PERMITTED Message is not a received message.
1127  * @return LE_OVERFLOW Timestamp number length exceed the maximum length.
1128  * @return LE_OK Function succeeded.
1129  *
1130  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1131  * function will not return.
1132  */
1133 //--------------------------------------------------------------------------------------------------
1134 LE_SHARED le_result_t ifgen_le_sms_GetTimeStamp
1135 (
1136  le_msg_SessionRef_t _ifgen_sessionRef,
1137  le_sms_MsgRef_t msgRef,
1138  ///< [IN] Reference to the message object.
1139  char* timestamp,
1140  ///< [OUT] Message time stamp (in text mode).
1141  ///< string format: "yy/MM/dd,hh:mm:ss+/-zz"
1142  ///< (Year/Month/Day,Hour:Min:Seconds+/-TimeZone)
1143  ///< The time zone indicates the difference, expressed
1144  ///< in quarters of an hours between the local time
1145  ///< and GMT.
1146  size_t timestampSize
1147  ///< [IN]
1148 );
1149 
1150 //--------------------------------------------------------------------------------------------------
1151 /**
1152  * Get the message Length value.
1153  *
1154  * @return Number of characters for text and UCS2 messages, or the length of the data in bytes for
1155  * raw binary messages.
1156  *
1157  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1158  * function will not return.
1159  */
1160 //--------------------------------------------------------------------------------------------------
1161 LE_SHARED size_t ifgen_le_sms_GetUserdataLen
1162 (
1163  le_msg_SessionRef_t _ifgen_sessionRef,
1164  le_sms_MsgRef_t msgRef
1165  ///< [IN] Reference to the message object.
1166 );
1167 
1168 //--------------------------------------------------------------------------------------------------
1169 /**
1170  * Get the text Message.
1171  *
1172  * Output parameter is updated with the text string encoded in ASCII format. If the text string
1173  * exceeds the value of 'len' parameter, LE_OVERFLOW error code is returned and 'text' is filled
1174  * until 'len-1' characters and a null-character is implicitly appended at the end of 'text'.
1175  *
1176  * @return LE_OVERFLOW Message length exceed the maximum length.
1177  * @return LE_OK Function succeeded.
1178  *
1179  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1180  * function will not return.
1181  */
1182 //--------------------------------------------------------------------------------------------------
1183 LE_SHARED le_result_t ifgen_le_sms_GetText
1184 (
1185  le_msg_SessionRef_t _ifgen_sessionRef,
1186  le_sms_MsgRef_t msgRef,
1187  ///< [IN] Reference to the message object.
1188  char* text,
1189  ///< [OUT] SMS text.
1190  size_t textSize
1191  ///< [IN]
1192 );
1193 
1194 //--------------------------------------------------------------------------------------------------
1195 /**
1196  * Get the binary Message.
1197  *
1198  * Output parameters are updated with the binary message content and the length of the raw
1199  * binary message in bytes. If the binary data exceed the value of 'len' input parameter, a
1200  * LE_OVERFLOW error code is returned and 'raw' is filled until 'len' bytes.
1201  *
1202  * @return LE_FORMAT_ERROR Message is not in binary format
1203  * @return LE_OVERFLOW Message length exceed the maximum length.
1204  * @return LE_OK Function succeeded.
1205  *
1206  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1207  * function will not return.
1208  */
1209 //--------------------------------------------------------------------------------------------------
1210 LE_SHARED le_result_t ifgen_le_sms_GetBinary
1211 (
1212  le_msg_SessionRef_t _ifgen_sessionRef,
1213  le_sms_MsgRef_t msgRef,
1214  ///< [IN] Reference to the message object.
1215  uint8_t* binPtr,
1216  ///< [OUT] Binary message.
1217  size_t* binSizePtr
1218  ///< [INOUT]
1219 );
1220 
1221 //--------------------------------------------------------------------------------------------------
1222 /**
1223  * Get the UCS2 Message (16-bit format).
1224  *
1225  * Output parameters are updated with the UCS2 message content and the number of characters. If
1226  * the UCS2 data exceed the value of the length input parameter, a LE_OVERFLOW error
1227  * code is returned and 'ucs2Ptr' is filled until of the number of chars specified.
1228  *
1229  * @return
1230  * - LE_FORMAT_ERROR Message is not in binary format
1231  * - LE_OVERFLOW Message length exceed the maximum length.
1232  * - LE_OK Function succeeded.
1233  *
1234  */
1235 //--------------------------------------------------------------------------------------------------
1236 LE_SHARED le_result_t ifgen_le_sms_GetUCS2
1237 (
1238  le_msg_SessionRef_t _ifgen_sessionRef,
1239  le_sms_MsgRef_t msgRef,
1240  ///< [IN] Reference to the message object.
1241  uint16_t* ucs2Ptr,
1242  ///< [OUT] UCS2 message.
1243  size_t* ucs2SizePtr
1244  ///< [INOUT]
1245 );
1246 
1247 //--------------------------------------------------------------------------------------------------
1248 /**
1249  * Get the PDU message.
1250  *
1251  * Output parameters are updated with the PDU message content and the length of the PDU message
1252  * in bytes. If the PDU data exceed the value of 'len' input parameter, a LE_OVERFLOW error code is
1253  * returned and 'pdu' is filled until 'len' bytes.
1254  *
1255  * @return LE_FORMAT_ERROR Unable to encode the message in PDU (only for outgoing messages).
1256  * @return LE_OVERFLOW Message length exceed the maximum length.
1257  * @return LE_OK Function succeeded.
1258  *
1259  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1260  * function will not return.
1261  */
1262 //--------------------------------------------------------------------------------------------------
1263 LE_SHARED le_result_t ifgen_le_sms_GetPDU
1264 (
1265  le_msg_SessionRef_t _ifgen_sessionRef,
1266  le_sms_MsgRef_t msgRef,
1267  ///< [IN] Reference to the message object.
1268  uint8_t* pduPtr,
1269  ///< [OUT] PDU message.
1270  size_t* pduSizePtr
1271  ///< [INOUT]
1272 );
1273 
1274 //--------------------------------------------------------------------------------------------------
1275 /**
1276  * Get the message Length value.
1277  *
1278  * @return Length of the data in bytes of the PDU message.
1279  *
1280  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1281  * function will not return.
1282  */
1283 //--------------------------------------------------------------------------------------------------
1284 LE_SHARED size_t ifgen_le_sms_GetPDULen
1285 (
1286  le_msg_SessionRef_t _ifgen_sessionRef,
1287  le_sms_MsgRef_t msgRef
1288  ///< [IN] Reference to the message object.
1289 );
1290 
1291 //--------------------------------------------------------------------------------------------------
1292 /**
1293  * Delete an SMS message from the storage area.
1294  *
1295  * Verifies first if the parameter is valid, then it checks the modem state can support
1296  * message deleting.
1297  *
1298  * @return LE_FAULT Function failed to perform the deletion.
1299  * @return LE_NO_MEMORY The message is not present in storage area.
1300  * @return LE_OK Function succeeded.
1301  *
1302  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1303  * function will not return.
1304  */
1305 //--------------------------------------------------------------------------------------------------
1306 LE_SHARED le_result_t ifgen_le_sms_DeleteFromStorage
1307 (
1308  le_msg_SessionRef_t _ifgen_sessionRef,
1309  le_sms_MsgRef_t msgRef
1310  ///< [IN] Reference to the message object.
1311 );
1312 
1313 //--------------------------------------------------------------------------------------------------
1314 /**
1315  * Create an object's reference of the list of received messages
1316  * saved in the SMS message storage area.
1317  *
1318  * @return
1319  * Reference to the List object. Null pointer if no messages have been retrieved.
1320  */
1321 //--------------------------------------------------------------------------------------------------
1322 LE_SHARED le_sms_MsgListRef_t ifgen_le_sms_CreateRxMsgList
1323 (
1324  le_msg_SessionRef_t _ifgen_sessionRef
1325 );
1326 
1327 //--------------------------------------------------------------------------------------------------
1328 /**
1329  * Delete the list of the Messages retrieved from the message
1330  * storage.
1331  *
1332  * @note
1333  * On failure, the process exits, so you don't have to worry about checking the returned
1334  * reference for validity.
1335  */
1336 //--------------------------------------------------------------------------------------------------
1337 LE_SHARED void ifgen_le_sms_DeleteList
1338 (
1339  le_msg_SessionRef_t _ifgen_sessionRef,
1340  le_sms_MsgListRef_t msgListRef
1341  ///< [IN] Messages list.
1342 );
1343 
1344 //--------------------------------------------------------------------------------------------------
1345 /**
1346  * Get the first Message object reference in the list of messages
1347  * retrieved with le_sms_CreateRxMsgList().
1348  *
1349  * @return NULL No message found.
1350  * @return Msg Message object reference.
1351  *
1352  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1353  * function will not return.
1354  */
1355 //--------------------------------------------------------------------------------------------------
1356 LE_SHARED le_sms_MsgRef_t ifgen_le_sms_GetFirst
1357 (
1358  le_msg_SessionRef_t _ifgen_sessionRef,
1359  le_sms_MsgListRef_t msgListRef
1360  ///< [IN] Messages list.
1361 );
1362 
1363 //--------------------------------------------------------------------------------------------------
1364 /**
1365  * Get the next Message object reference in the list of messages
1366  * retrieved with le_sms_CreateRxMsgList().
1367  *
1368  * @return NULL No message found.
1369  * @return Msg Message object reference.
1370  *
1371  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1372  * function will not return.
1373  */
1374 //--------------------------------------------------------------------------------------------------
1375 LE_SHARED le_sms_MsgRef_t ifgen_le_sms_GetNext
1376 (
1377  le_msg_SessionRef_t _ifgen_sessionRef,
1378  le_sms_MsgListRef_t msgListRef
1379  ///< [IN] Messages list.
1380 );
1381 
1382 //--------------------------------------------------------------------------------------------------
1383 /**
1384  * Read the Message status (Received Read, Received Unread, Stored
1385  * Sent, Stored Unsent).
1386  *
1387  * @return Status of the message.
1388  *
1389  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1390  * function will not return.
1391  */
1392 //--------------------------------------------------------------------------------------------------
1393 LE_SHARED le_sms_Status_t ifgen_le_sms_GetStatus
1394 (
1395  le_msg_SessionRef_t _ifgen_sessionRef,
1396  le_sms_MsgRef_t msgRef
1397  ///< [IN] Messages list.
1398 );
1399 
1400 //--------------------------------------------------------------------------------------------------
1401 /**
1402  * Mark a message as 'read'.
1403  *
1404  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1405  * function will not return.
1406  */
1407 //--------------------------------------------------------------------------------------------------
1408 LE_SHARED void ifgen_le_sms_MarkRead
1409 (
1410  le_msg_SessionRef_t _ifgen_sessionRef,
1411  le_sms_MsgRef_t msgRef
1412  ///< [IN] Messages list.
1413 );
1414 
1415 //--------------------------------------------------------------------------------------------------
1416 /**
1417  * Mark a message as 'unread'.
1418  *
1419  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1420  * function will not return.
1421  */
1422 //--------------------------------------------------------------------------------------------------
1423 LE_SHARED void ifgen_le_sms_MarkUnread
1424 (
1425  le_msg_SessionRef_t _ifgen_sessionRef,
1426  le_sms_MsgRef_t msgRef
1427  ///< [IN] Messages list.
1428 );
1429 
1430 //--------------------------------------------------------------------------------------------------
1431 /**
1432  * Get the SMS center address.
1433  *
1434  * Output parameter is updated with the SMS Service center address. If the Telephone number string exceeds
1435  * the value of 'len' parameter, LE_OVERFLOW error code is returned and 'tel' is filled until
1436  * 'len-1' characters and a null-character is implicitly appended at the end of 'tel'.
1437  *
1438  * @return
1439  * - LE_FAULT Service is not available.
1440  * - LE_OVERFLOW Telephone number length exceed the maximum length.
1441  * - LE_OK Function succeeded.
1442  *
1443  */
1444 //--------------------------------------------------------------------------------------------------
1445 LE_SHARED le_result_t ifgen_le_sms_GetSmsCenterAddress
1446 (
1447  le_msg_SessionRef_t _ifgen_sessionRef,
1448  char* tel,
1449  ///< [OUT] SMS center address number string.
1450  size_t telSize
1451  ///< [IN]
1452 );
1453 
1454 //--------------------------------------------------------------------------------------------------
1455 /**
1456  * Set the SMS center address.
1457  *
1458  * SMS center address number is defined in ITU-T recommendations E.164/E.163.
1459  * E.164 numbers can have a maximum of fifteen digits and are usually written with a '+' prefix.
1460  *
1461  * @return
1462  * - LE_FAULT Service is not available..
1463  * - LE_OK Function succeeded.
1464  *
1465  * @note If the SMS center address number is too long (max LE_MDMDEFS_PHONE_NUM_MAX_LEN digits), it
1466  * is a fatal error, the function will not return.
1467  */
1468 //--------------------------------------------------------------------------------------------------
1469 LE_SHARED le_result_t ifgen_le_sms_SetSmsCenterAddress
1470 (
1471  le_msg_SessionRef_t _ifgen_sessionRef,
1472  const char* LE_NONNULL tel
1473  ///< [IN] SMS center address number string.
1474 );
1475 
1476 //--------------------------------------------------------------------------------------------------
1477 /**
1478  * Set the preferred SMS storage for incoming messages.
1479  * @return
1480  * - LE_FAULT Function failed.
1481  * - LE_OK Function succeeded.
1482  */
1483 //--------------------------------------------------------------------------------------------------
1484 LE_SHARED le_result_t ifgen_le_sms_SetPreferredStorage
1485 (
1486  le_msg_SessionRef_t _ifgen_sessionRef,
1487  le_sms_Storage_t prefStorage
1488  ///< [IN] storage parameter.
1489 );
1490 
1491 //--------------------------------------------------------------------------------------------------
1492 /**
1493  * Get the preferred SMS storage for incoming messages.
1494  * @return
1495  * - LE_FAULT Function failed.
1496  * - LE_OK Function succeeded.
1497  */
1498 //--------------------------------------------------------------------------------------------------
1499 LE_SHARED le_result_t ifgen_le_sms_GetPreferredStorage
1500 (
1501  le_msg_SessionRef_t _ifgen_sessionRef,
1502  le_sms_Storage_t* prefStoragePtr
1503  ///< [OUT] storage parameter.
1504 );
1505 
1506 //--------------------------------------------------------------------------------------------------
1507 /**
1508  * Activate Cell Broadcast message notification
1509  *
1510  * @return
1511  * - LE_FAULT Function failed.
1512  * - LE_OK Function succeeded.
1513  */
1514 //--------------------------------------------------------------------------------------------------
1515 LE_SHARED le_result_t ifgen_le_sms_ActivateCellBroadcast
1516 (
1517  le_msg_SessionRef_t _ifgen_sessionRef
1518 );
1519 
1520 //--------------------------------------------------------------------------------------------------
1521 /**
1522  * Deactivate Cell Broadcast message notification
1523  *
1524  * @return
1525  * - LE_FAULT Function failed.
1526  * - LE_OK Function succeeded.
1527  */
1528 //--------------------------------------------------------------------------------------------------
1529 LE_SHARED le_result_t ifgen_le_sms_DeactivateCellBroadcast
1530 (
1531  le_msg_SessionRef_t _ifgen_sessionRef
1532 );
1533 
1534 //--------------------------------------------------------------------------------------------------
1535 /**
1536  * Activate CDMA Cell Broadcast message notification
1537  *
1538  * @return
1539  * - LE_FAULT Function failed.
1540  * - LE_OK Function succeeded.
1541  */
1542 //--------------------------------------------------------------------------------------------------
1543 LE_SHARED le_result_t ifgen_le_sms_ActivateCdmaCellBroadcast
1544 (
1545  le_msg_SessionRef_t _ifgen_sessionRef
1546 );
1547 
1548 //--------------------------------------------------------------------------------------------------
1549 /**
1550  * Deactivate CDMA Cell Broadcast message notification
1551  *
1552  * @return
1553  * - LE_FAULT Function failed.
1554  * - LE_OK Function succeeded.
1555  */
1556 //--------------------------------------------------------------------------------------------------
1557 LE_SHARED le_result_t ifgen_le_sms_DeactivateCdmaCellBroadcast
1558 (
1559  le_msg_SessionRef_t _ifgen_sessionRef
1560 );
1561 
1562 //--------------------------------------------------------------------------------------------------
1563 /**
1564  * Add Cell Broadcast message Identifiers range.
1565  *
1566  * @return
1567  * - LE_FAULT Function failed.
1568  * - LE_OK Function succeeded.
1569  */
1570 //--------------------------------------------------------------------------------------------------
1571 LE_SHARED le_result_t ifgen_le_sms_AddCellBroadcastIds
1572 (
1573  le_msg_SessionRef_t _ifgen_sessionRef,
1574  uint16_t fromId,
1575  ///< [IN] Starting point of the range of cell broadcast message identifier.
1576  uint16_t toId
1577  ///< [IN] Ending point of the range of cell broadcast message identifier.
1578 );
1579 
1580 //--------------------------------------------------------------------------------------------------
1581 /**
1582  * Remove Cell Broadcast message Identifiers range.
1583  *
1584  * @return
1585  * - LE_FAULT Function failed.
1586  * - LE_OK Function succeeded.
1587  */
1588 //--------------------------------------------------------------------------------------------------
1589 LE_SHARED le_result_t ifgen_le_sms_RemoveCellBroadcastIds
1590 (
1591  le_msg_SessionRef_t _ifgen_sessionRef,
1592  uint16_t fromId,
1593  ///< [IN] Starting point of the range of cell broadcast message identifier.
1594  uint16_t toId
1595  ///< [IN] Ending point of the range of cell broadcast message identifier.
1596 );
1597 
1598 //--------------------------------------------------------------------------------------------------
1599 /**
1600  * Clear Cell Broadcast message Identifiers.
1601  *
1602  * @return
1603  * - LE_FAULT Function failed.
1604  * - LE_OK Function succeeded.
1605  */
1606 //--------------------------------------------------------------------------------------------------
1607 LE_SHARED le_result_t ifgen_le_sms_ClearCellBroadcastIds
1608 (
1609  le_msg_SessionRef_t _ifgen_sessionRef
1610 );
1611 
1612 //--------------------------------------------------------------------------------------------------
1613 /**
1614  * Add CDMA Cell Broadcast category services.
1615  *
1616  * @return
1617  * - LE_FAULT Function failed.
1618  * - LE_BAD_PARAMETER Parameter is invalid.
1619  * - LE_OK Function succeeded.
1620  */
1621 //--------------------------------------------------------------------------------------------------
1622 LE_SHARED le_result_t ifgen_le_sms_AddCdmaCellBroadcastServices
1623 (
1624  le_msg_SessionRef_t _ifgen_sessionRef,
1625  le_sms_CdmaServiceCat_t serviceCat,
1626  ///< [IN] Service category assignment. Reference to 3GPP2 C.R1001-D
1627  ///< v1.0 Section 9.3.1 Standard Service Category Assignments.
1628  le_sms_Languages_t language
1629  ///< [IN] Language Indicator. Reference to
1630  ///< 3GPP2 C.R1001-D v1.0 Section 9.2.1 Language Indicator
1631  ///< Value Assignments
1632 );
1633 
1634 //--------------------------------------------------------------------------------------------------
1635 /**
1636  * Remove CDMA Cell Broadcast category services.
1637  *
1638  * @return
1639  * - LE_FAULT Function failed.
1640  * - LE_BAD_PARAMETER Parameter is invalid.
1641  * - LE_OK Function succeeded.
1642  */
1643 //--------------------------------------------------------------------------------------------------
1644 LE_SHARED le_result_t ifgen_le_sms_RemoveCdmaCellBroadcastServices
1645 (
1646  le_msg_SessionRef_t _ifgen_sessionRef,
1647  le_sms_CdmaServiceCat_t serviceCat,
1648  ///< [IN] Service category assignment. Reference to 3GPP2 C.R1001-D
1649  ///< v1.0 Section 9.3.1 Standard Service Category Assignments.
1650  le_sms_Languages_t language
1651  ///< [IN] Language Indicator. Reference to
1652  ///< 3GPP2 C.R1001-D v1.0 Section 9.2.1 Language Indicator
1653  ///< Value Assignments
1654 );
1655 
1656 //--------------------------------------------------------------------------------------------------
1657 /**
1658  * Clear CDMA Cell Broadcast category services.
1659  *
1660  * @return
1661  * - LE_FAULT Function failed.
1662  * - LE_OK Function succeeded.
1663  */
1664 //--------------------------------------------------------------------------------------------------
1665 LE_SHARED le_result_t ifgen_le_sms_ClearCdmaCellBroadcastServices
1666 (
1667  le_msg_SessionRef_t _ifgen_sessionRef
1668 );
1669 
1670 //--------------------------------------------------------------------------------------------------
1671 /**
1672  * Get the number of messages successfully received or sent since last counter reset.
1673  *
1674  * @return
1675  * - LE_OK Function succeeded.
1676  * - LE_BAD_PARAMETER A parameter is invalid.
1677  *
1678  * @note If the caller is passing a bad pointer into this function, it is a fatal error, the
1679  * function will not return.
1680  */
1681 //--------------------------------------------------------------------------------------------------
1682 LE_SHARED le_result_t ifgen_le_sms_GetCount
1683 (
1684  le_msg_SessionRef_t _ifgen_sessionRef,
1685  le_sms_Type_t messageType,
1686  ///< [IN] Message type
1687  int32_t* messageCountPtr
1688  ///< [OUT] Number of messages
1689 );
1690 
1691 //--------------------------------------------------------------------------------------------------
1692 /**
1693  * Start to count the messages successfully received and sent.
1694  */
1695 //--------------------------------------------------------------------------------------------------
1696 LE_SHARED void ifgen_le_sms_StartCount
1697 (
1698  le_msg_SessionRef_t _ifgen_sessionRef
1699 );
1700 
1701 //--------------------------------------------------------------------------------------------------
1702 /**
1703  * Stop to count the messages successfully received and sent.
1704  */
1705 //--------------------------------------------------------------------------------------------------
1706 LE_SHARED void ifgen_le_sms_StopCount
1707 (
1708  le_msg_SessionRef_t _ifgen_sessionRef
1709 );
1710 
1711 //--------------------------------------------------------------------------------------------------
1712 /**
1713  * Reset the count of messages successfully received and sent.
1714  */
1715 //--------------------------------------------------------------------------------------------------
1716 LE_SHARED void ifgen_le_sms_ResetCount
1717 (
1718  le_msg_SessionRef_t _ifgen_sessionRef
1719 );
1720 
1721 //--------------------------------------------------------------------------------------------------
1722 /**
1723  * Enable SMS Status Report for outgoing messages.
1724  *
1725  * @return
1726  * - LE_OK Function succeeded.
1727  * - LE_FAULT Function failed.
1728  */
1729 //--------------------------------------------------------------------------------------------------
1730 LE_SHARED le_result_t ifgen_le_sms_EnableStatusReport
1731 (
1732  le_msg_SessionRef_t _ifgen_sessionRef
1733 );
1734 
1735 //--------------------------------------------------------------------------------------------------
1736 /**
1737  * Disable SMS Status Report for outgoing messages.
1738  *
1739  * @return
1740  * - LE_OK Function succeeded.
1741  * - LE_FAULT Function failed.
1742  */
1743 //--------------------------------------------------------------------------------------------------
1744 LE_SHARED le_result_t ifgen_le_sms_DisableStatusReport
1745 (
1746  le_msg_SessionRef_t _ifgen_sessionRef
1747 );
1748 
1749 //--------------------------------------------------------------------------------------------------
1750 /**
1751  * Get SMS Status Report activation state.
1752  *
1753  * @return
1754  * - LE_OK Function succeeded.
1755  * - LE_BAD_PARAMETER Parameter is invalid.
1756  * - LE_FAULT Function failed.
1757  */
1758 //--------------------------------------------------------------------------------------------------
1759 LE_SHARED le_result_t ifgen_le_sms_IsStatusReportEnabled
1760 (
1761  le_msg_SessionRef_t _ifgen_sessionRef,
1762  bool* enabledPtr
1763  ///< [OUT] True when SMS Status Report is enabled, false otherwise.
1764 );
1765 
1766 //--------------------------------------------------------------------------------------------------
1767 /**
1768  * Get TP-Message-Reference of a message. Message type should be either a SMS Status Report or an
1769  * outgoing SMS.
1770  * TP-Message-Reference is defined in 3GPP TS 23.040 section 9.2.3.6.
1771  *
1772  * @return
1773  * - LE_OK Function succeeded.
1774  * - LE_BAD_PARAMETER Parameter is invalid.
1775  * - LE_FAULT Function failed.
1776  * - LE_UNAVAILABLE Outgoing SMS message is not sent.
1777  */
1778 //--------------------------------------------------------------------------------------------------
1779 LE_SHARED le_result_t ifgen_le_sms_GetTpMr
1780 (
1781  le_msg_SessionRef_t _ifgen_sessionRef,
1782  le_sms_MsgRef_t msgRef,
1783  ///< [IN] Reference to the message object.
1784  uint8_t* tpMrPtr
1785  ///< [OUT] 3GPP TS 23.040 TP-Message-Reference.
1786 );
1787 
1788 //--------------------------------------------------------------------------------------------------
1789 /**
1790  * Get TP-Recipient-Address of SMS Status Report.
1791  * TP-Recipient-Address is defined in 3GPP TS 23.040 section 9.2.3.14.
1792  * TP-Recipient-Address Type-of-Address is defined in 3GPP TS 24.011 section 8.2.5.2.
1793  *
1794  * @return
1795  * - LE_OK Function succeeded.
1796  * - LE_BAD_PARAMETER A parameter is invalid.
1797  * - LE_OVERFLOW The Recipient Address length exceeds the length of the provided buffer.
1798  * - LE_FAULT Function failed.
1799  */
1800 //--------------------------------------------------------------------------------------------------
1801 LE_SHARED le_result_t ifgen_le_sms_GetTpRa
1802 (
1803  le_msg_SessionRef_t _ifgen_sessionRef,
1804  le_sms_MsgRef_t msgRef,
1805  ///< [IN] Reference to the message object.
1806  uint8_t* toraPtr,
1807  ///< [OUT] 3GPP TS 24.011 TP-Recipient-Address
1808  ///< Type-of-Address.
1809  char* ra,
1810  ///< [OUT] 3GPP TS 23.040 TP-Recipient-Address.
1811  size_t raSize
1812  ///< [IN]
1813 );
1814 
1815 //--------------------------------------------------------------------------------------------------
1816 /**
1817  * Get TP-Service-Centre-Time-Stamp of SMS Status Report.
1818  * TP-Service-Centre-Time-Stamp is defined in 3GPP TS 23.040 section 9.2.3.11.
1819  *
1820  * @return
1821  * - LE_OK Function succeeded.
1822  * - LE_BAD_PARAMETER A parameter is invalid.
1823  * - LE_OVERFLOW The SC Timestamp length exceeds the length of the provided buffer.
1824  * - LE_FAULT Function failed.
1825  */
1826 //--------------------------------------------------------------------------------------------------
1827 LE_SHARED le_result_t ifgen_le_sms_GetTpScTs
1828 (
1829  le_msg_SessionRef_t _ifgen_sessionRef,
1830  le_sms_MsgRef_t msgRef,
1831  ///< [IN] Reference to the message object.
1832  char* scts,
1833  ///< [OUT] 3GPP TS 23.040 TP-Service-Centre-Time-Stamp.
1834  size_t sctsSize
1835  ///< [IN]
1836 );
1837 
1838 //--------------------------------------------------------------------------------------------------
1839 /**
1840  * Get TP-Discharge-Time of SMS Status Report.
1841  * TP-Discharge-Time is defined in 3GPP TS 23.040 section 9.2.3.13.
1842  *
1843  * @return
1844  * - LE_OK Function succeeded.
1845  * - LE_BAD_PARAMETER A parameter is invalid.
1846  * - LE_OVERFLOW The Discharge Time length exceeds the length of the provided buffer.
1847  * - LE_FAULT Function failed.
1848  */
1849 //--------------------------------------------------------------------------------------------------
1850 LE_SHARED le_result_t ifgen_le_sms_GetTpDt
1851 (
1852  le_msg_SessionRef_t _ifgen_sessionRef,
1853  le_sms_MsgRef_t msgRef,
1854  ///< [IN] Reference to the message object.
1855  char* dt,
1856  ///< [OUT] 3GPP TS 23.040 TP-Discharge-Time.
1857  size_t dtSize
1858  ///< [IN]
1859 );
1860 
1861 //--------------------------------------------------------------------------------------------------
1862 /**
1863  * Get TP-Status of SMS Status Report.
1864  * TP-Status is defined in 3GPP TS 23.040 section 9.2.3.15.
1865  *
1866  * @return
1867  * - LE_OK Function succeeded.
1868  * - LE_BAD_PARAMETER A parameter is invalid.
1869  * - LE_FAULT Function failed.
1870  */
1871 //--------------------------------------------------------------------------------------------------
1872 LE_SHARED le_result_t ifgen_le_sms_GetTpSt
1873 (
1874  le_msg_SessionRef_t _ifgen_sessionRef,
1875  le_sms_MsgRef_t msgRef,
1876  ///< [IN] Reference to the message object.
1877  uint8_t* stPtr
1878  ///< [OUT] 3GPP TS 23.040 TP-Status.
1879 );
1880 /** @} **/
1881 #endif // LE_SMS_COMMON_H_INCLUDE_GUARD
Area Traffic Reports.
Definition: le_sms_common.h:253
Error in MS.
Definition: le_sms_common.h:498
Entertainment News National.
Definition: le_sms_common.h:247
Message present in the message storage has been read.
Definition: le_sms_common.h:151
Message saved in the message storage has been sent.
Definition: le_sms_common.h:155
Business News International.
Definition: le_sms_common.h:233
Undefined storage.
Definition: le_sms_common.h:294
TPDU not supported.
Definition: le_sms_common.h:476
Employment Opportunities.
Definition: le_sms_common.h:267
A terminal problem other than described above.
Definition: le_sms_common.h:346
Message has been in the sending pool.
Definition: le_sms_common.h:161
#define LE_SHARED
Definition: le_basics.h:287
Message sending has Failed due to timeout.
Definition: le_sms_common.h:167
Unspecified TP-Command error.
Definition: le_sms_common.h:474
General News Regional.
Definition: le_sms_common.h:221
SC busy.
Definition: le_sms_common.h:478
Definition: le_sms_common.h:312
Definition: le_sms_common.h:371
le_result_t
Definition: le_basics.h:46
Business News National.
Definition: le_sms_common.h:231
Interworking, unspecified.
Definition: le_sms_common.h:453
Definition: le_sms_common.h:327
(U)SIM data download error
Definition: le_sms_common.h:504
Definition: le_sms_common.h:357
Card Application Toolkit Protocol Teleservice.
Definition: le_sms_common.h:275
Undefined reason.
Definition: le_sms_common.h:391
Sim SMS storage.
Definition: le_sms_common.h:292
Multicategory.
Definition: le_sms_common.h:273
Medical/Health/Hospitals.
Definition: le_sms_common.h:269
Protocol error, unspecified.
Definition: le_sms_common.h:451
le_sms_Status_t
Definition: le_sms_common.h:149
(U)SIM SMS storage full
Definition: le_sms_common.h:494
Resources facility not subscribed.
Definition: le_sms_common.h:432
Definition: le_sms_common.h:332
Definition: le_sms_common.h:343
Unspecified TP-PID error.
Definition: le_sms_common.h:461
SMS mobile originated message.
Definition: le_sms_common.h:134
Korean language.
Definition: le_sms_common.h:192
No SMS storage capability in (U)SIM.
Definition: le_sms_common.h:496
struct le_sms_RxMessageHandler * le_sms_RxMessageHandlerRef_t
Definition: le_sms_common.h:537
Definition: le_sms_common.h:340
Command unsupported.
Definition: le_sms_common.h:472
Definition: le_sms_common.h:348
Definition: le_sms_common.h:335
Unspecified error cause.
Definition: le_sms_common.h:506
Command cannot be actioned.
Definition: le_sms_common.h:470
Definition: le_sms_common.h:351
SM Rejected-Duplicate SM.
Definition: le_sms_common.h:488
Sementically incorect message.
Definition: le_sms_common.h:439
Call barred.
Definition: le_sms_common.h:408
A network problem other than identified above.
Definition: le_sms_common.h:322
TP-VPF not supported.
Definition: le_sms_common.h:490
Definition: le_sms_common.h:365
struct le_sms_Msg * le_sms_MsgRef_t
Definition: le_sms_common.h:521
Definition: le_sms_common.h:463
Sports News International.
Definition: le_sms_common.h:241
Message present in the message storage has not been read.
Definition: le_sms_common.h:153
Resources facility not implemented.
Definition: le_sms_common.h:434
Platform specific code.
Definition: le_sms_common.h:389
Reserved.
Definition: le_sms_common.h:410
Definition: le_sms_common.h:324
Definition: le_sms_common.h:374
Destination SME barred.
Definition: le_sms_common.h:486
English language.
Definition: le_sms_common.h:184
Short Message Type 0 not supported.
Definition: le_sms_common.h:457
Entertainment News Regional.
Definition: le_sms_common.h:245
Sports News Local.
Definition: le_sms_common.h:235
Definition: le_sms_common.h:368
Unknown message status.
Definition: le_sms_common.h:169
Resources unavailable, unspecified.
Definition: le_sms_common.h:430
Undefined reason.
Definition: le_sms_common.h:510
Network out of order.
Definition: le_sms_common.h:424
le_sms_ErrorCode3GPP2_t
Definition: le_sms_common.h:305
Unassigned (unallocated) number.
Definition: le_sms_common.h:404
Non volatile memory storage.
Definition: le_sms_common.h:290
Memory capacity exceeded.
Definition: le_sms_common.h:500
Message has been sent.
Definition: le_sms_common.h:159
Memory capacity exceeded.
Definition: le_sms_common.h:414
Destination out of order.
Definition: le_sms_common.h:416
Operator determined barring.
Definition: le_sms_common.h:406
Invalid mandatory information.
Definition: le_sms_common.h:441
SMS mobile terminated message.
Definition: le_sms_common.h:132
Definition: le_sms_common.h:383
Japanese language.
Definition: le_sms_common.h:190
SMS Cell Broadcast message.
Definition: le_sms_common.h:136
Text message format.
Definition: le_sms_common.h:113
SC system failure.
Definition: le_sms_common.h:482
Business News Regional.
Definition: le_sms_common.h:229
PDU message format.
Definition: le_sms_common.h:111
TP-VP not supporte.
Definition: le_sms_common.h:492
Telematic interworking not supported.
Definition: le_sms_common.h:455
Technology News.
Definition: le_sms_common.h:271
le_sms_Storage_t
Definition: le_sms_common.h:288
Platform specific code.
Definition: le_sms_common.h:508
Unknown subscriber.
Definition: le_sms_common.h:422
struct le_msg_Session * le_msg_SessionRef_t
Definition: le_messaging.h:860
Unknown message format.
Definition: le_sms_common.h:119
The originating MIN is not recognized.
Definition: le_sms_common.h:360
Short message transfer rejected.
Definition: le_sms_common.h:412
Retail Directory.
Definition: le_sms_common.h:261
Unknow or Unspecified language.
Definition: le_sms_common.h:182
UCS2 message format.
Definition: le_sms_common.h:117
Delivery is not currently possible.
Definition: le_sms_common.h:338
Other general problems.
Definition: le_sms_common.h:387
le_sms_Type_t
Definition: le_sms_common.h:130
Definition: le_sms_common.h:380
The SMS Destination Address is invalid.
Definition: le_sms_common.h:310
Chinese language.
Definition: le_sms_common.h:194
Local weather.
Definition: le_sms_common.h:251
SMS Status Report.
Definition: le_sms_common.h:138
Cannot replace short message.
Definition: le_sms_common.h:459
Lodgings.
Definition: le_sms_common.h:259
Unknown or Unspecified.
Definition: le_sms_common.h:211
Entertainment News Local.
Definition: le_sms_common.h:243
Definition: le_sms_common.h:377
Definition: le_sms_common.h:307
void(* le_sms_RxMessageHandlerFunc_t)(le_sms_MsgRef_t msgRef, void *contextPtr)
Definition: le_sms_common.h:570
Invalid SME address.
Definition: le_sms_common.h:484
Congestion.
Definition: le_sms_common.h:428
struct le_sms_MsgList * le_sms_MsgListRef_t
Definition: le_sms_common.h:529
Message has not been sent.
Definition: le_sms_common.h:163
Message class not supported.
Definition: le_sms_common.h:466
Message sending has Failed.
Definition: le_sms_common.h:165
le_sms_ErrorCode_t
Definition: le_sms_common.h:402
Administrative.
Definition: le_sms_common.h:215
Maintenance.
Definition: le_sms_common.h:217
Message type nonexistent or not implemented.
Definition: le_sms_common.h:443
Definition: le_sms_common.h:354
void(* le_sms_FullStorageHandlerFunc_t)(le_sms_Storage_t storage, void *contextPtr)
Definition: le_sms_common.h:584
Advertisements.
Definition: le_sms_common.h:263
Spanish language.
Definition: le_sms_common.h:188
Sports News National.
Definition: le_sms_common.h:239
No SC subscription.
Definition: le_sms_common.h:480
le_sms_Format_t
Definition: le_sms_common.h:109
Entertainment News International.
Definition: le_sms_common.h:249
Emergency Broadcast.
Definition: le_sms_common.h:213
Temporary failure.
Definition: le_sms_common.h:426
Hebrew language.
Definition: le_sms_common.h:196
Unidentified subscriber.
Definition: le_sms_common.h:418
Facility rejected.
Definition: le_sms_common.h:420
Sports News Regional.
Definition: le_sms_common.h:237
Stock Quotes.
Definition: le_sms_common.h:265
Binary message format.
Definition: le_sms_common.h:115
General News National.
Definition: le_sms_common.h:223
(U)SIM Application Toolkit busy
Definition: le_sms_common.h:502
Unspecified TP-DCS error.
Definition: le_sms_common.h:468
Business News Local.
Definition: le_sms_common.h:227
Definition: le_sms_common.h:448
Message saved in the message storage has not been sent.
Definition: le_sms_common.h:157
void(* le_sms_CallbackResultFunc_t)(le_sms_MsgRef_t msgRef, le_sms_Status_t status, void *contextPtr)
Definition: le_sms_common.h:554
Restaurants.
Definition: le_sms_common.h:257
Local Airplane Flight Schedules.
Definition: le_sms_common.h:255
French language.
Definition: le_sms_common.h:186
General News International.
Definition: le_sms_common.h:225
Definition: le_sms_common.h:318
Definition: le_sms_common.h:315
struct le_sms_FullStorageEventHandler * le_sms_FullStorageEventHandlerRef_t
Definition: le_sms_common.h:545
General News Local.
Definition: le_sms_common.h:219
le_sms_CdmaServiceCat_t
Definition: le_sms_common.h:209
le_sms_Languages_t
Definition: le_sms_common.h:180
Definition: le_sms_common.h:362