[asterisk-users] Sending SMS and SIM card
Frank Vanoni
mailinglist at linuxista.com
Sat Apr 27 06:35:51 CDT 2019
On Fri, 2019-04-26 at 14:39 +0000, bilal ghayyad wrote:
> Any small example how to send gsm calls through chan_dognle and how
> to send sms through chan_dongle?
In dongle.conf:
[gsmgateway]
context=gsm
imei=123456789012345
imsi=098765432112345
In extensions.conf:
[gsm]
; Incoming calls from GSM/3G
exten => +41776665544,1,Dial(Local/mydeskphone at voipphone)
same => n,Hangup()
; Phone call though GSM/3G
exten => _0.,n,Dial(Dongle/gsmgateway/${EXTEN},120)
same => n,Hangup()
; Incoming SMS to mail address and to sms.txt file
exten => sms,1,Noop(Incoming SMS from ${CALLERID(num)}
${BASE64_DECODE(${SMS_BASE64})})
exten => sms,n,System(echo '${STRFTIME(${EPOCH},,%Y-%m-%d %H:%M:%S)} -
${DONGLENAME} - ${CALLERID(num)}: ${BASE64_DECODE(${SMS_BASE64})}' >>
/var/log/asterisk/sms.txt)
exten => sms,n,System(echo "${STRFTIME(${EPOCH},,%Y-%m-%d %H:%M:%S)} -
${DONGLENAME} - ${CALLERID(num)}: ${BASE64_DECODE(${SMS_BASE64})}" |
mail -s "SMS from ${CALLERID(num)}" myemailaddress at mymailbox.com)
exten => sms,n,Hangup()
More information about the asterisk-users
mailing list