Editing the Nav Stored Locations via SD Card

My Nissan Leaf Forum

Help Support My Nissan Leaf Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

EVNation

Well-known member
Joined
Aug 31, 2010
Messages
162
Location
Redondo Beach, CA
I was looking for a way to upload charging stations from my app direct to the nav system.

I found that you can export the NAV data to SD card. The data is saved in three files.

1. Home location : homelocation.hlc
2. Stored location: storedlocation.slc
3. stsfile : unknown what that is though it just has some hex code followed by exp_fin in ascii.

Looking at the location files, they are a 256 byte hex block followed by ascii comma separated numbers. The first numbers are the Lat/Lon coords for the location. The rest of it will need to be decoded.

Anyone know if this is a standard format that there are existing editors for? I couldn't find anything.

If not, I will start decoding it by making changes to the settings and see what comes up.

If you are interested in helping with this, you will need an SD card and the ability to load that file on a PC. DM me if you would like to participate. I will publish any info I determine or any utilities I make.
 
Look for the old nav thread. I've the nav supplier info there. Then you can search for their format info.
 
Thanks,

It does seem like it is NavTech. I signed up for their dev access but they have a ton of different formats for their data and I didn't immediately see something that matches. They mention on their forum that the car makers customize the formats for storage. It looks like it is POI data. There are also code types for the type of point. So I may be able to decode more from those docs. But for now, much faster progress was made by just looking at the data.

For those interested. After the 256 byte block (which I need more saves to decode), an entry looks like this:


34.009722,-118.489722,0,00,00,00,4D41494E20535400,00,-1719627072,672,982,,,,,0,0,-1,0,1,44,0,-1,3000,-1,4294967295,65535,65535

First two columns are lat/lon pair. Column 7 is obviously a hex string and it turned out to be the obvious thing. It is ASCII for the location name. In this case "MAIN ST.". The "44" may be code for a charge site. On my data, it is 44 for charge stations and 0 for home location. But I need more data. 3000 matches the code format for NAVTECH POI but couldn't find what that code meant. All my points are 3000. 4294967295 is consistent for my points also so could be a UID for me. The three numbers in the middle vary (all others match):

Here is the variation on the three middle numbers.
-1719561536 1027 479

-1719627072 672 982

-1722576175 976 1217

-1722576189 1109 604

-1721527600 202 340

A few more datapoints to decode the initial block and I will start writing my own files.
 
I am very close now. I successfully created a file with new locations. Gave them names, set the type to Charge Location. I then uploaded my created file to the car. However, the location is off.

It appears that the number variation describes where in map space the location is. So somehow:

-1719627072,672,982

corresponds to:
34.009722,-118.489722

It is likely in their map data coordinate format somehow.

Anyone know anything further about these kind of Nav coordinates? If I can solve that, it will be easy to make a address book editor.
 
First I assume you mean NAVTEQ not Navtech?

I looked and didn't see anything immediately useful.. but http://faculty.unlv.edu/jensen/gisdata/navteq/

I started adding info here to the wiki..
http://www.leafic.com/wiki/index.php/Navigation_System
 
EVNation said:
Anyone know anything further about these kind of Nav coordinates? If I can solve that, it will be easy to make a address book editor.
I don't know anything, but if the NAV system coordinates are linear functions of the Lat and Lon, you just need two data points to figure out the relationship. You've already posted one data point, so get another, find the linear equations, and check them against a third data point.

Cheers, Wayne
 
Thanks Wayne,

I was hoping it was just a linear scale issue. That would be easy since I have done that for GPS before. But in this case, it seems three numbers are varying. Which makes it very hard. And I don't see a pattern. I suspect it is a quadrant or page number the 2D coords on that page. Here are the 6 datapoints I have:


34.025556 -118.484167 = -1719561536 1027 479
34.009722 -118.489722 = -1719627072 672 982
33.824722 -118.328611 = -1722576175 976 1217
33.818611 -118.389167 = -1722576189 1109 604
33.899167 -118.371667 = -1721527600 202 340
33.902778 -118.386389 = -1721527613 1292 701

Of course some of those numbers could be unrelated to location. What I plan to do next is manually load up some fixed locations, and see where they end up.

Puzzling...
 
Fortunately, you have something of an "oracle" there in the car, so you can just take the existing file, cut and paste the entries, and try tweaking them from the least significant to most significant bits to see how far they move when it reads them back. Make 1000 of them named after the values, and something interesting should show up.

But maybe that's just what you meant by "manually load up some fixed locations". :)
 
EVNation said:
I was hoping it was just a linear scale issue. That would be easy since I have done that for GPS before. But in this case, it seems three numbers are varying.
Well, if I have understood properly how to use OOCalc's LINEST function, then for the 6 datapoints you gave, the LAT and LON are not linear combinations of the other three numbers. At least the reported standard deviation was non-zero, so there was some dispersion.

Cheers, Wayne
 
An update on this. I believe I have figured the format out. I have succeeded in creating data points using my data and imported them to the car.

I need to do more testing on more regions to ensure it is valid across areas, but it looks good. Once I have finalized it, I will release some sample data for others to validate and the format details.

Though I never like to comment on others systems since I don't know the working parameters, it sure seems needlessly obtuse without being deliberately obfuscated...
 
Yes. I believe I have good news on this. But I need another Leaf to make sure the data is not car specific. I should be able to do this on Saturday at the Irwindale EV Rally event. Then I will report in more.

Then next steps will be automating a system where we can create datasets for different regions on SD cards. You can upload up to 100 custom data points, so will need a way to select what you want.
 
100, possibly even 1000, "points" will not be enough to hold just the charging locations in San Diego and LA areas.

When CARWINGS downloads "nearby" charge-stations, does it overwrite the previous file?
 
I am not totally sure on that yet. The docs mention that you are limited to 200 locations in one place and 100 in another. Actually re-reading, it looks like 200 for stored in address book.

I believe where you do the search by contacting Carwings, it pulls down closest into temporary memory. But to save that off you would need to use one of your 200 slots.

That is why I believe I will need to have a way to select what areas you want to load then download to SD file. In an ideal world we figure out a way to transmit data to the car just like carwings and can provide them dynamically. That is way down the line though.
 
garygid said:
What is the capacity and speed (class) of the Nav SD card?

I am just using one out of my camera. It is 1GB. You can use whatever you want to store the locations onto. It goes in the second SD slot. The built in nav data is on the first SD. I pulled it out to look once but didn't look at the size.
 
Looking for useful files on the Nav-SD might be instructive?

Is it read-only, or do files get written or updated there?

Can one make a backup copy that will work, and then experiment with that?
 
garygid said:
Looking for useful files on the Nav-SD might be instructive?

Is it read-only, or do files get written or updated there?

Can one make a backup copy that will work, and then experiment with that?

The Card is labeled:
NISSAN SD MAP DATA
10-11Y - 1
US / CANADA

No marking of size. Not locked so "Read/Write" I bet it stores downloaded info there.
But can't be read by my SD card reader on PC so it is in some proprietary format I would guess that is not user readable.
So no backup without some tools. I could be a NavTeq format that is known but likely a Hitachi system format.
 
Back
Top