Is there any way I can dynamically generate uplink DTMF tone (ie the receiver hears it)?
When I looked at the android source code I saw a function called startDTMF() which is exactly what I need, but I couldn't find any API that allows me to access that function...
I then thought of using ToneGenerator and tried to inject the sound to the mic stream, and again I couldn't find a way to achieve this...
Any help is appreciated.
Perhaps the android.media.ToneGenerator class in the SDK can help?
tel:1234,123
this can help.
, generates a 4 sec delay so you may use this at places sometimes...
but still we need to get some thing from sdk lets hope Android guys find something up!
Related
So I am trying to create an app that can answer and reject incoming calls.
I've trying every single solution possible than I could find like using the audio manager for lower version then for higher versions use the media button and for Oreo+ use the answerRingingCall method. But none works. ITelephony is Dead and does not exist. And I can't manage to get it working even though I know it's possible since I have seen apps that can do it.
Can someone please help me find a solution?
Thanks in advance.
I am creating an android app in which I am trying to modify the default dialer keyboard tones (1,2,3....) (NOT the incoming caller tunes etc)
This is my first approach for such kind of android app.
Can anyone please guide me how to achieve this?
I read it somewhere that "ToneGenerator" class can be used to achieve what I've in mind but not sure how to use this class.
A little help here will be highly appreciated.
Thnx..
Use below code to generate tone.
ToneGenerator generator = new ToneGenerator(AudioManager.STREAM_MUSIC,100);
generator.startTone(ToneGenerator.TONE_DTMF_0);
Thread.sleep(500);
generator.stopTone();
generator.release();
Change TONE_DTMF_0 according to your needs
I want to create an audio recorder I have tried the code I get from http://developer.android.com/guide/topics/media/audio-capture.html and it works fine; it records and it plays back what I have said. But right now I want to create an audio recorder with a UI like in recognizerIntent which Google has provided so that you can see or monitor that your voice has been recorded(sorry I can't find a right term but I'm hoping you can understand what I am trying to say). Do you know any tutorial or links that can help me?thanks for you help!
I think you mean that you want some feedback that your voice is being picked up? If so, perhaps this project, Audalyzer might be a good place to start looking?
Libraries within the package offer you a dB reading, a one and two-dimensional wave form, and an FFT plot.
(source: googlecode.com)
There is a simpler WaveformControl you may find easier to understand and modify for your needs.
How do I play audio file to a call for android?
I want to make some kind of machine answering program. is it possible?
You don't appear to be able to intercept incoming calls.
ETA: er, apparently that isn't true? See:
How to programmatically answer a call
I want to record call from android phone.
I am using android.media.MediaRecorder pckg.
Also used following code:
mrec.setAudioSource(MediaRecorder.AudioSource.VOICE_CALL);
mrec.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);
mrec.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);
But I didn't succeed in recording an incoming call.
Can anyone recommend a tested code snippet?
Also,
Is this true?
http://groups.google.com/group/android-developers/browse_thread/thread/c2bc85eb60ae2aa5?pli=1
http://code.google.com/p/android/issues/detail?id=2117#c226
Standard distributions of Android does not support it till now.
You can vote up these if you want:
http://code.google.com/p/android/issues/detail?id=4075
http://code.google.com/p/android/issues/detail?id=2117
It's not a software problem and I don't think the baseband firmware vendors will fix this. Most likely because it's illegal in most western countries to record calls without consent of the other person.