How to add ordinance survey maps to OSMand

613 views
Skip to first unread message

Oliver Mattos

unread,
Sep 21, 2015, 10:40:40 PM9/21/15
to Osmand
OS maps have a license requirement, and hence are not in OSMand by default, but here is how to add them (by getting a free license).


Grab a mapping api license from Microsoft:  https://msdn.microsoft.com/en-us/library/ff428642.aspx

Create a new map layer, by first choosing "Install more" and selecting a free included microsoft maps layer.  Next "define/edit" one of them.  Choose one of the microsoft ones from the dropdown, and give it a new name.

Change the URL to be this:  (yes, I know it's code, but in this case you can put code in the tile URL box).

public static String eqt(int z, int x, int y) {static final char[] NUM_CHAR = { '0', '1', '2', '3' };char[] tn = new char[z];for (int i = z - 1; i >= 0; i--) {int num = (x % 2) | ((y % 2) << 1);tn[i] = NUM_CHAR[num];x >>= 1;y >>= 1;}return new String(tn);} String getTileUrl(int z, int x, int y) { return "http://ak.t2.tiles.virtualearth.net/tiles/r" + eqt(z,x,y) + ".png" + "?g=3675&productSet=mmOS&key=YOUR_KEY_HERE";}


Replace YOUR_KEY_HERE with your license key from the first step.


Enjoy nice ordinance survey maps!  (This should also work for any other custom map types that require licenses).

P Wat

unread,
Sep 23, 2015, 4:09:02 AM9/23/15
to Osmand
Presumably in this instance "OS" = UK Ordnance Survey = Probably the best maps in the world - Really useful for UK - Must try your method, Oliver. Thanks. Paul W.
Reply all
Reply to author
Forward
0 new messages