views:

409

answers:

3

Hi, 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. This SMS message is sent to the user when he is billed with the bill details. The GSM modem is connected to a single computer but the billing can happen in other systems. 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*.

  • can we access the COM port of other system or shoould i use socket programming (with the machine with the modem(Server) listening for any connection, the sender has to send data in particular format and the server has to parse the data and send the message) or use Java RMI or is there any other solution.

Suggestions please....

Thank you

+4  A: 

There are any number of solutions you can think up. The most common ones would be:

  • Communication with some kind of RPC, be it RMI, SOAP, plain HTTP, telnet, etc.
  • Using an SMS gateway such as Nordic Messaging’s EMG (probably overkill, though) or kannel (seems to be down currently).
Bombe
+1 for SMS Gateway. Also, there are great Java SMPP clients like ObjectXP's one.
karim79
A: 

We've got an SMS Gatway. We wrapped it in a J2EE-application with a webservice interface. That way we can send SMS from any of our applications. For the sake of java we made a little jar-file that talks to the webservice

SmsClient smsclient = new SmsClient();
smsclient.sendSms(from, to, message);
Tommy
A: 

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.

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. UDP was only used instead of TCP as it was simpler to configure on an embedded system.

John McG