Hang up from SoftKey

Version 1
    This document was generated from CDN thread

    Created by: Steve Schultz on 02-09-2009 06:49:08 PM
    Is it possible to hang up a call by pressing a softkey?

    Subject: RE: Hang up from SoftKey
    Replied by: David Staudt on 02-09-2009 08:12:13 PM
    You can use HTTP POST to send a CiscoIPPhoneExecute object to the phone with a command to press a particular softkey, but there are several caveats with this:
     
    - You can press softkeys only by position, i.e. 'Key:Soft1'
    - The actual position that the 'Hangup' option is at is configurable by the user (and not discoverable by an app)
    - The Hangup softkey can appear/disappear depending on transient call states, the app may have difficulty knowing whether 'Soft Key 1' is appropriate to push at any given instant.
     
    For positive phone control like this, you will want to look at the CTI APIs: TAPI and JTAPI.  These APIs allow the app to know the full/exact call state of the phone and positively execute call-control commands.

    Subject: RE: Hang up from SoftKey
    Replied by: Steve Schultz on 03-09-2009 12:42:56 PM
    Thanks David.
    I'm familiar with using the Execute command to invoke softkeys, but how can I set a softkey to hang up a call?
     
     
     
     

    Subject: RE: Hang up from SoftKey
    Replied by: David Staudt on 03-09-2009 02:02:33 PM
    All you can do is send a command like 'push softkey #2'.  If you are in a call, and you happen to know softkey #2 is displaying 'hangup' this works ok.  If, however, another call comes in and softkey #2 switches to 'answer', then pushing softkey #2 is not what the user wanted.
     
    For an application, there is no way (except by using CTI APIs) for it to know the exact current state of the phone, and to execute call control commands with guaranteed results.

    Subject: RE: Hang up from SoftKey
    Replied by: Steve Schultz on 04-09-2009 01:45:48 PM
    David,
     
    Thanks again.
    I have a working solution with the softkeys.
    I understand that I won't know the call state, but we aren't using the phone as most would.
    The phone won't make or take calls. Instead we're using it to control radios and we're always pretty much aware of the call state.
     
    Thanks, you've been a great help.
    Steve