All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
le_mcc_call_interface.h File Reference
#include "legato.h"
#include "le_audio_interface.h"

Go to the source code of this file.

Typedefs

typedef struct le_mcc_call_Obj * le_mcc_call_ObjRef_t
 

Enumerations

enum  le_mcc_call_Event_t {
  LE_MCC_CALL_EVENT_INCOMING, LE_MCC_CALL_EVENT_ALERTING, LE_MCC_CALL_EVENT_EARLY_MEDIA, LE_MCC_CALL_EVENT_CONNECTED,
  LE_MCC_CALL_EVENT_TERMINATED, LE_MCC_CALL_EVENT_ON_HOLD, LE_MCC_CALL_EVENT_TRANSFERED
}
 
enum  le_mcc_call_TerminationReason_t {
  LE_MCC_CALL_TERM_NETWORK_FAIL, LE_MCC_CALL_TERM_BAD_ADDRESS, LE_MCC_CALL_TERM_BUSY, LE_MCC_CALL_TERM_LOCAL_ENDED,
  LE_MCC_CALL_TERM_REMOTE_ENDED, LE_MCC_CALL_TERM_NOT_DEFINED
}
 

Functions

void le_mcc_call_StartClient (const char *serviceInstanceName)
 
void le_mcc_call_StopClient (void)
 
void le_mcc_call_Delete (le_mcc_call_ObjRef_t callRef)
 
le_result_t le_mcc_call_Start (le_mcc_call_ObjRef_t callRef)
 
bool le_mcc_call_IsConnected (le_mcc_call_ObjRef_t callRef)
 
le_result_t le_mcc_call_GetRemoteTel (le_mcc_call_ObjRef_t callRef, char *telPtr, size_t telPtrNumElements)
 
le_mcc_call_TerminationReason_t le_mcc_call_GetTerminationReason (le_mcc_call_ObjRef_t callRef)
 
le_audio_StreamRef_t le_mcc_call_GetTxAudioStream (le_mcc_call_ObjRef_t callRef)
 
le_audio_StreamRef_t le_mcc_call_GetRxAudioStream (le_mcc_call_ObjRef_t callRef)
 
le_result_t le_mcc_call_Answer (le_mcc_call_ObjRef_t callRef)
 
le_result_t le_mcc_call_HangUp (le_mcc_call_ObjRef_t callRef)
 
le_result_t le_mcc_call_HangUpAll (void)
 

Detailed Description

Legato Modem Call Control include file.

Copyright (C) Sierra Wireless, Inc. 2014. Use of this work is subject to license.

Typedef Documentation

typedef struct le_mcc_call_Obj* le_mcc_call_ObjRef_t

Reference type for managing active calls.

Enumeration Type Documentation

Enumeration of the possible events that may be reported to a call event handler.

Enumerator
LE_MCC_CALL_EVENT_INCOMING 

Incoming call attempt (new call).

LE_MCC_CALL_EVENT_ALERTING 

Far end is now alerting its user (outgoing call).

LE_MCC_CALL_EVENT_EARLY_MEDIA 

Callee has not accepted the call, but a media stream is available.

LE_MCC_CALL_EVENT_CONNECTED 

Call has been established, and is media is active.

LE_MCC_CALL_EVENT_TERMINATED 

Call has terminated.

LE_MCC_CALL_EVENT_ON_HOLD 

Remote party has put the call on hold.

LE_MCC_CALL_EVENT_TRANSFERED 

Remote party transferred or forwarded the call.

Enumeration of the possible reasons for call termination.

Enumerator
LE_MCC_CALL_TERM_NETWORK_FAIL 

Network could not complete the call.

LE_MCC_CALL_TERM_BAD_ADDRESS 

Remote address could not be resolved.

LE_MCC_CALL_TERM_BUSY 

Callee is currently busy and cannot take the call.

LE_MCC_CALL_TERM_LOCAL_ENDED 

Local party ended the call.

LE_MCC_CALL_TERM_REMOTE_ENDED 

Remote party ended the call.

LE_MCC_CALL_TERM_NOT_DEFINED 

Undefined reason.

Function Documentation

le_result_t le_mcc_call_Answer ( le_mcc_call_ObjRef_t  callRef)

Answers incoming call.

Returns
LE_TIMEOUT No response was received from the Modem.
LE_OK The function succeeded.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference.
void le_mcc_call_Delete ( le_mcc_call_ObjRef_t  callRef)

Call to free up a call reference.

Note
This frees up the reference, but remains active if other holders reference it.
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call object to free.
le_result_t le_mcc_call_GetRemoteTel ( le_mcc_call_ObjRef_t  callRef,
char *  telPtr,
size_t  telPtrNumElements 
)

Display the remote party telephone number associated with the call.

Output parameter is updated with the telephone number. If the Telephone number string length exceeds the value of 'len' parameter, the LE_OVERFLOW error code is returned and 'telPtr' is used until 'len-1' characters and a null-character is implicitly appended at the end of 'telPtr'.

Returns
LE_OVERFLOW The Telephone number length exceed the maximum length.
LE_OK The function succeeded.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference to read from.
[out]telPtrThe telephone number string.
[in]telPtrNumElements
le_audio_StreamRef_t le_mcc_call_GetRxAudioStream ( le_mcc_call_ObjRef_t  callRef)

Called to get the received audio stream. All audio received from the other end of the call is received on this stream.

Returns
Received audio stream reference.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference to read from.
le_mcc_call_TerminationReason_t le_mcc_call_GetTerminationReason ( le_mcc_call_ObjRef_t  callRef)

Called to get the termination reason.

Returns
The termination reason.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference to read from.
le_audio_StreamRef_t le_mcc_call_GetTxAudioStream ( le_mcc_call_ObjRef_t  callRef)

Called to get the transmitted audio stream. All audio generated on this end of the call is sent on this stream.

Returns
Transmitted audio stream reference.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference to read from.
le_result_t le_mcc_call_HangUp ( le_mcc_call_ObjRef_t  callRef)

Disconnect, or hang up, the specifed call. Any active call handlers will be notified.

Returns
LE_TIMEOUT No response was received from the Modem.
LE_OK Function succeeded.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call to end.
le_result_t le_mcc_call_HangUpAll ( void  )

This function will disconnect, or hang up all the ongoing calls. Any active call handlers will be notified.

Returns
LE_TIMEOUT No response was received from the Modem.
LE_NOT_POSSIBLE The function failed.
LE_OK The function succeeded.
bool le_mcc_call_IsConnected ( le_mcc_call_ObjRef_t  callRef)

Allow the caller to know if the given call is actually connected or not.

Returns
TRUE if the call is connected, FALSE otherwise.
Note
If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefThe call reference to read.
le_result_t le_mcc_call_Start ( le_mcc_call_ObjRef_t  callRef)

Start a call attempt.

Asynchronous due to possible time to connect.

As the call attempt proceeds, the profile's registered call event handler receives events.

Returns
LE_OK Function succeed.
  • Note
    As this is an asynchronous call, a successful only confirms a call has been started. Don't assume a call has been successful yet.
    If the caller is passing a bad pointer into this function, it is a fatal error, the function will not return.
Parameters
[in]callRefReference to the call object.
void le_mcc_call_StartClient ( const char *  serviceInstanceName)

Start the service for the client main thread

Parameters
[in]serviceInstanceName
void le_mcc_call_StopClient ( void  )

Stop the service for the current client thread