- Android signal strength
- 2 Answers 2
- How to get LTE signal strength in Android?
- 4 Answers 4
- Android onSignalStrengthsChanged – LTE Strength Measurement
- No Permissions needed
- Android onSignalStrengthsChanged LTE measurement
- Android Signal Strength
- About Mohit Gupt
- Android get signal strength
- Android get signal strength
- Latest commit
- Git stats
- Files
- README.md
- About
Android signal strength
Is there any method to get signal strength on both sim cards. I search a lot but I couldn’t find any solution. Maybe is there any method to register receiver on second sim card ? I’m working on Android 5.0 and I know that on this version Android officially does not support dual sim solutions. I found only this which nearly fits to me: Check whether the phone is dual SIM Android dual SIM signal strength
Second link presents some way but I cannot use it because method TelephonyManager.listenGemini is not available
2 Answers 2
Please note: the following is specific to some Android 5.0 devices. It uses hidden interface in Android 5.0, and will not work in earlier AND later versions. In particular, the subscription id changed from long to int when the API is exposed in API 22 (for which you should use the official API anyway).
For Android 5.0 on HTC M8, you may try the following to get the signal strength of both sim cards:
Overriding PhoneStateListener and its protected internal variable long mSubId . Since the protected variable is hidden you will need to use reflection.
You also need to get the list of active subscription IDs from the SubscriptionManager for instantiating the class. Again SubscriptionManager is hidden in 5.0.
Then you can iterate through the subIdList to create instances of MultiSimListener . e.g.
You can then call TelephonyManager.listen as usual, for each of the listeners.
You will need to add error and Android version / device check to the code, as it works only on specific devices / version.
Источник
How to get LTE signal strength in Android?
I am using Verizon’s new LTE handset from HTC Thunderbolt. I cannot find the API to query for the signal strength while the handset is on LTE. By entering the field test mode (##4636##), I can see signal strength as -98dBm 2 asu. Anyone know what API I could use to get this info?
4 Answers 4
Warning : this solution should work for Android below API17. Some people may have troubles with newer api or specific phone brand (like Huawei)
You need to use this code. In fact, all the information you need is here :
The parts[] array will then contain these elements:
In order to solve this question I created an application called Signal Strength Detector and with source code on GitHub. In my past experience, some devices running Android ICS 4.0 and up have a getLevel method on SignalStrength that returns an integer from 0 — 4 reporting the signal strength. On some other LTE devices (I do not believe the HTC Thunderbolt), there are some methods like getLteCqi getLteRsrp getLteRsrq and getLteRssnr which I will leave to you to determine how to use these values to calculate a signal strength. Finally, I found that on some devices (I believe the HTC Thunderbolt) the LTE signal strength is actually reported with the methods labelled for GSM signal strength! It’s crazy, but true. Feel free to download Signal Strength Detector and check out the results on your device and/ or modify code as necessary.
As a side note, you will need to use Reflection to access these methods, again which I will leave to you to determine how to best implement this. It’s fairly simple, but you need to do a lot of try-catch to determine if the method is present, and sometimes setAccessible(true) just to ignore any issues with private methods.
Источник
Android onSignalStrengthsChanged – LTE Strength Measurement
In this tutorial I would show how to measure the signal strengths in Android. Since Android is a mobile operating system, therefore measuring signal strengths from device itself would be a very easy task. Android onSignalStrengthsChanged is a method in Android PhoneStateListener class which observes the changes in telephony states of a device. In my previous tutorials I utilized the power of Android PhoneStateListener class to determine the changes in message waiting indicator, service state, data activity and also to monitor the change in cell info. If you wish to read the full series, links are below:
To listen the change in signal strengths a flag PhoneStateListener.LISTEN_SIGNAL_STRENGTHS is used in the listen method of TelphonyManager class. By using this flag we will start getting the callbacks in onSignalStrengthsChanged(SignalStrength signalStrength) method whenever the signal strength of network changes.
No Permissions needed
Now the interesting part here is that, to use the Android onSignalStrengthsChanged method we don’t need to add any permissions in our manifest. I tested this on a Kitkat 4.4.4 device.
Lets start with PhoneStateListener Activity:
As you can see in the above class, a custom Android PhoneStateListener is used to capture the updates of signal strengths with the help of TelephonyManager class. as soon as the listener is registered, we start receiving callbacks in Android PhoneStateListener onSignalStrengthsChanged method.
Android onSignalStrengthsChanged LTE measurement
LTE (Long-Term Evolution) is a new emerging standard for wireless communication. LTE is an upgrade for both GSM/UMTS and CDMA2000 Networks. Here the good part is, android supports LTE standard. With the help of PhoneStateListener and Android onSignalStrengthsChanged method we can measure LTE signal strengths. In this Android onSignalStrengthsChanged – LTE Strength Measurement tutorial I would show how to measure the signal strength for LTE network by using the Java Reflection APIs. Lets define the custom PhoneStateListener:
Before moving forward let me give a brief intro to Java Reflection API. Reflection API is used to examine or modify the run-time behavior of any application in running in virtual machine (DVM or ART). Since this is a very powerful API, it is advised to use this only if you know what you are doing. To read more about reflection API, please go here. Coming back to this tutorial, here we are using the reflection APIs to invoke following methods which are not included in Android APIs:
- getLteSignalStrength – Returns LTE signal strength
- getLteRsrp – Returns LTE Reference Signal Received Power
- getLteRsrq – Returns LTE Reference Signal Received Quality
- getLteRssnr – Returns LTE rssnr
- getLteCqi – Returns LTE Channel Quality Indication
Android Signal Strength
Although if we go by standard Android APIs, whenever Android onSignalStrengthsChanged method is invoked an object of SignalStrength is passed as an argument. As its shown in the above code, with this object we can determine the type of signal being receiving on device. It could be any type of network like GSM, CDMA or EVDO, hence one can get signal strength as well. Hope this helped you out, if it did please share it with your friends.
About Mohit Gupt
An android enthusiast, and an iPhone user with a keen interest in development of innovative applications.
Источник
Android get signal strength
Are you living or working in a low signal area ? Then this is the app for you. With this app you can get a good idea of the mobile signal strength and find out which corners of your office or home are having the best reception.
What this app gives you:-
1. An aesthetic and very functional full screen Signal Strength Meter.
2. Simple Home Screen widgets without taking too much space
3. Neighboring Cell tower coverage
4. Network Latency or Delay for data
IMPORTANT: Read the notes
The signal meter and widgets cover all networks including 4G/LTE and give extensive network information. The widgets can be extensively customized to any theme with a prototype. There is also notifications for out of service and roaming conditions.
Free Features:-
1. Network Signal strength in dBm and percentage.
2. Graphic and Minimal Widgets with color schemes
3. Out of service and roaming notifications.
4. Detailed Network info and Neighboring cell towers
5. Airplane or Restart Mobile Connection only without disturbing WiFi, NFC etc(Not available for >= Android 4.2)
6. Network latency widget
7 Signal Check for basic diagnostics
Pro Features(Inapp Purchase):-
1. AdFree
2. Additional Widget Color schemes
3. Service Notification tones
4. Auto Refresh Signal Meter and Neighbor cells
Требуется Android: 7.0 и выше
Русский интерфейс: Нет
Версия: 22.0.8 Premium (Alex0047)
Версия: 22.0.7 Premium (Alex0047)
Версия: 22.0.6 Premium (Alex0047)
версия: 22.0.5 Premium Network Signal Strength
версия: 22.0.3 Сообщение №87, автор Giacomino
версия: 21.0.7 [Premium] Сообщение №71, автор Alex0047
версия: 21.0.5 Premium Network Signal Strength (Пост Alex0047 #76042404)
версия: 21.0.3 Premium Сообщение №67, автор Alex0047
версия: 21.0.1 Premium Сообщение №66, автор Alex0047
версия: 21.0.0 Premium Network Signal Strength (Пост Alex0047 #73852475)
Версия: 19.4.2 Premium Сообщение №62, автор Giacomino
Версия: 19.4.2 Premium Сообщение №63, автор Alex0047Версия: 19.4.0 Premium Сообщение №61, автор Alex0047
версия: 17.0.8 Premium Mod Network Signal Strength (Пост Alex0047 #59405142)
Версия: 19.3.9 Premium Сообщение №60, автор Alex0047
Версия: 19.3.8 Premium Network Signal Strength (Пост Alex0047 #72670774)
Версия: 19.3.7 Premium Сообщение №58, автор Alex0047
Версия: 19.3.6 Premium Сообщение №57, автор Alex0047
Версия: 19.3.5 Premium Сообщение №56, автор Alex0047
Версия: 19.3.3 Premium Сообщение №54, автор Giacomino
Версия: 19.3.2 Premium Сообщение №53, автор Alex0047
Версия: 19.3.1 Premium Network Signal Strength (Пост Alex0047 #68777060)
Версия: 19.3.0 Premium Network Signal Strength (Пост Alex0047 #68284238)
Версия: 19.2.8 Premium Network Signal Strength (Пост Alex0047 #68219390)
Версия: 19.2.7 Premium Network Signal Strength (Пост Alex0047 #67214264)
Версия: 19.2.5 Premium Network Signal Strength (Пост Alex0047 #67059883)
Версия: 19.2.3 Premium Network Signal Strength (Пост Alex0047 #64872208)
Версия: 19.2.2 Premium Network Signal Strength (Пост Alex0047 #64577794)
Версия: 19.2.1 Premium Network Signal Strength (Пост Alex0047 #64383763)
Версия: 19.1.9 Premium Network Signal Strength (Пост Alex0047 #64315578)
версия: 19.1.7 Premium Network Signal Strength (Пост Meoweom #63888265)
версия: 19.1.6 Premium Network Signal Strength (Пост Alex0047 #63872719)
версия: 19.1.4 Premium Network Signal Strength (Пост Alex0047 #63424925)
версия: 19.1.3 Premium Network Signal Strength (Пост Alex0047 #63361727)
версия: 19.1.2 Premium Network Signal Strength (Пост Alex0047 #62321627)
версия: 19.1.1 Premium Network Signal Strength (Пост Alex0047 #62275264)
версия: 19.1.0 Premium Network Signal Strength (Пост Alex0047 #61509269)
версия: 19.0.7 Premium Network Signal Strength (Пост Giacomino #61323601)
версия: 19.0.5 Premium Network Signal Strength (Пост Alex0047 #61188420)
версия: 19.0.4 Premium Network Signal Strength (Пост Giacomino #60597794)
версия: 19.0.3 Premium Network Signal Strength (Пост Alex0047 #60562998)
версия: 19.0.1 Premium Network Signal Strength (Пост Alex0047 #60084304)
версия: 19.0.0 Premium Network Signal Strength (Пост Alex0047 #60015959)
версия: 17.0.8 Premium Network Signal Strength (Пост Giacomino #58994946)
версия: 17.0.6 Premium Network Signal Strength (Пост Alex0047 #58745669)
версия: 17.0.4 Premium Network Signal Strength (Пост Alex0047 #52181252)
версия: 8.3.1 Premium Network Signal Strength (Пост Alex0047 #47114234)
версия: 8.3.0 Network Signal Strength (Пост vutak #46516296)
версия: 8.2.8 Network Signal Strength (Пост Alex0047 #45944472)
версия: 8.2.7 Network Signal Strength (Пост Alex0047 #41759124)
версия: 8.1.9 Rus Network Signal Strength (Пост papasha55 #41236790)
версия: 8.1.6 Rus //4pda.to/forum/d…Bv8.1.6.Rus.signed.apk
версия: 8.2.0 //4pda.to/forum/d…al+Strength+v8.2.0.apk
версия: 8.1.9 Network Signal Strength (Пост Alex0047 #41117083)
версия: 8.1.8 //4pda.to/forum/d…gth_Premium_v8.1.8.apk
версия: 8.1.7 //4pda.to/forum/d…gth+Premium+v8.1.7.apk
версия: 8.1.6Network Signal Strength v8.1.6.apk ( 2.34 МБ )
Сообщение отредактировал iMiKED — 15.11.21, 10:30
Источник
Android get signal strength
A library and sample application with the purpose of getting an accurate signal strength on different Android phones.
Latest commit
Git stats
Files
Failed to load latest commit information.
README.md
SignalStrengths is a library and sample application with the purpose of getting an accurate signal strength on different Android phones.
For testing and experimentation purposes, a sample apk can be downloaded here.
The Gradle dependency is available through jCenter, which is used by default in Android Studio. To add the module to your project, copy this line into the dependencies section of your build.gradle file.
Listening for Signal Changes
Getting a Signal Value
To obtain a signal value from a SignalStrength object, simply pass it to one of the methods in the SignalStrengths class, which will return a number from 0-4, or -1 if an error occurs. Some examples of this are below.
Using a Specific Method
This allows you to specify exactly which method you want to obtain a value from.
First Valid Level
This gets the first valid signal level available from any method in order of accuracy. This is the most recommended way of getting a signal value, as it is the most consistently accurate across different phones and android versions. See Excluding Methods and Custom Methods for ways to change this method’s behavior.
This gets the average of all the valid levels. To exclude a level, see Excluding Methods.
The list of methods used by SignalStrengths can be accessed using SignalStrengths.getMethods() . An example of how to exclude a method is below.
It is also possible to add your own method to the list of methods used by SignalStrengths. An example for how to create a new method is below.
About
A library and sample application with the purpose of getting an accurate signal strength on different Android phones.
Источник