maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Maemo Mapper v1.0 for the 2006 OS (https://talk.maemo.org/showthread.php?t=2142)

gnuite 2006-08-17 23:59

Quote:

Originally Posted by Luna
I've been playing with the idea of server. Like said, there is alot of redundant data. I could further subdivide the data and really clean house. Just rebuild the zoom level 0 and server up the rest in the 256x256 blocks.

If you try limiting the data to just zoom-level-0 blocks, though, you're not going to get a very readable image (in terms of text _and_ in terms of road lines).

indio 2006-08-18 09:21

Thanks Gnuite for your reply. I bow to your trully elite C skill :).

I am trying to get some basic information through my GPS receiver using python. What I want to do is just get my current position, compare it with another waypoint's coordinates and get the distance.

Could point our some documentation I could study? I am too new to GPS so I dont know where to start. I think getting just the difference of two coords(the current fix and an arbitrary point) will be less difficult than navigating a map.

ReinhardE 2006-08-18 10:38

Quote:

Originally Posted by Luna
I've been playing with the idea of server. Like said, there is alot of redundant data. I could further subdivide the data and really clean house. Just rebuild the zoom level 0 and server up the rest in the 256x256 blocks.

Under the assumption that all tiles in all zoom levels are around the same size, you only save 25%, if you delete all levels greater than 0 (due to the geometric series 1 + 1/4 + 1/16 ...).

Luna 2006-08-18 12:58

Quote:

Originally Posted by ReinhardE
Under the assumption that all tiles in all zoom levels are around the same size, you only save 25%, if you delete all levels greater than 0 (due to the geometric series 1 + 1/4 + 1/16 ...).

Correct. That is why I have no problem with retaining the higher levels, it is when you hit level 0 and 1 that you have the big hit (and those are the only ones I'm really concerned with). When you look at the typical usage, I'm either zoomed midway or all the way in looking for details.

This is just for discussion though. A MPS file base server is the real way to go if I put any time into this. Gnuite's excellent work and my current work obligations will make this a hard task to truely begin :)


BTW, are jpegs decoded by software or in hardware?

Luna 2006-08-18 13:00

Quote:

Originally Posted by gnuite
If you try limiting the data to just zoom-level-0 blocks, though, you're not going to get a very readable image (in terms of text _and_ in terms of road lines).


What? You cannot read text that is quarter point in size ? :)

ReinhardE 2006-08-18 13:28

Quote:

Originally Posted by Luna
BTW, are jpegs decoded by software or in hardware?

Even if you give files names like 54823.jpg they need not be jpeg files. When you try jpegtopnm you get an error, while pngtopnm succeeds. So google-map files could be of type png after all.

Luna 2006-08-18 19:41

The headers say png.

I did a little test to see the level of redundancy in my level 0 folder. Here are the stats: 169 folders, 16900 files total, 12355 distinct files. I did this via MD5 hash comparision. Now I need to split each of the 16900 files into 4 or so separate images and see how it pans out.

gnuite 2006-08-19 16:25

Quote:

Originally Posted by ReinhardE
Even if you give files names like 54823.jpg they need not be jpeg files. When you try jpegtopnm you get an error, while pngtopnm succeeds. So google-map files could be of type png after all.

Google Maps uses PNG for street maps and JPG for topographical maps. It doesn't matter what the extension is - I just picked jpg for the sake of simplicity. It probably should have no extension, but it's too late to change that now, and with an image extension, at least people know that it's an image (even if it's not the right image type).

gnuite 2006-08-19 16:31

Quote:

Originally Posted by indio
Thanks Gnuite for your reply. I bow to your trully elite C skill :).

I am trying to get some basic information through my GPS receiver using python. What I want to do is just get my current position, compare it with another waypoint's coordinates and get the distance.

Could point our some documentation I could study? I am too new to GPS so I dont know where to start. I think getting just the difference of two coords(the current fix and an arbitrary point) will be less difficult than navigating a map.

If you use rfcomm, accessing the GPS Receiver is as easy as opening a file (and the interface is the same). Most likely the input stream will be in ASCII following the NMEA protocol, so google it for info about that.

Once you have your current position (from, e.g., the RMC sentence in the NMEA protocol), it's easy to calculate the surface distance between two points - there are numerous code examples on the web.

The code for maemo mapper is not all that complex, especially the parts that do the NMEA parsing and geographical calculations. The hard part is the matter of proper UI design considering the form factor.

tdmajic 2006-08-20 23:22

are there any other gps programs that can be used on the n770? mm is a really cool app. but i really can't depend on the routing portion of the app. uses the long way all the time.

oelph 2006-08-21 13:22

How do people manage their maps? I won't be using the 770 'online' whilst on the road and therefore want to predownload as much as possible. I've tried doing a download along a popular route (Plymouth to London) but it was taking so long I had to cancel it.

Is there a better way to predownload? Is it possible to get all maps for the UK? If so how big would that download be?

Lastly are there any tips for the optimal zoom levels to download?

ioan 2006-08-21 17:11

Quote:

Originally Posted by oelph
I've tried doing a download along a popular route (Plymouth to London) but it was taking so long I had to cancel it.
Is there a better way to predownload? Is it possible to get all maps for the UK? If so how big would that download be?

You can use this application to download your maps on your computer and then transfer them on the memory card.
-i

Luna 2006-08-21 17:42

Awesome, I was just about to write an app to do that

oelph 2006-08-21 20:43

OMG, thank you!! Thank you!! :)

oelph 2006-08-22 15:48

What's the best way to get maps for say all of London? The following link seems to cover much of Greater London:

EDIT:

Ok so I didn't realise this and maybe a few others didn't:

In Maemo Mapper if you zoom out to encompass an area you wish to download it will determine the top left and bottom right coordinates. You can then set the download area zoom level to the desired level (eg 2) and it will get all the maps required.

mebourne 2006-08-24 12:36

Quote:

Originally Posted by indio
1. It seems maemo mapper does not work with a proxy server. This is a serious disadvantage, some ppl only see the web through a proxy(including me ofcourse). Maybe it could just respect the $http_proxy var?

It works through a proxy server for me. OS2006, v1.1. I set the proxy in the advanced settings for my connection (http, https, ftp) and it's working right now.

armin 2006-08-24 17:47

Quote:

Originally Posted by Luna
Keep in mind that the cluster size on the larger MMC card will kill you. For instance, my metro area cached was was a total file size of around 57MB. Size on disk 760MB!

Good hint! I backuped my 512mb RS-MMC, reformatted with VFAT32 using 1kb cluster size, and restored it. Before it used 8kb cluster size, which was a big waste with map tiles. My maps repository shrank by 35%. Before my MMC was >90% full, now it is only 75% full.

Before (8kb sector):

/media/mmc1 $ du -ks .??* *
144 .archive
8 Audio clips # this is an empty directory!
46768 backups
4480 Documents
2144 Images
395296 maemo-mapper
11928 supertux
192 tuxpaint


After (1kb sector):

/media/mmc1 $ du -ks .??* *
86 .archive
1 Audio clips # this is an empty directory!
46675 backups
3813 Documents
2033 Images
293338 maemo-mapper
7783 supertux
120 tuxpaint

armin 2006-08-24 18:03

Maemo-Mapper's cousins for PSP and Nintendo DS
 
PlayStation Portabel (PSP) now has an application similiar to Maemo-Mapper:

http://www.pspaccess.net/modules.php...rticle&sid=595
http://www.youtube.com/watch?v=_nitCHViaCU

And Nintendo DS:

http://www.natrium42.com/blog/?p=31

Some features of these might be interesting for Maemo-Mapper.

ReinhardE 2006-08-25 12:03

Quote:

Originally Posted by armin
Good hint! I backuped my 512mb RS-MMC, reformatted with VFAT32 using 1kb cluster size, and restored it.

Today I received my new 2GB Kingston MMC, so I backed up my maps
from a 1GB card (fromatted with FAT32 and logical sector size 512 bytes)

The 1 GB card:
/dev/sdc1 1017268 761980 255288 75% /USBc1

The (uncompressed) backup file (ls -l):
584038400 2006-08-25 12:50 Maps.tar

I tested the new 2 GB card via
fsck -v /dev/sdc1
and was told that the logical sector size is 512 bytes.

So I untared the backup and to my surprise the MMC card was full, before everything was backed up.

That was the time when I realized that the minimum allocation size for a file is cluster size (which was 32KB) and not logical sector size.

By formatting the card with
mkfs.vfat -S 512 -s 1 /dev/sdc1
one achieves 512 bytes logical sector size (-S 512) and 1 logical sector per cluster (-s 1), and therefore 512 bytes per cluster.

After restoring my tar file, it took only 27% of disk space:

The 2 GB card:
/dev/sdc1 2007789 534883 1472906 27% /USBc1

The bad news: my Nokia phone (symbian) cannot read the card any more :(

oelph 2006-08-25 14:57

For generating routes and directions can anyone point me to a site that allows you to specify a preference for certain roads or ways to your destination?

Google generates one route but I'd prefer to travel a slightly different route but have no options available to specify waypoints.

frethop 2006-08-25 16:41

The Marengo Route Planner at http://www.marengo-ltd.com/map/ lets you design your own route. Unfortunately, you have to massage the final GPX file to change the "rte" specs to "trk" and add a <trkseg></trkseg> pair.

-F

bac522 2006-08-25 21:23

Quote:

Originally Posted by frethop
The Marengo Route Planner at http://www.marengo-ltd.com/map/ lets you design your own route. Unfortunately, you have to massage the final GPX file to change the "rte" specs to "trk" and add a <trkseg></trkseg> pair.

-F

Would be nice to take the data from that site, save it into a file and then feed it into http://gnuite.com:8080/cgi-bin/gpx.cgi to get a the Maemo Mapper file needed that could then be saved and upload to maemo mapper. Having the route along with the waypoints is helpful.

9a6or 2006-08-25 21:52

These threads are getting a bit long but earlier Gnuite responded to my similar request suggesting that at present smaller sections of the route can be created which are then loaded one after the other. Alternatively the route segments can be edited manually to remove the end/beginning of segments resulting in one route.


It is a bit fiddly but works. I use Google Earth to get the co-ordinates of my POIs and run Gnuite's prog to generate the route segments. I don't bother about the extra POI at the end of segments so I just load them one after the other and save as a single long one. These routes took me through Europe this summer UK-Italy-Hungary-UK.

Kudos to Gnuite, yet again.

Mara 2006-08-28 12:51

Overwrite corrupt/incomplete map files
 
I'm not sure if anyone else has encountered this problem: Sometimes during the map download if the internet connection gets interrupted and causes the map file not to load completely. Part of it is still saved in the MaemoMapper file storage directory, thus Mapper thinks it has the map. However, Mapper does not show that particular map file. (I guess that's because it is corrupt and it detects it during loading the map.)

What I end up doing was hooked up 770 to PC and using file manager (maps are saved in MMC card) browsed through all the map files... and deleted the ones that were corrupt/incomplete. After that Mapper did redownload the maps that were missing.

Gnuite: Can you add couple lines of code that checks the file, if it is corrupt or incomplete (or if that is not possible then somehow detect situation in Mapper when it did not load and show a specific map file properly?), and then redownload the map?

There is somewhat similar request over here:
http://www.internettablettalk.com/fo...ead.php?t=2899

That might be a good addition as well to force (re)download maps by area, similar to the function already in Mapper download maps by area...

ReinhardE 2006-08-28 13:20

Quote:

Originally Posted by Mara
I'm not sure if anyone else has encountered this problem: Sometimes during the map download if the internet connection gets interrupted and causes the map file not to load completely.

As the corrupted files seem to have a time stamp different from ordinary files,
I use simple find commands (from a linux host) for purging the repository:
Code:

#!/bin/sh
# delete files younger than 10 days
find . ! -type d -mtime -40 -print -delete
# delete files with dates in the 70s
find . ! -type d -mtime +11000 -print -delete

It usually works quite well. But of course one should have some assistance from maemo-mapper.

BK_man 2006-08-29 14:56

Gps
 
Today have bought Nokia LD-3W. Works well.

Next question - how can I download maps from Google?
This link is not working anymore (tried from laptop's Firefox it - got HTTP/404): http://mt0.google.com/mt?n=404&v=w2.....108180&zoom=2

It looks like that now actual map's URI are: http://kh1.google.com/kh?n=404&v=9&t=trtqttrrqqrssr

How can I download particular area of map?

gnuite 2006-08-29 15:11

Quote:

Originally Posted by BK_man
Today have bought Nokia LD-3W. Works well.

Next question - how can I download maps from Google?
This link is not working anymore (tried from laptop's Firefox it - got HTTP/404): http://mt0.google.com/mt?n=404&v=w2.....108180&zoom=2

The "x" and "y" in that link don't refer to latitude and longitude, but rather an alternative coordinate system based on integer "tile numbers." For example, a zoomed-out map of part of South America has x=10, y=15, and zoom=12:

http://mt0.google.com/mt?n=404&v=w2....0&y=15&zoom=12

Quote:

Originally Posted by BK_man
It looks like that now actual map's URI are: http://kh1.google.com/kh?n=404&v=9&t=trtqttrrqqrssr

This URL is for topographical maps. The other URL is for street maps.

Quote:

Originally Posted by BK_man
How can I download particular area of map?

Use the "Download by Area" or "Download Along Route" menu items in the "Maps" menu of Maemo Mapper, or use a third-party program.

BK_man 2006-08-29 15:45

Quote:

Originally Posted by gnuite
The "x" and "y" in that link don't refer to latitude and longitude, but rather an alternative coordinate system based on integer "tile numbers." For example, a zoomed-out map of part of South America has x=10, y=15, and zoom=12:

http://mt0.google.com/mt?n=404&v=w2....0&y=15&zoom=12

This URL is for topographical maps. The other URL is for street maps.

Use the "Download by Area" or "Download Along Route" menu items in the "Maps" menu of Maemo Mapper, or use a third-party program.

Thanks a lot, problem solved.

edk4971 2006-09-01 06:15

map torrents
 
So I downloaded my state (NJ) all even number zoom levels. Granted NJ is a small state, but it took up 446 MB (2.4 GB on disk on NTFS) and on a FAT 32 MMC it's looking like it's going to take about 600 MB (not done copying yet). Has anyone else had the idea to download all the states and torrent them? Obviously it wouldn't fit on a MMC card, but there are laptop hard drives that use little enough power that they can be run off USB alone, or certainly off just a power inverter in the car (or just grab the maps you want for where you're going off your computer).

My completely uneducated guess would say all of the US could be stored on in about 100gb, perhaps less if gnuite was willing to slightly modify the program to allow for dynamic resizing of maps, or perhaps import from say... streets and trips? If M$ can fit all of it's driving data on 1 650 MB CD, maybe there's a way to convert all that into something MM can understand?

just an idea for those of us w/o data on our cell plans... thoughts?

gnuite 2006-09-01 08:05

Quote:

Originally Posted by edk4971
If M$ can fit all of it's driving data on 1 650 MB CD, maybe there's a way to convert all that into something MM can understand?

Sure; you could use compressed public-domain vector-based street data, and you could render map images on-the-fly based on the data. And, if you could find enough free data, or if you had a non-trivial chunk of cash to buy it, you could even calculate route directions on-the-fly, automatically adjusting as you drive off course. This is generally what TomTom or expensive in-car navigation systems do.

Unfortunately, it would run slower than molasses on a Nokia 770, or it would look considerably uglier than what Google Maps provides (admit it - TomTom's "maps" are ugly). There is no way that Maemo Mapper could generate images as pretty and readable as those which Google Maps provides without expending an unreasonable (and likely unusable) number of CPU cycles, especially without hardware floating point operations. Hell, even Google Maps admits its complex to generate aesthetically pleasing maps on-the-fly; that's why they pre-render the maps and store the PNGs on network drives. That's what made their web site so much slicker than MapQuest or Expedia. It would be near impossible to provide operation as smooth as Google Maps if you were generating maps on-the-fly from vector data.

Furthermore, the design for a "Vectorized Maemo Mapper" would be so completely different that, if such an effort were engaged upon by some entrepreneurial lads with more time on their hands than I have, I would suggest that it create a product separate from Maemo Mapper, so as not to unnecessarily increase the memory requirements of the application for those who prefer raster maps to vector maps. It could take the form of a #include-controlled separate build, or as a minimal web server that could serve tiles based on vector data.

In any case, I'm happy with raster images and do not have any motivation to sacrifice anti-aliased beauty by trying to modify Maemo Mapper to support vector data. Maemo Mapper is GPL, though, so feel free to contribute if you wish.

bac522 2006-09-01 12:40

Quote:

Originally Posted by gnuite
In any case, I'm happy with raster images and do not have any motivation to sacrifice anti-aliased beauty by trying to modify Maemo Mapper to support vector data. Maemo Mapper is GPL, though, so feel free to contribute if you wish.

Second that!!!! I'm very happy with this app, it's my favorite and other then for maybe some usability enhancements, the fundamental app doesn't and shouldn't change at all.

edk4971 2006-09-01 13:09

fair enough, wasn't even sure if it was possible (was hoping though) ahh well

gnuite 2006-09-01 16:50

Quote:

Originally Posted by edk4971
fair enough, wasn't even sure if it was possible (was hoping though) ahh well

I'm not saying it's impossible, and I didn't mean to dash anyone's hopes or aspirations to do it. I'm just saying that there's a tradeoff here between pretty maps that take up a lot of space and quick-and-dirty vector renderings that don't. With a little more horsepower, we could get something close to TomTom, but no matter how much CPU they put in the Nokia 770, the on-the-fly renderings will never be as good-looking as Google's pre-rendered PNGs, so the tradeoff will always exist.

Partly, I was trying to provide justification for why I'm not going to try to implement it in Maemo Mapper. :)

P.S. For the record, I don't have a data plan, or a cell phone at all, and at the exhorbitant rate these cell plans go for, I probably never will, so I'm in the same boat as you. I bought a 1 GB memory card, and I used to fill it to the brim with maps, but then I traded them in for a bunch of my seinfeld episodes, and now I only download maps as needed (e.g. using "Download Along Route" when I'm going on a trip).

kutibah 2006-09-03 17:36

I haven't been on these forums for a while, so I still have the old version of my 770 and MaemoMapper. I'll be upgrading soon, but I was just wondering if it's possible to some how modify the routes that MaemoMapper gives you?

cjackiewicz 2006-09-04 20:21

Hello,

can someone test a new version poi for mm? Changes:
- fix locale problem ("," as decimal separator)
- new option: Edit poi, for editing label, description, category and delete

Download: http://eko.one.pl/files/n770/maemo-m...i/maemo-mapper

--
Cezary

lbattraw 2006-09-05 00:48

Quote:

Originally Posted by cjackiewicz
Hello,

can someone test a new version poi for mm? Changes:
- fix locale problem ("," as decimal separator)
- new option: Edit poi, for editing label, description, category and delete
Cezary

Hi, I was able to try it on Sardine but it only gave a segfault. On standard IT2006 it works well, although I would suggest adding a slightly larger "fuzz factor" when selecting a POI to edit/delete so you don't have to be so exact in your aim. It would be difficult to select points in a moving car for example. Turning the selected POI red or another color so you are sure which one you are working with would also be nice.
Good work!

Larry

cjackiewicz 2006-09-05 05:09

Quote:

Originally Posted by lbattraw
On standard IT2006 it works well, although I would suggest adding a slightly larger "fuzz factor" when selecting a POI to edit/delete so you don't have to be so exact in your aim. It would be difficult to select points in a moving car for example.

I found better metod handling selecting point. Need some test; I'll publish solution in this week. Thanks.

--
Cezary

thomashp 2006-09-08 05:11

I'm getting some bad output from your web service that is not allowing maemo mapper to download routes.

If you look at the very end of this gpx output the <desc> contains alot of garbage that causes maemo mapper to give the error "Error Parsing GPX file."
http://gnuite.com:8080/cgi-bin/gpx.c...er%20elk,%20nc

When i remove the gargabe and upload the file to my 770 it works great. There seems to be a parsing error in your web service.

Thanks.

cjackiewicz 2006-09-08 21:09

1 Attachment(s)
Next small step: directions & altitude.

--
Cezary

tdmajic 2006-09-08 21:33

this is may sound pretty dumb, yet I have to ask. Do you have to be online to retreive maps from the flash memory? Also can dn load let's say Chicago in all the zoom levels & save them to a memory card & retreive them w/out being online to see all the zoom levels? thanks


All times are GMT. The time now is 21:18.

vBulletin® Version 3.8.8