[asterisk-users] OpenVox G400P SMS messages character set issues

A J Stiles asterisk_list at earthshod.co.uk
Fri Aug 17 04:29:13 CDT 2012


I have just installed one of these cards with the intention of using it to 
send text messages.

O2 and Vodafone PAYG SIM cards worked fine  (couldn't make calls or send texts 
before putting on some credit, obviously).  Orange and Virgin PAYG SIMs keep 
showing "Network status: Not Registered".  I have not added any credit to 
these SIMs for fear of it still not working  ()

I can't get "smsq" working.  However, I can send an SMS message using the "gsm 
send sms" command in CLI, and so by using something like

# asterisk -rx "gsm send sms 1 0xxxxxxxxxx \"Wibble\""

I can send a message to my own mobile.

However, when doing this, some characters are getting changed in transit!  The 
$ sign gets changed to ¤, the @ sign gets changed to ¡, [\]^_` get changed to 
ÄÖÑܧ̣¿ and {|}~ get changed to äöñü.  (Tried with 2 different phones and two 
different spans on the card, same result each time.) 

This is reminiscent of the old days of dot-matrix printers, where DIP switches 
were used to select a national variant of a 7-bit ASCII charset.  (Though, I'm 
not sure what country speaks such a mixture of Spanish and German .....)

Should I be looking for a setting somewhere to change the charset?

Or should I be thinking in terms of encoding the message as PDU, and sending 
the charset with the binary coded message?


On a separate note, I managed to get SMS reception working nicely by 
configuring an extension "sms" in the [from-gsm] context of my dialplan; this 
gets called, with channel variables ${SMSTXT} and ${SMSSRC} defined, whenever 
an SMS message arrives.

; ========== 8< ==========
[from-gsm]
...
exten => sms,1,NoOp(Incoming SMS)
exten => sms,2,AGI(sms_to_email.agi,${SMSTXT},${SMSSRC})
exten => sms,3,Hangup()
; ========== >8 ==========

The AGI script simply e-mails the SMS message text and sender's number to me.  


-- 
AJS

Answers come *after* questions.



More information about the asterisk-users mailing list