“错误:电话报告通用通信错误或语法错误. (GsmComm.GsmCommunication.CommException)".有什么问题 ? [英] "Error: Phone reports generic communication error or syntax error. (GsmComm.GsmCommunication.CommException)" what's the problem ?
问题描述
大家好,
我正在使用gsmComm库检查示例代码,我的调制解调器是诺基亚5130 Xpressmusic调制解调器,并且连接成功完成,但是当我尝试发送SMS时...我收到此消息:
错误:电话报告通用通信错误或语法错误.(GsmComm.GsmCommunication.CommException)"
有什么问题吗?
Hey guys,
I was checking the sample code with gsmComm library, my modem is nokia 5130 Xpressmusic modem and the connection was done successfuly but when I tried to send a SMS... I got this message:
"Error: Phone reports generic communication error or syntax error. (GsmComm.GsmCommunication.CommException)"
What''s the problem?
// Read all SMS messages from the storage
DecodedShortMessage[] messages = CommSetting.comm.ReadMessages(PhoneMessageStatus.All, storage);
foreach(DecodedShortMessage message in messages)
{
Output(string.Format("Message status = {0}, Location = {1}/{2}",
StatusToString(message.Status), message.Storage, message.Index));
ShowMessage(message.Data);
Output("");
}
Output(string.Format("{0,9} messages read.", messages.Length.ToString()));
Output("");
推荐答案
尝试将您的问题发布到文章下方的论坛中,这样作者应会看到它.
Try posting your question in the forum below the article, and that way the author should see it.
当我调试该行时:
When i debug the line:
DecodedShortMessage[] messages = CommSetting.comm.ReadMessages(PhoneMessageStatus.All, storage);
我也面临着同样的问题
Error: Phone reports generic communication error or syntax error
我该如何解决
I have facing the same problem
Error: Phone reports generic communication error or syntax error
How can i resolve
这是GSMComm在某些不正确的情况下解释ERROR响应的方式.原因可能有很多,包括:
*在硬件级别上存在通信问题.
*命令的语法无效.示例:电话需要特定命令的3个参数,但只有2个.
*电话处于命令无效的状态.示例:在手机等待输入PIN码时尝试发送SMS消息.
*完全不支持该命令.示例:某些电话不允许您阅读联系人或SMS消息.
答案来自 http://www.scampers.org/steve/sms/libraries.htm [ ^ ].
This is how GSMComm interprets the ERROR response if something isn''t right. Many issues can be the cause, including:
*There is a communication problem on the hardware level.
*The syntax of a command is invalid. Example: The phone requires 3 parameters of a specific command but got only 2.
*The phone is in a state where the command is not valid. Example: Trying to send SMS messages while the phone waits for a PIN code to be entered.
*The command is not supported at all. Example: Some phones don''t allow you to read contacts or SMS messages.
Answer taken from http://www.scampers.org/steve/sms/libraries.htm[^].
这篇关于“错误:电话报告通用通信错误或语法错误. (GsmComm.GsmCommunication.CommException)".有什么问题 ?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!