Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
F
freeswitch
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
张华
freeswitch
Commits
8a1508d6
提交
8a1508d6
authored
5月 13, 2012
作者:
Giovanni Maruzzelli
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
gsmopen: correctly receives SMSs in GSM7 and UCS2
上级
eb93a14e
显示空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
7 行增加
和
5 行删除
+7
-5
gsmopen_protocol.cpp
src/mod/endpoints/mod_gsmopen/gsmopen_protocol.cpp
+7
-5
没有找到文件。
src/mod/endpoints/mod_gsmopen/gsmopen_protocol.cpp
浏览文件 @
8a1508d6
...
...
@@ -1180,10 +1180,12 @@ int gsmopen_serial_read_AT(private_t *tech_pvt, int look_for_ack, int timeout_us
if
(
res
)
{
ERRORA
(
"AT+CMGR (read SMS) do not got OK from the phone, message sent was:|||%s|||
\n
"
,
GSMOPEN_P_LOG
,
at_command
);
}
res
=
gsmopen_serial_write_AT_ack
(
tech_pvt
,
"AT+CSCS=
\"
GSM
\"
"
);
/*
res = gsmopen_serial_write_AT_ack(tech_pvt, "AT+CSCS=\"CIAPALO1\"");
if (res) {
ERRORA
(
"AT+CSCS=
\"
GSM
\"
(set TE messages to GSM) do not got OK from the phone
\n
"
,
GSMOPEN_P_LOG
);
ERRORA("AT+CSCS=\"
CIAPALO1
\" (set TE messages to GSM) do not got OK from the phone\n", GSMOPEN_P_LOG);
}
*/
memset
(
at_command
,
0
,
sizeof
(
at_command
));
sprintf
(
at_command
,
"AT+CMGD=%d"
,
tech_pvt
->
unread_sms_msg_id
);
/* delete the message */
tech_pvt
->
unread_sms_msg_id
=
0
;
...
...
@@ -2399,7 +2401,7 @@ int utf8_to_iso_8859_1(private_t *tech_pvt, char *utf8_in, size_t inbytesleft, c
iconv_res
=
iconv
(
iconv_format
,
&
inbuf
,
&
inbytesleft
,
&
outbuf
,
&
outbytesleft
);
#endif // WIN32
if
(
iconv_res
==
(
size_t
)
-
1
)
{
ERRORA
(
"
error: %s %d
\n
"
,
GSMOPEN_P_LOG
,
strerror
(
errno
),
errno
);
DEBUGA_GSMOPEN
(
"cannot translate in iso_8859_1
error: %s %d
\n
"
,
GSMOPEN_P_LOG
,
strerror
(
errno
),
errno
);
return
-
1
;
}
DEBUGA_GSMOPEN
...
...
@@ -3038,9 +3040,9 @@ int gsmopen_serial_getstatus_AT(private_t *tech_pvt)
if
(
res
)
{
ERRORA
(
"AT+CMGR (read SMS) do not got OK from the phone, message sent was:|||%s|||
\n
"
,
GSMOPEN_P_LOG
,
at_command
);
}
res
=
gsmopen_serial_write_AT_ack
(
p
,
"AT+CSCS=
\"
GSM
\"
"
);
res
=
gsmopen_serial_write_AT_ack
(
p
,
"AT+CSCS=
\"
CIAPALO2
\"
"
);
if
(
res
)
{
ERRORA
(
"AT+CSCS=
\"
GSM
\"
(set TE messages to GSM) do not got OK from the phone
\n
"
,
GSMOPEN_P_LOG
);
ERRORA
(
"AT+CSCS=
\"
CIAPALO2
\"
(set TE messages to GSM) do not got OK from the phone
\n
"
,
GSMOPEN_P_LOG
);
}
memset
(
at_command
,
0
,
sizeof
(
at_command
));
sprintf
(
at_command
,
"AT+CMGD=%d"
,
p
->
unread_sms_msg_id
);
/* delete the message */
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论