在C#中重新启动调制解调器命令 [英] Reboot Modem Command in C#

查看:131
本文介绍了在C#中重新启动调制解调器命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

有人可以告诉我如何使用C#编程重新启动调制解调器吗?

这是西门子的调制解调器,

非常感谢您

Hello

Can someone show me how to reboot a modem with c# programming

It''s a Siemens Modem,

thank you very much

推荐答案

您有没有可以与调制解调器通信的代码?如果是这样,则正确的命令顺序为:

+++
ATZ


发送 +++ 序列后,等待 OK 响应;该顺序告诉调制解调器进入命令模式并侦听命令字符串.准备就绪后,它会通过发送回 OK 的方式进行响应.在 +++ 字符串后不需要CRLF,但是在发送 ATZ 命令后不需要.现代调制解调器能够保存多组默认设置.它们可以接受命令 ATZ n ,其中 n 是一个数字,用于选择适当的状态以重置设备.到.使用 n = 0选择出厂默认设置.

如果尚未编写与调制解调器进行通信的代码,请研究System.IO.Ports中的SerialPort类.您应该在那里找到所需的东西.如果没有,请在尝试了几件事并包含您编写的任何代码后再次发布,这将帮助我们为您提供更好的答案.祝你好运!
Do you have any code that lets you communicate with the modem already? If so, the proper command sequence is:

+++
ATZ


Wait for an OK response after you send the +++ sequence; that sequence tells the modem to enter Command Mode and to listen for a command string. When it''s ready, it responds by sending back OK. You do not need a CRLF after the +++ string, but you do need it after sending the ATZ command. Modern modems are able to hold multiple sets of default settings. These can accept the command ATZn, where n is a number that selects the proper state to reset the unit to. Use n = 0 to select the factory default settings.

If you haven''t written the code to communicate with the modem yet, research the SerialPort class in System.IO.Ports. You should find what you need there. If not, post again after you''ve tried a few things and include any code you''ve written, That will help us to provide you with better answers. Good luck!


这篇关于在C#中重新启动调制解调器命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆