PDA

View Full Version : Tiles not showing...



MIB.42
February 8th, 2007, 06:38
Deniska, I got my GPSlim240, made my own cable, everything works great.

However, there are times in MapViewer, when all starts out OK, I zoom in, works fine, but when I zoom out, there is no map, just the grid. No error message or anything. And from that moment, it doesn't matter if I zoom in or out, it just won't display the map tiles, just the grid.

Since I don't have the source code to compile/test, my hunch is that there might be some memory alloc/free problem?

deniska
February 9th, 2007, 05:39
yep, my guess is the cach_mngr thread dies, probably due to lack of free memory...
Do you run any FW plugins? - if so I'd try to disable them for now...
I am curently trying to trim memory usage a bit...
Also, check if your memory stick is not currupted - you may want to try to format it and create a new map...

MIB.42
February 9th, 2007, 06:11
yep, my guess is the cach_mngr thread dies, probably due to lack of free memory...
Do you run any FW plugins? - if so I'd try to disable them for now...
I am curently trying to trim memory usage a bit...
Also, check if your memory stick is not currupted - you may want to try to format it and create a new map...

No extra fw plugs, clean 3.03OE-B. Memstick is OK.

It's "OK" if the cache manager dies, I just would like to know about it, maybe some error message if you can catch it...

btw, I finally found the source for 0.4.60 on page 16, so I am looking at it now...
First observation :

- If the user specifies a default map, it gets loaded nicely (from main.cpp main() ), and gpsOn=1; gets assigned. However, the rest does not get initialized the same way if you press SQUARE ( like the sceRtcGetCurrentTick(&triptime); )...
So, if I may suggest, either we should add a new variable which you include in the line :
if ((cpad.Buttons & PSP_CTRL_SQUARE) && timer>10) {
so it looks something like this :
if (((startupmaploaded)||(cpad.Buttons & PSP_CTRL_SQUARE)) && timer>10) { startupmaploaded=0; etc.
and if there is default map, don't init gps, just set startupmaploaded=1;

or simply fill in the appropriate inits in the readmaplistings...if (strcmp(options[i],startupmap)==0) {
...


On top of these, I added an 'n-pass' locate_address for geo lookup, which is more flexible on the name comparisons, thus returns more results for the address lookup. Pretty simple really, wrote an other strncmp which checks partials... I also moved the locate_address function out to a new file for better maintainance... Once I test it plenty, I will post it for your review...


Thx

BTW, I showed your app today to a couple of engineers and they were most impressed... Good Job! You make a good argument FOR homebrew...

MIB.42
February 19th, 2007, 07:11
Deniska,

Any comments on the above?

- I also added screenshot feature ( I am sure you had it somewhere ), very useful...

if ((cpad.Buttons & PSP_CTRL_CIRCLE) && timer>10) {
char filename2[128];
beep();
timer=0;
sprintf(filename2,"Lat_%8.4f__Lon_%8.4f__%dft.png",c.lat,c.lon,(int)(altitude*altfix));
savePngImage(filename2,getVramDisplayBuffer(),SCRE EN_WIDTH,SCREEN_HEIGHT,PSP_LINE_SIZE,0);
}

- Also, would you mind sharing your latest src with png and jpg lib? Email me at [email protected]

Cheers.

MIB.42
February 20th, 2007, 22:19
Deniska,

In utils.cpp, gpsfsOpen(char *dirname) function I believe there might be a small bug:

When you open the individual zoom GPSFS files, you are checking for file failure on gpsfsfp[0]==NULL only, instead of gpsfsfp[i] ... ( last 'for' loop )

Any email address where I can address these and possible improvements in the future ?

Thanks.

deniska
February 23rd, 2007, 22:18
Below is the latest source code for the generic gps version..
all the required libs can be acquired from ps2dev.org svn repository...

MIB.42
February 24th, 2007, 10:22
Below is the latest source code for the generic gps version..
all the required libs can be acquired from ps2dev.org svn repository...

Thanks, I do have the png and jpg libs ( downloaded latest sources and compiled them ), I just wanted to have the same libs what you use. Never mind...

I started a new thread on code contribution as this thread is probably not relevant to what I/we are trying to do...

Regards, MIB.42