[英]How should I go about implementing this SMS notification system?
I have developed a application which involves billing users. 我开发了一个涉及计费用户的应用程序。 To do this i have incorporated a GSM modem (gateway) that the SMS messages are sent through.
为此,我已集成了通过其发送SMS消息的GSM调制解调器(网关)。 This SMS message is sent to the user when he is billed with the bill details.
当向用户支付账单明细时,此SMS消息就会发送给用户。 The GSM modem is connected to a single computer but the billing can happen in other systems.
GSM调制解调器已连接到单台计算机,但计费可能在其他系统中进行。 How do I send an SMS notification for the changes that occur in the other systems, as the GSM modem is attached to a COM port on the computer*.
当GSM调制解调器连接到计算机上的COM端口时,如何发送SMS通知有关其他系统中发生的更改。
Suggestions please.... 请提出建议。
Thank you 谢谢
There are any number of solutions you can think up. 您可以想出许多解决方案。 The most common ones would be:
最常见的是:
We've got an SMS Gatway. 我们有一个短信网关。 We wrapped it in a J2EE-application with a webservice interface.
我们将其包装在具有Web服务接口的J2EE应用程序中。 That way we can send SMS from any of our applications.
这样,我们可以从任何应用程序发送SMS。 For the sake of java we made a little jar-file that talks to the webservice
为了Java,我们制作了一个与Web服务对话的jar文件
SmsClient smsclient = new SmsClient();
smsclient.sendSms(from, to, message);
I built a similar system to this in the past where small embedded systems sat on a network and reported messages over the network to a central server that logged the messages and sent SMS messages when required. 过去,我构建了与此类似的系统,其中小型嵌入式系统位于网络上,并通过网络将消息报告给中央服务器,该中央服务器记录该消息并在需要时发送SMS消息。
I used a java socket listener that waited for UDP messages from the embedded units and the java program wrote to the GSM modem on the servers comm port. 我使用了一个Java套接字侦听器,该侦听器等待来自嵌入式单元的UDP消息,并将Java程序写入服务器comm端口上的GSM调制解调器。 UDP was only used instead of TCP as it was simpler to configure on an embedded system.
仅使用UDP而不使用TCP,因为在嵌入式系统上更易于配置。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.