All times are UTC+02:00




Post new topic  Reply to topic  [ 29 posts ]  Go to page Previous 1 2 3 Next
Author Message
 Post subject: Re: Umlauts in RadioText
PostPosted: Fri Dec 28, 2012 8:21 pm 
User avatar

Joined: Fri Mar 16, 2012 11:11 pm
Posts: 19
Location: Stockholm, Sweden
Yes, that is what I do. I'm using Winamp as the player with the Advanced mIRC Integration Plug-In. http://amip.tools-for.net/wiki/manual/amip
Image

The AMIP plug-in can do many different things. I have it writing what's playing to a file and do the RDS character set translation.
Image
Code:
strrep(ü,chr(153),strrep(Ü,chr(217),strrep(É,chr(194),strrep(é,chr(130),strrep(Ö,chr(215),strrep(Ä,chr(209),strrep(Å,chr(225),strrep(ö,chr(151),strrep(ä,chr(145),strrep(å,chr(241),strrep(',chr(39),strrep(á,chr(128),strrep(Á,chr(192),%name)))))))))))))
--
Ragnar


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Fri Dec 28, 2012 10:20 pm 

Joined: Sat Dec 15, 2012 1:47 am
Posts: 42
Location: Some campus radio station, Germany
In a typing spree, I came up with this:

RDS_CHARSET = ur"""€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€€ !"#¤%&'()*+,-./0123456789:,<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]€_€abcdefghijklmnopqrstuvwxyz{|}€€áàéèíìóòúùÑÇŞßİIJâäêëîïôöûüñçşĝıijªα©‰Ğěňȍπ€£$←↑→↓º¹²³±€ńȕµ¿÷°¼½¾§ÁÀÉÈÍÌÓÒÚÙŘČŠŽĐĽÂÄÊËÎÏÔÖÛÜřčšžđŀÃÅÆŒŷÝÕØÞŊŔĆŚŹ€ðãåæœŵýõøþŋŕćśź€€"""

€ means either a) I didnt find the unicode character (because it does not exist, I was too lazy to search, or because I could not decipher it), b) the RDS codetable does not assign a character to that byte.

HTH. Hans, can you maybe include transcoding from UTF-8 into ST and make it optional (backwards compatibility)?


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Fri Dec 28, 2012 10:25 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11425
Quote:
HTH. Hans, can you maybe include transcoding from UTF-8 into ST and make it optional (backwards compatibility)?
Sounds like a VERY useful option, I wanted to propose it yesterday already but I first wanted to wait if it works - I suppose since ragnar.jensen uses it it does. I'll have to dive into character maps first I suppose, since different PC character maps have different symbols at different locations :(


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Fri Dec 28, 2012 10:37 pm 

Joined: Sat Dec 15, 2012 1:47 am
Posts: 42
Location: Some campus radio station, Germany
Quote:
Quote:
HTH. Hans, can you maybe include transcoding from UTF-8 into ST and make it optional (backwards compatibility)?
I'll have to dive into character maps first I suppose, since different PC character maps have different symbols at different locations :(
No, you only need my string from above :) I suggest two or three modes: a) old mode (RDS encoding) b) latin1 input c) UTF-8 input. Your code for mode b would convert the user input to UTF-8 first. Then and in mode c, the string is converted using my string to the RDS encoding.


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Fri Dec 28, 2012 11:02 pm 
User avatar

Joined: Fri Mar 16, 2012 11:11 pm
Posts: 19
Location: Stockholm, Sweden
Quote:
...I wanted to propose it yesterday already but I first wanted to wait if it works - I suppose since ragnar.jensen uses it it does.
Yes, I run this successfully with a small transmitter that is fed a Stereotool-generated MPX signal.

EDIT: Ooops! Not entirely true, I use an external RDS encoder. I'll make a test with the latest beta and without the external encoder tomorrow.

--
Ragnar


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Sat Dec 29, 2012 4:26 pm 
User avatar

Joined: Fri Mar 16, 2012 11:11 pm
Posts: 19
Location: Stockholm, Sweden
Tests are done. Umlauts seem to get through OK, but there are issues. Characters just before an umlaut are sometimes shifted down one ASCII code, but not always.

Test 1: Audio file is tagged with Artist: Nürnberg åäöÅÄÖ Title: Sämre
Tags are displayed OK in Winamp
Image

The file written by AMIP in the RDS character set, viewed in Notepad. It looks OK, it is supposed to look like this.
Image

Same file in a Hex editor, looks OK.
Image

Stereotool does not display the umlauts.
Image

What it looks like in a radio display.
Image
Characters before an umlaut are changed. N has become M, the space before å is now A with cedilla, S has become R.

Test 2:Audio file is tagged with Artist: Nü MÜSÉk Title: Räksmörgås
Tags are displayed OK in Winamp
Image

The file written by AMIP in the RDS character set, viewed in Notepad. It looks OK, it is supposed to look like this.
Image

Same file in a Hex editor, looks OK.
Image

Stereotool does not display the umlauts.
Image

What it looks like in a radio display.
Image
N in has become M. The R before ä in Räksmörgås has actually survived, but the g is now an f.

Test 3: Audio file is tagged with Artist: Räksmörgås Title: Nü MÜSÉk; Same as Test 2 but Artist and Title tags are swapped and a semicolon added to Title.
Tags are displayed OK in Winamp
Image

The file written by AMIP in the RDS character set, viewed in Notepad. It looks OK, it is supposed to look like this.
Image

Same file in a Hex editor, looks OK.
Image

Stereotool does not display the umlauts.
Image

What it looks like in a radio display.
Image
Some characters before umlauts are shifted one character code down. Although the words are the same as in test 2, the changes are not the same.

The results are consistent between different runs of the same test case.
I have tested with several different RDS receivers and they all show the same in their displays.

--
Ragnar


Attachments:
File comment: Text files in RDS char set created by AMIP
rdstests.zip [596 Bytes]
Downloaded 444 times
Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Sat Dec 29, 2012 4:38 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11425
Ah! The characters that are changing are at odd places (1, 3, 5, ...) - which makes sense because in RDS always 2 characters are encoded together. So I think I have a type error (signed vs. unsigned char).

I'm building a fix now.


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Sun Dec 30, 2012 1:37 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11425
The latest version in the News section should fix the issue with changed characters before umlauts now.


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Sun Dec 30, 2012 4:07 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11425
Here's the RDS default character set (there are others for Greek characters etc.). My question: The spec mentions that some cheap receivers can only display the characters inside the thick black line. What happens if you send lower case (I suppose they get converted?) - but also: What happens if you send special characters with umlauts etc? Are they replaced by the same character without umlaut, or completely left out?

Where I live there are no stations that broadcast weird characters in their RDS texts, you may have more experience with this ;)

Image


Top
   
 Post subject: Re: Umlauts in RadioText
PostPosted: Sun Dec 30, 2012 4:38 pm 

Joined: Sat Dec 15, 2012 1:47 am
Posts: 42
Location: Some campus radio station, Germany
Quote:
Here's the RDS default character set (there are others for Greek characters etc.). My question: The spec mentions that some cheap receivers can only display the characters inside the thick black line. What happens if you send lower case (I suppose they get converted?) - but also: What happens if you send special characters with umlauts etc? Are they replaced by the same character without umlaut, or completely left out?
Lower case might vanish as well (blank chars).
I think special unsupported will appear as blank chars instead. But I think this refers mainly to the PS name. Devices that support RadioText should support most of the charset.
Quote:
(Some Image)
Yes, thats what I typed above in my string.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 29 posts ]  Go to page Previous 1 2 3 Next

All times are UTC+02:00


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited