开发者

Fake location AND speed in emulator. KML or GPX?

I figured how to connect emulator + IntelliJ + DDMS all together and I can spoof GPS location fine.

I figured how to generate KML and GPX files.

Issue I have: 1. KML file I generate using google maps doesn't have speed info. 2. GPX files won't even open in DDMS

Ideally I'd like to solve my problem with either KML or GPX (I do开发者_如何学Pythonn't care which format to use) but I need to feed coordinates and speed into emulator.

Is there any way to achieve this?


So far no responses :)

Here is what I found myself. The only way (as far as I see it) to pass speed into emulator is to use Telnet and pass command like this:

geo nmea $GPRMC,040302.663,A,3939.7,N,10506.6,W,0.27,358.86,200804,,*1A

Only GPRMC format can carry speed and other goodies.

Now I needed better way to pass steps to my application. Since my main tool is C# - I just wrote simple telnet client, put it into test class and voila! Now I get step by step GPS spoofing on emulator. I can use any source and then pass it into emulator for replay.


The geo fix command now supports velocity:

'geo fix <longitude> <latitude> [<altitude> [<satellites> [<velocity>]]]'
 allows you to send a simple GPS fix to the emulated system.
 The parameters are:

  <longitude>   longitude, in decimal degrees
  <latitude>    latitude, in decimal degrees
  <altitude>    optional altitude in meters
  <satellites>  number of satellites being tracked (1-12)
  <velocity>    optional velocity in knots
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜