Sending DTMF tones over the uplink in-call

前端 未结 3 1175
清歌不尽
清歌不尽 2020-12-04 20:25

I\'m working on a project that requires my app to be able to send DTMF tones on the voice\'s uplink frequency during an active call.

My 2 conditions are:

    <
相关标签:
3条回答
  • 2020-12-04 20:29

    You've taken an interesting approach, and I commend your efforts. Unfortunately, there are some reserved internal privileges (evidently, such as SPN_STRINGS_UPDATED) that you aren't allowed to use as an app developer, which more or less breaks this approach. You could try removing the area of code causing this, but I'm fairly certain you will run into a blocking problem.

    Hence, I'm afraid this is not possible at the moment. There's an open feature request on Android for sending DTMF tones over an existing phone call, but it has been dormant there for almost two years.

    I understand that this doesn't resolve your problem, but take note that you can send DTMF tones directly after dialing a number:

    Intent i = new Intent("android.intent.action.CALL",
                          Uri.parse("tel://" + number + "," + dtmfTones));
    
    0 讨论(0)
  • 2020-12-04 20:29

    You can't send DTMF tones during an active call, but you can send them when you "program" them when you initiate the call. see the following post: https://stackoverflow.com/a/12986066/475472

    0 讨论(0)
  • 2020-12-04 20:54

    Simply put, you won't be able to do it without customizing at least the Phone app, which has to run as a system user in order to access the modem. In order to do this, you have to root your phone.

    To meet your requirements the only possible solution is to enhance the android platform. We did just that, and already sent in our patches to the AOSP project:

    https://android-review.googlesource.com/32820

    https://android-review.googlesource.com/32821

    We are currently waiting for the Google developers to review and accept our contribution. If you are interested, please let Google know on the various AOSP lists (android-contrib, android-platform). It will hopefully expedite the review.

    Best Regards, Gergely

    0 讨论(0)
提交回复
热议问题