Page 1 of 1

special characters, again

Posted: Thu Apr 29, 2010 2:19 am
by smoking
Hi Alt,

How to send special chars like "^{}\[~]|" with the library?

I used testing string "$&,+/:;=?@<>-()#%{}|\^[]'~"
I tried Default, Latin1, OctetUnspecified encodings.

Default and Latin1 both cannot show "{}\|[]~".
While with OctetUnspecified encoding, I cannot open the message on my Nokia e71. Gave me error "Unable to open. Message format not supported." on the phone. But the characters did all show up correctly in the message preview of the Inbox. Just cannot open it.

I also used SmppClient.MapEncoding(DataCodings.Default, Encoding.Default) , and this allowed me to send "@","$"... using default encoding.
And I also searched the forum, tried GmsEncoding method found here http://www.inetlab.ru/support/viewtopic.php?t=626, and tried to set encoding as ASCII or Default, still not working.

And your answer here http://www.inetlab.ru/support/viewtopic.php?t=611 - Real SMPP client never use GSM coding. Conversion to GSM is performed only on SMSC side. - Which also suggest that we don't have to use previous GsmEncoding method during sending.

Run out of ideas. Please advise.

my send message code snippet:

Code: Select all

if (coding == DataCodings.Default)
{                
               //mapEncoding, allow default encoding shows "@" char
               SmppClient.MapEncoding(DataCodings.Default, Encoding.Default);                
}
           

List<SubmitSm> req = this.SmppClient.PrepareSubmit(
                                mode,
                                srcTon,
                                srcNpi,
                                srcAddr,
                                destTon,
                                destNpi,
                                destAddr,
                                coding,
                                smsMessage);

this.SmppClient.SubmitAsync(req);
Thanks.

K

Posted: Thu Apr 29, 2010 9:03 am
by alt
Hi

First of all please ask SMSC side in what encoding they are expecting SMS message for data_coding Default.

Different SMSC have different configurations.

alt

Posted: Thu Apr 29, 2010 9:49 pm
by smoking
Thanks for your reply.

The SMSC said they are using encoding 4 - which I believe is OctetUnspecified.
I tried this encoding, however I cannot open such message when I receive it.

K

Posted: Mon May 03, 2010 1:03 am
by smoking
Any idea, anyone?

How come I cannot open the message that I sent with encoding OctetUnspecified?

Really stuck here. Please help.

Posted: Mon May 03, 2010 3:53 pm
by alt
Can you open message when you send SMS with DataCodings.UCS2?

Posted: Mon May 03, 2010 9:30 pm
by smoking
Yes. I can open message with UCS2 encoding.
And all the special chars show up in UCS2.

But I cannot send every message in this encoding. Which limits message length to 70 characters.

Posted: Fri May 07, 2010 12:47 am
by smoking
Did somebody have same problem?
Have someone tried to use other encoding?

Please help.
K

Posted: Mon May 10, 2010 6:18 pm
by alt
Do you know vendor type of SMSC ?

All symbols "{}\|[]~" are belong to extension table of GSM encoding.
http://www.dreamfabric.com/sms/default_alphabet.html

Possible SMSC doesn't properly convert your messages to packed GSM 03.38 encoding.

Please also try to send with GSM encoding in data coding = 4

SmppClient.MapEncoding(DataCodings.OctetUnspecified , new GSMEncoding());


Did you try to receive these symbols on another mobile phone?

Posted: Wed May 12, 2010 4:59 am
by smoking
Hi,


I tried this method,

SmppClient.MapEncoding(DataCodings.OctetUnspecified , new GSMEncoding());

It gives me some square marks in the message.
And doesn't show @ and $ etc anymore.

K

Posted: Wed May 12, 2010 7:30 am
by alt
Could you tell results for cases
1) SmppClient.MapEncoding(DataCodings.Default , new GSMEncoding());
2) SmppClient.MapEncoding(DataCodings.Default , Encoding.Default);
3) SmppClient.MapEncoding(DataCodings.ASCII , new GSMEncoding());
4) SmppClient.MapEncoding(DataCodings.ASCII , Encoding.Default)
5) SmppClient.MapEncoding(DataCodings.Latin1 , new GSMEncoding());
6) SmppClient.MapEncoding(DataCodings.Latin1 , Encoding.Default)
7) SmppClient.MapEncoding(DataCodings.OctetUnspecified , new GSMEncoding());
8) SmppClient.MapEncoding(DataCodings.OctetUnspecified , Encoding.Default)

Posted: Mon May 17, 2010 11:57 pm
by smoking
Hi Alt,

I tried several different phones and another network provider(smsc).
It seems some phones cannot show "{}\|[]~". But some do. with default encoding. - SmppClient.MapEncoding(DataCodings.Default , Encoding.Default); while SmppClient.MapEncoding(DataCodings.Default , new GSMEncoding()) doesn't work, it cannot show $@ etc.

And when using SmppClient.MapEncoding(DataCodings.OctetUnspecified , Encoding.Default), some phone cannot open it, but if it does, it shows every character.

I also tried other methods you suggested, same results as default encoding.

I'm stick with SmppClient.MapEncoding(DataCodings.Default , Encoding.Default) for now. And also sent an email to the smsc to ask if they have any idea why the message cannot open.

Thanks,

K