How to measure GPS signal strength on Android?

2019-01-09 04:18发布

问题:

Question is as simple as the title: How to measure GPS signal strength?

回答1:

Are you sure you mean signal strength vs. accuracy? What good is the signal strength? Since the GPS position is determined via many satellites, you don't have "one" signal strength.

So assuming that you really mean signal strength, you can get the GpsStatus via LocationManager.getGpsStatus(), and that gives you a list of satellites via getSatellites()', and each one of those has a signal-to-noise ratio (getSnr()).

Assuming you mean accuracy, try Location.getAccuracy().



回答2:

You can read signal strength in MNEA message GSV in SNR-Signal to Noise Ratio.

Signal strength is VERY important. Too weak of a signal and the receiver can't track them. You need several 'strong' satellites to get position, not just one.

Older receivers couldn't track in trees or inside buildings. Modern receivers are much more sensitive.



回答3:

It is very difficult to measure the signal level of a gps satellite without very expensive test gear (spectrum analyzer or specialized gps receiver). There are no commercially available tools to do this.

Why would you want to do this, anyway? The signal level is actually quite irrelevant in determining position.