tags:

views:

365

answers:

2

I am making for my Graduation Project a low price Navigation device, using Android as Operating System

I tried the Native Google's Map-view Control, but it works only Online ..
and of-course I want to store maps for offline navigation

So.. I want a map provider (like OpenStreetMap) that :

  • I can use offline
  • Contain Searchable Street names (not only a rendered image)
  • for commercial use
  • Free or at low price

The problem with OpenStreetMap that it doesn't provide detailed map for most cities in Egypt.

+2  A: 

You want something like MapDroyd, maybe talk to them about using their code.

Alternatively take the OpenStreetMap widget from here http://code.google.com/p/osmdroid/ and add a way to cache regions. For the street name index you can download the world.osm (or just part of it to save time) and then run it through a python script like this:

(Note that this needs some work: it doesn't handle duplicate street names, so you'll have to modify it a bit. It also finds pubs and ATMs.)

#!/usr/bin/python

from xml.dom import pulldom

doc = pulldom.parse("england.osm")
#outFile = open("england.txt", "w")

nodes = {}
ways = {}
pubs = []
atms = []

i = 0
for event, node in doc:
    if event == pulldom.START_ELEMENT:
        if node.localName == "node":
            doc.expandNode(node)

            nodeID = node.getAttribute("id")
            nodeLat = node.getAttribute("lat")
            nodeLon = node.getAttribute("lon")

            amenity = "";
            for tag in node.getElementsByTagName("tag"):
                if tag.getAttribute("k") == "amenity":
                    amenity = tag.getAttribute("v")

            nodes[int(nodeID)] = ( float(nodeLat), float(nodeLon) )

            if amenity == "pub":
                pubs.append(int(nodeID))
            elif amenity == "atm" or amenity == "bank":
                atms.append(int(nodeID))

        elif node.localName == "way":
            doc.expandNode(node)

            name = "";
            for tag in node.getElementsByTagName("tag"):
                if tag.getAttribute("k") == "name":
                    name = tag.getAttribute("v")
            if name == "":
                continue;

            wayName = name.encode("latin-1", "replace")
            refList = [nd.getAttribute("ref") for nd in node.getElementsByTagName("nd")]

            if ways.has_key(wayName):
                ways[wayName].append([int(x) for x in refList])
            else:
                ways[wayName] = [int(x) for x in refList]

        i = i + 1
        if i % 100 == 0:
            print(i / 100)

print(nodes)
print(ways)
print(pubs)
print(atms)

#outFile.close()
Timmmm
MapDroyd uses Maps from OSMand OSM itself doesn't provide detailed maps in most cities EgyptThe Question is about provider other than OSMeven if it has no API to deal with in Android , I can do whatever it takes to make this works on Android
Radian
Sounds like more of a business question than a programming one then. You might want to try ask on a mapping forum rather than stackoverflow.I seriously doubt there will be any free map providers other than OSM.
Timmmm
+1  A: 

I found "Mobile Atlas Creator" http://trekbuddyatlasc.sourceforge.net/

Radian