Re: Need help

Andreas Fink <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <[email protected]>
A GSM phone doesnt use WINDOWS-1252 charset but it uses GSM-Charset..

The GSM character set is 7 bit, so you can not have values of 128-159  
in it.
very few characters are coded with an escape sequence.

I think your problem is that if you send binary message, you should  
tell kannel that its binary 8 bit instead of standard 7 bit. Kannel  
will otherwise try to convert. I presume it will try converting from  
ISO (not Windows 1252) to GSM and back. Setting the coding parameter  
to the right value (see users guide) should make it send binary 8 bit  
messages.

On 31.01.2008, at 19:44, Vitaliy Osaulenko wrote:

> Hi,
>
> I have a question. I try send binary message.
>
> byte[] original = {77, 67, 65, 83, 72, 32, 33, 216, 21, 199, 102,  
> 84, 199, 230, 2, 164, 183, 47, 130, 157, 125, 96, 186, 213, 42, 94,  
> 79, 203, 210, 50, 76, 232, 174, 76, 49, 146, 187, 217, 34, 27, 18,  
> 135, 197, 64, 82, 197, 66, 65, 115, 213, 23, 77, 153, 34, 243, 58,  
> 231, 220, 192, 11, 120, 15, 9, 148, 53, 215, 126, 2, 110, 38, 11,  
> 135, 190, 176, 107, 155, 231, 2, 176, 159, 86, 132, 128, 45, 91,  
> 144, 98, 63, 115, 110, 228, 37, 200, 194, 38, 219, 135, 41, 233,  
> 138, 117, 246, 29, 211, 6, 213, 178, 216, 79, 70, 0, 45, 187, 223,  
> 189, 110, 99, 228, 108, 196, 33, 72, 125, 64, 135, 218, 202, 228,  
> 216, 170, 62, 80, 139, 128, 0, 0, 0, 0, 0, 0};
>
> I received from gateway next binary parameter:
>
> MCASH+!%D8%15%C7fT%C7%E6%02%A4%B7%2F%1A%1A%7D%60%BA%D5*%5EO%CB%D22L 
> %E8%AEL1%1A%BB%D9%22%1B%12%1A%C5%40R%C5BAs%D5%17M%1A%22%F3%3A%E7%DC 
> %C0%0Bx%0F%09%1A5%D7~%02n%26%0B%1A%BE%B0k%1A%E7%02%B0%1AV%1A%1A-%5B 
> %1Ab%3Fsn%E4%25%C8%C2%26%DB%1A)%E9%1Au%F6%1D%D3%06%D5%B2%D8OF%00-%BB 
> %DF%BDnc%E4l%C4!H%7D%40%1A%DA%CA%E4%D8%AA%3EP%1A%1A%00%00%00%00%00%00
>
> And then do URL decoding with using WINDOWS-1252 charset:
>
> byte[] data = {77, 67, 65, 83, 72, 32, 33, 216, 21, 199, 102, 84,  
> 199, 230, 2, 164, 183, 47, 26, 26, 125, 96, 186, 213, 42, 94, 79,  
> 203, 210, 50, 76, 232, 174, 76, 49, 26, 187, 217, 34, 27, 18, 26,  
> 197, 64, 82, 197, 66, 65, 115, 213, 23, 77, 26, 34, 243, 58, 231,  
> 220, 192, 11, 120, 15, 9, 26, 53, 215, 126, 2, 110, 38, 11, 26, 190,  
> 176, 107, 26, 231, 2, 176, 26, 86, 26, 26, 45, 91, 26, 98, 63, 115,  
> 110, 228, 37, 200, 194, 38, 219, 26, 41, 233, 26, 117, 246, 29, 211,  
> 6, 213, 178, 216, 79, 70, 0, 45, 187, 223, 189, 110, 99, 228, 108,  
> 196, 33, 72, 125, 64, 26, 218, 202, 228, 216, 170, 62, 80, 26, 26,  
> 0, 0, 0, 0, 0, 0};
>
> The data a bit different. Bytes from 128 to 159 converts to 26. I  
> think range is a bit bigger. But it is not important.
> My question to you. Do I something wrong? Or we lost that bytes when  
> gateway performs converting? May be it happens when gateway tries to  
> convert bytes to unicode/utf-8?
> Could I fix that? Could I change config files or sources?
>
>
> Looking forward hearing from you!
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.