Re: [mkgmap-dev] Encoding problems

2011-03-11 Thread Rich
On 03/09/11 22:58, Johann Gail wrote:

 Am 09.03.2011 16:10, schrieb Rich:
 On 03/09/11 17:00, Marko Mäkelä wrote:
 On Wed, Mar 09, 2011 at 04:02:38PM +0200, Rich wrote:
 so it might be that the file has properly encoded characters, but the
 device does not properly display them ?
 That is a possibility. Do the older Garmins (such as GPSMap 60 and Edge
 605/705) support anything else than the ISO 8859-1 like CP1252? I think
 that I saw some hacked Russian firmware somewhere, with some 8-bit
 Cyrillic encoding support, I suppose.
 no idea about older ones, but this specimen is etrex vista hcx

 Do you have a garmin map, which shows the characters as expected? This
 will prove that the device could display the chars at least.

nope, default garmin map was quite a joke.
i submitted a question at garmin techsupport.
-- 
  Rich
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Rich
On 03/07/11 19:49, Tomas Straupis wrote:
 2011-03-07 Steve Ratcliffe:
 Is that using code-page or charset?

 I would not expect --charset to work.

Yep. Changing to
--code-page=1257
fixes Lithuanian letters!

hmm. i might be doing something wrong... but --code-page=1257 with 
mkgmap 1867 still results in garbled latvian characters.

in which revision/version does it work for you ?
what else could i be doing incorrectly ?

full options to the jar are :

--mapname=13131313 --description=Latvia-2011.03.06 --country-name=Latvia 
--country-abbr=LV --code-page=1257 --net --route latvia-2011.03.06.osm

Thank you!
-- 
  Rich
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Marko Mäkelä
On Wed, Mar 09, 2011 at 01:45:02PM +0200, Rich wrote:
Yep. Changing to
--code-page=1257
fixes Lithuanian letters!

hmm. i might be doing something wrong... but --code-page=1257 with
mkgmap 1867 still results in garbled latvian characters.

Do you have an example? Can you check the file with a hex editor. For 
example, if you have a string Test*#% that shows up as Test/!, search 
for Test in the img file and show the hexdump. Also, what encoding is 
the input in? UTF-8 like XML? What chars should they be?

You might find the GNU Recode tool useful when diagnosing character set 
translation problems. For example, if your terminal emulator is 
configured to use the UTF-8 encoding, the following should encode your 
input properly, or complain if it cannot be done:

echo 'your utf-8 string'|recode utf8..cp1257|od -t x1

Best regards,

Marko
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Rich
On 03/09/11 14:26, Marko Mäkelä wrote:
 On Wed, Mar 09, 2011 at 01:45:02PM +0200, Rich wrote:
 Yep. Changing to
 --code-page=1257
 fixes Lithuanian letters!

 hmm. i might be doing something wrong... but --code-page=1257 with
 mkgmap 1867 still results in garbled latvian characters.

 Do you have an example? Can you check the file with a hex editor. For
 example, if you have a string Test*#% that shows up as Test/!, search
 for Test in the img file and show the hexdump. Also, what encoding is

Ū - DB
Ā - C2
Ņ - D2
Ļ - CF
Ž - DE

 the input in? UTF-8 like XML? What chars should they be?

it's an osm xml from geofabrik downloads, so i'd expect it to be proper 
utf8 :)

 You might find the GNU Recode tool useful when diagnosing character set
 translation problems. For example, if your terminal emulator is
 configured to use the UTF-8 encoding, the following should encode your
 input properly, or complain if it cannot be done:

 echo 'your utf-8 string'|recode utf8..cp1257|od -t x1

  echo 'Ž'|recode utf8..cp1257|od -t x1
000 de 0d 0a
003

so it might be that the file has properly encoded characters, but the 
device does not properly display them ?
if i manually compare what they look like on the gps device and 
onscreen, result on gps device seems to match what i get if i look at 
cp1257 (or iso-8859-13) encoded text in a unicode terminal...

 Best regards,

   Marko
-- 
  Rich
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Marko Mäkelä
On Wed, Mar 09, 2011 at 04:02:38PM +0200, Rich wrote:
so it might be that the file has properly encoded characters, but the 
device does not properly display them ?

That is a possibility. Do the older Garmins (such as GPSMap 60 and Edge 
605/705) support anything else than the ISO 8859-1 like CP1252? I think 
that I saw some hacked Russian firmware somewhere, with some 8-bit 
Cyrillic encoding support, I suppose.

if i manually compare what they look like on the gps device and 
onscreen, result on gps device seems to match what i get if i look at 
cp1257 (or iso-8859-13) encoded text in a unicode terminal...

Do you mean UTF-8 interpreted as if it were cp1257 (multiple characters 
per non-ASCII character)? Anything non-UTF-8, non-ASCII interpreted as 
UTF-8 should show as � (U+FFFD).

echo -e '\xdb\xc2\xd2\xcf\xde\r'|recode cp1257..utf8
ŪĀŅĻŽ
echo -e '\xdb\xc2\xd2\xcf\xde\r'|recode cp1252..utf8
ÛÂÒÏÞ

The former interprets the codes as CP1257 and the latter as CP1252. Did 
you see the latter on your GPS?

Marko
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Rich
On 03/09/11 17:00, Marko Mäkelä wrote:
 On Wed, Mar 09, 2011 at 04:02:38PM +0200, Rich wrote:
 so it might be that the file has properly encoded characters, but the
 device does not properly display them ?

 That is a possibility. Do the older Garmins (such as GPSMap 60 and Edge
 605/705) support anything else than the ISO 8859-1 like CP1252? I think
 that I saw some hacked Russian firmware somewhere, with some 8-bit
 Cyrillic encoding support, I suppose.

no idea about older ones, but this specimen is etrex vista hcx

 if i manually compare what they look like on the gps device and
 onscreen, result on gps device seems to match what i get if i look at
 cp1257 (or iso-8859-13) encoded text in a unicode terminal...

 Do you mean UTF-8 interpreted as if it were cp1257 (multiple characters
 per non-ASCII character)? Anything non-UTF-8, non-ASCII interpreted as
 UTF-8 should show as � (U+FFFD).

 echo -e '\xdb\xc2\xd2\xcf\xde\r'|recode cp1257..utf8
 ŪĀŅĻŽ
 echo -e '\xdb\xc2\xd2\xcf\xde\r'|recode cp1252..utf8
 ÛÂÒÏÞ

 The former interprets the codes as CP1257 and the latter as CP1252. Did
 you see the latter on your GPS?

the latter seems like what i'm seeing on the device with --codepage=cp-1257

   Marko
-- 
  Rich
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Tomas Straupis
I've tried downloading Latvian extract from geofabrik and creating a map.
I then browsed through Riga and haven't noticed any problems (using
Colorado). I do see Latvian letters properly...

P.S. Note that Lithuanian letters (and the same should apply to
Latvian ones) does NOT work on GPSMAP 60csx, eTrex Vista HCx and it
DOES work with Colorado, Oregon, MobileXT 5.00(60), Nuvi 250w.

-- 
Tomas Straupis
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Rich
On 03/09/11 18:31, Tomas Straupis wrote:
 I've tried downloading Latvian extract from geofabrik and creating a map.
 I then browsed through Riga and haven't noticed any problems (using
 Colorado). I do see Latvian letters properly...

 P.S. Note that Lithuanian letters (and the same should apply to
 Latvian ones) does NOT work on GPSMAP 60csx, eTrex Vista HCx and it

i... don't like vista hcx being mentioned in that list :)
do you have any source for this info ?

 DOES work with Colorado, Oregon, MobileXT 5.00(60), Nuvi 250w.
-- 
  Rich
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Tomas Straupis
2011-03-09 Rich:
 i... don't like vista hcx being mentioned in that list :)
 do you have any source for this info ?

  I've placed a map on the internet and asked people to send me an
e-mail telling if they see Lithuanian letters or not. That is the
source of above-mentioned information...

-- 
Tomas Straupis
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-09 Thread Johann Gail


Am 09.03.2011 16:10, schrieb Rich:
 On 03/09/11 17:00, Marko Mäkelä wrote:
 On Wed, Mar 09, 2011 at 04:02:38PM +0200, Rich wrote:
 so it might be that the file has properly encoded characters, but the
 device does not properly display them ?
 That is a possibility. Do the older Garmins (such as GPSMap 60 and Edge
 605/705) support anything else than the ISO 8859-1 like CP1252? I think
 that I saw some hacked Russian firmware somewhere, with some 8-bit
 Cyrillic encoding support, I suppose.
 no idea about older ones, but this specimen is etrex vista hcx

Do you have a garmin map, which shows the characters as expected? This 
will prove that the device could display the chars at least.
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] Encoding problems

2011-03-07 Thread Steve Ratcliffe

 I expect the latest version to work, but if it doesn't...

  charsets stopped working (at least for cp1257) after index branch
merge. It used to work for at least half a year before that (on stable
versions).

-- 
Tomas Straupis
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Is that using code-page or charset?

I would not expect --charset to work.
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] Encoding problems

2011-03-07 Thread Tomas Straupis
2011-03-07 Steve Ratcliffe:
 Is that using code-page or charset?

 I would not expect --charset to work.

  Yep. Changing to
  --code-page=1257
  fixes Lithuanian letters!

  Thank you!

-- 
Tomas Straupis
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev