I want to receive DTFM code in Android which is sent by the caller. Is it possible?
This is not possible through the phone, as you have no access to the underlying telephony hardware. The only way that telephony hardware is accessed in Android is through the Radio Interface Layer (RIL). The frequent trick to play, is to force the user to play their call through the speaker, for which you see some apps exist that will do this.
Related
Let's assume I have two androide devices. An AndroidTV and a smartphone.
On both devices I have installed my app, that is capable of video playback streamed from a server.
I want, similar to chromecast, to delegate the playback from my smartphone to the AndroidTV via my app.
How would I do that?
My starting point is this: Media Router here I go for Remote Playback.
If I understand this correctly,
the app on my AndroidTV device would be a MediaRoute Provider,
the app on my phone would use a MediaRoute to launch a CATEGORY_REMOTE_PLAYBACK-intent on the MediaRoute Provider?
This also means, that the callbacks handle all communication, so that I could differentiate via callbacks between passing the url and let the receiver app fetch title and images themself or let it be passed from the sender app?
Or am I on the wrong track?
the app on my AndroidTV device would be a MediaRoute Provider
No. MediaRouteProvider goes on the device that is the user's controller, which in this case would be the phone.
the app on my phone would use a MediaRoute to launch a CATEGORY_REMOTE_PLAYBACK-intent on the MediaRoute Provider?
You can do that. The advantage of using MediaRouteProvider is that any app on that phone that supports RemotePlaybackClient can now support your setup. If you only want your app to do this, you could skip MediaRouteProvider.
Then, either your app or your MediaRouteProvider is responsible for getting the request over to the Android TV device, and your app on it, by some means (WiFiDirect, Bluetooth, GCM over the Internet, whatever). There is nothing in the Android SDK that specifically addresses this -- you're on your own for rolling whatever protocol and connectivity you want. On the plus side, there's no built-in assumption in MediaRouteProvider about any particular way to deliver that information, meaning that you could be connecting to something that is not running Android at all.
I'm developing one Android application which would record video during calling when dialing some emergency numbers. Some of my android developer friends told it is not possible. Please help me if there is any way to achieve this
Normally, your app cannot know if some special number has been dialed. We can send a CALL Intent with some special number, and the Dialer system app will allow the end-user place the call. Or edit the number and place the call. It is also possible to write a broadcast handler that can be invoked when the end-user or some other app requested a call to some special number. But your app cannot perform the call itself.
If your app runs with superuser permissions (e.g. if the device is rooted), or if you replace the system Dial app with your custom one, then you certainly can control the camera while in call.
Also, if you forward the call over Internet, you can do what you want.
Finally, please note that even if you record the video during the phone call, you may not be able to live stream this video over the cellular network (some LTE networks do not turn off mobile data channel while in phone call).
I installed Kamailio, am able to add users and make calls, but I need to use it for my android push to talk client app i.e. upon calling another user(s) (using the same app), instead of ringing their app/phone it should directly transmit voice of the caller while the other user(s) is muted and to respond other user presses a toggle button to speak to the caller.
Is there a module that does this, would I have to implement my own or would I have to modify the source code to achieve this?
Thanks.
Kamailio is a SIP signaling server, usually acting as a proxy, it does not process media (audio) at all. Sending/receiving the media in a call is a matter of end points. Therefore the PTT functionality has to be implemented by client applications or a dedicated PTT server has to be placed in the network.
Just wonder whether it's possible to access phone's voice mail box using code?
I have seen in Android 4.0, Google has introduce a new content provider called "android.provider.VoicemailContract.Voicemails" but I want to do this on older versions of Android? Is it possible at all ?
No, because each network operator/phone manufacturer handles voicemail differently. In many cases, there won't even be any app on the phone that knows about individual voice messages. The best you can do is create a PhoneStateListener to listen for LISTEN_MESSAGE_WAITING_INDICATOR, which lets you read the message waiting indicator flag sent by the network operator (answers the question "Are there any new voice messages?").
I am new to android. I am trying to lock the device using voice . I recorded the voice with media recorder but now How I lock the phone with this voice ? plz any idea.
Interesting, but u need to probably do more work that mere speculation here. A quick brainstorm:
your app must be a device admin to be able to lock the device
to lock the device, this device admin could be "told" via a broadcast event routed to it
the "lock device" event can be raised by another / same app if it can capture from the mic,
probably forward this to a server that can do speech-to-text (Google has something), then yo app tries to recognize whether the response text matches the "lock" criteria. If it does, then broadcast the "lock" event.
This heavily depends on how good the speech-to-text part is done, otherwise, explore along those lines.