RaBu.dk - Website and weblog of Rasmus Burkal

How to set the location in the Android Emulator

Posted on the 13.06.2011 at 12:13 by Rasmus Burkal

By default there is no location (latitude and longitude) set in the Android Emulator, so you have to set this – before you are able to work with GPS location coordinates. Here is how you do it:

  1. Start your Android Emulator
  2. Open your Terminal or Command Prompt (CMD)
  3. Connect to the Emulator:
    telnet localhost <port>
    

    Note: You can see the port number in the title bar of the running Android Emulator

  4. Enter the location coordinates you wish to test with:
    geo fix <longitude> <latitude>

Read more about user location in the Android Developer Guide

Bookmark and Share

Comments

There are no comments yet.

Leave a reply

To leave a reply, you must be logged in.