I have a very minimal knowledge about VoLTE service in android which is provided by the LTE operator.
Is there any API's are available to detect VoLTE call in android?
The API's such as
Call Connected
Call Disconnected
Latency
Call Status
Any link/API reference is much appreciated.
TelephonyManager.java have a function to check isVolteAvailable(). You can call that function to know the status of voLTE.
You can check the source here.. https://github.com/android/platform_frameworks_base/blob/master/telephony/java/android/telephony/TelephonyManager.java
If you can connect to at port then by using standard at commands, this can be verified.
at+cops? => this will give information about the current latched cell. check if the mobile is currently on LTE(7) cell.
make volte call and shoot the at+cops? again. If the call is connected and mobile is still in LTE(7) cell, then its for sure VoLTE call.
Related
I am tring to setup WIFI P2P on 2 devices using
manager.addLocalService(channel, service, ActionListener)
and then connect both devices using
manager.connect(channel, config, ActionListener).
I would like to know which method is called before the popup to accept/reject connection is shown on the target device. All I was able to find was onConnectionInfoAvailable(WifiP2pInfo p2pInfo), but it is called after the connection is established.
I basically want to receive the "instance name" of the device trying to connect to me using WIFI P2P and then reject the connection request without showing system dialog(that allows the user to accept/reject connection).
I can't anything that can help me do this on docs or any other place. If anyone knows how to do it or can point me in the right direction then please let me know.
I solved it. I can put the instancename and devicename (of device I want to connect to) in Map that is passed when setting up service. From other device I can retrieve map of all devices available using this and find the instancename of one I need.
I am trying to read the Preferred network type setting from the device. But nowhere android API's are available.
Use case:
Trying to read the Preferred network type and connected network type so that if the device has LTE enabled and the user is forcefully switched back to the lower network(3G,2G); then there should be a notification sent to the user.
I have checked the system setting code, But it's deprecated.
Settings.Secure.getString(getApplicationContext().getContentResolver(),
Settings.System.NETWORK_PREFERENCE);
Is there any alternate way to read the system secured settings(By reflection?).
And Also is it possible to write back the setting with the user permission?
Help is much appreciated.
I think the right code is:
Settings.Global.getString(context.getContentResolver(),Settings.Global.NETWORK_PREFERENCE)
How can I programmatically check that internet access in a android device is only over Wi-Fi and not over Packet Data connections like UMTS EDGE or GPRS ?
if you want your app to only use one particular type of data connection, you can form if/else logic and use check for mobile-network-access and wifi-access and give command accordingly
you can refer to mobile-network-access and wifi-access questions of stackoverflow for check on connection availability
I'm developping an app which may send sensitive data and I want to be sure that i don't send them on a public or weak protected network.
That's why I'd like to get the current security used on wifi network on Android.
I found this post but I'm not sure of the accuracy of the solution.
Indeed, the allowedKeyManagement method seems to return the supported protocols, but it's not explicitely said to return the current active protocol beeing used.
Is there a sure way to get the effective protection used on the cirrent wifi network ?
Thanks
I can suggest one method
Get list of all configured network using getConfiguredNetworks API
Loop through all entries and find the current Network using WifiConfiguration.status API. The status should be CURRENT for current network
For that current network, get the allowedKeyManagement and check that it is not NONE.
i would like if my question is possible or not.
Well every channel has a specefic frequency 1 à 13(2,4GHz), 36 to 64(5GHz) and 100 to 165(5GHz).
for example :
channel number 1 : 2412GHz ;channel number 2 : 2417GHz.
Well when we enter to the router interface from the localhost address ,we can easely choose a channel.
What i would like to do is to change the channel programmatically (from my android app ) .
I have an idea ,but i don't know if it's feaseble or not ,is to simulate the router web interface and do the same work that it doeas with android.
if someone has an idea please help me
PS: 'm the router adminsrator
Thank you
I think that is possible you connect to your router by SSH, and then, you change the configuration, and restart wireless, but, then, you will lost connection when channel changes.
However, I dont know if your router allow this operation with SSH
I have another idea:
With wireshark, see the HTTP packet sent between your PC and your router, when you does Login, and when you save configuration. If you understand them, maybe you make a new packet in your phone.
(sorry my English)
You can try to configure the router with SSH.