freesmartphone.org GSM Call Interface
Description
The Call interface is used to initiate, accept, release, and otherwise deal with voice calls. It also allows you to send DTMF tones.
Namespace
org.freesmartphone.GSM.Call
Methods
- Emergency
- Activate
- ActivateConference
- Release
- HoldActive
- Join
- Transfer
- Deflect
- ReleaseHeld
- ReleaseAll
- Initiate
- ListCalls
- SendDtmf
Signals
Properties
None
Errors
None
Methods
Emergency ( s )
Description: Initiate an emergency call.
Implementation Note
This maps to ATD(number);, see v.250.
Parameters:*
s: number The emergency number to dial. National and world-wide restrictions apply.
Activate ( i )
Description: Activate a call as single active call. All previously active calls are put on hold. No difference is made whether this is an incoming call or a call that has been put on hold.
Implementation Note
This can map to ATA, see v.250. It might also map to GSM 07.07 +CHLD=…, see 3GPP TS 07.07 Chapter 7.12.
Parameters:*
i: id
ActivateConference ( i )
Description: Activate a call in addition to all previously active calls. No difference is made whether this is an incoming call or a call that has been put on hold.
Implementation Note
This maps to GSM 07.07 +CHLD=…, see 3GPP TS 07.07 Chapter 7.12.
Parameters:*
i: id
Release ( i )
Description: Release a call.
Implementation Note
This can map to ATH, see v.250. It might also map to GSM 07.07 +CHLD=…, see 3GPP TS 07.07 Chapter 7.12. Some implementations might map it to GSM 07.07 +CHUP=, see 3GPP TS 07.07 Chapter 6.5.
Parameters:*
i: id
HoldActive ( )
Description: Hold the active call.
Implementation Note
This maps to GSM 07.07 +CHLD=2, see 3GPP TS 07.07 Chapter 7.12.
Join ( )
Description: Join all active and held calls and release yourself from the conversation.
Implementation Note
This maps to GSM 07.07 +CHLD=4, see 3GPP TS 07.07 Chapter 7.12.
Transfer ( )
Description: Join the currently active and held calls together and disconnect both calls.
Implementation Note
This usually maps to the +CHLD AT command, see 3GPP TS 27.07 Chapter 7.13.
Deflect ( s )
Description: Deflect an incoming or active call to another number.
Implementation Note
This maps to GSM 07.07 +CTFR=…, see 3GPP TS 27.07 Chapter 7.14.
Parameters:*
s: number The number to transfer the call to.
ReleaseHeld ( )
Description: Release all held calls.
Implementation Note
This maps to GSM 07.07 +CHLD=, see 3GPP TS 07.07 Chapter 7.12.
ReleaseAll ( )
Description: Release all calls, no matter whether active or put on hold.
Implementation Note
This maps to ATH, see v.250.
Initiate ( ss ) → i
Description: Initiate an outgoing call.
Implementation Note
This maps to ATD(number);, see v.250.
Parameters:*
s: number The number to call.
s: type The type of call to made. Valid values are:
- “voice” - a GSM voice call,
- “data” - a GSM data call,
- “fax” - a FAX call.
Returns:
i: id The reference id for this call. It will get assigned by the system.
ListCalls ( ) → a(isa{sv})
Description: Retrieve the status for all calls in the system.
Returns:
a(isa{sv}): call_details The call status. This is an array containing a call status record for every single call. See CallStatus signal for a description of the format.
SendDtmf ( s )
Description: Send one or more Dual Tone Multiple Frequency (DTMF) signals during an active call.
Implementation Note
This maps to the TIA IS 101 command +VTS=(value), see 3GPP TS 07.07 Chapter C.2.11. Note: DTMF signals are always sent to all active calls, this is a limitation of the underlying protocols.
Parameters:*
s: tones The tones to send. Allowed values are: (0-9,#,*,A-D)
Signals
CallStatus ( isa{sv} )
Description: Sent whenever there is any status or property change on a call in the system, no matter whether this is an incoming, active, held, or released call.
Parameters:
i: id The index of the call that changed its status or properties.
s: status The new status of the call. Expected values are:
- “incoming” = The call is incoming (but not yet accepted),
- “outgoing” = The call is outgoing (but not yet established),
- “active” = The call is the active call (you can talk),
- “held” = The call is being held,
- “release” = The call has been released.
a{sv}: properties An array of property values. Note that some properties are optional. Mandatory tuples are:
- ( “direction”, string ) = “incoming” or “outgoing”,
- ( “peer”, string ) = The number of the peer (on incoming calls only if we received a CLIP).
- ( “reason”, string ) = The reason for the status change (on outgoing calls e.g. ‘BUSY’ or ‘NO CARRIER’),
- ( “auxstatus”, string ) = An auxillary connection status (if your modem supports that),
- ( “line”, string ) = The GSM line (0 or 1) this call is taking place (on modems that support multiple lines).