2-way SMS Troubleshooting Tips

2-way SMS Troubleshooting Tips SearchSearch

SMS & MMS Technical Forum » NowSMS Support - SMS Issues (Product Support Only) » Archive through July 14, 2004 » 2-way SMS Troubleshooting Tips « Previous || Next »
Author Message
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 2637
Registered: 10-2002
Posted on Monday, May 24, 2004 - 02:25 pm:   

The purpose of this discussion thread is to offer some tips on troubleshooting the setup of 2-way SMS. Here is the approach that I usually recommend:

Enable receive messages for the GSM modem or SMSC connection. (Highlight the entry in the "SMSC" page of our configuration dialog, then press "Properties", and there will be an option for enabling receive if it is not already enabled.)

On the "2-way" page of our configuration dialog, check "Process Received SMS Messages".

But, initially don't define any commands in the command table. I recommend this for troubleshooting purposes.

Apply the changes, and restart the NowSMS SMS service.

Send an SMS message to the phone number for which you are receiving messages. If everything is ok, NowSMS should receive the message and create a file in the SMS-IN subdirectory with a .SMS file extension. (NowSMS will create this directory automatically the first time it receives a message.)

If no file is created, then NowSMS is not actually receiving the message.

  • If this is a GSM modem connection, note that phones that use the Symbian operating system do not support receiving SMS messages over the GSM modem interface. (This includes Nokia Series 60 phones, including the 3650, 6600, 6620, 7650, as well other Symbian based phones, such as the Nokia 92x0 and 7600. Also, the Nokia D211/D311 PC cards do not support receiving SMS over the GSM modem interface.)
  • For other GSM modems, it may be necessary to change the "SMS Message Storage" setting. Usually this setting is only performance related, but it may be worth trying other settings to see if one of the other settings enables NowSMS to start seeing received messages.
  • If you are not receiving messages over a connection to an operator SMSC, then the default settings in NowSMS might not be appropriate for your operator connection.
  • For example, in an SMPP environment, there are two basic setups for how the operator delivers received messages. The default behaviour in NowSMS is to open 2 SMPP connections to the operator, one as a transmitter (for sending messages), and one as a receiver (for receiving messages). Some operators only support a single connection, and request that you bind as an SMPP transceiver (which supports sending and receiving messages over the same connection). The Transceiver option is enabled under "Advanced Settings" in the SMPP configuration.
  • In a UCP/EMI environment, there are two basic setups for how received messages are delivered to your server. The default behaviour of NowSMS is to open a connection to the operator SMSC, where messages are sent and received over the same connection. But in some rare configurations, the operator will connect to your server when there are messages to be delivered. In these situations, a "Receive Port" must be defined in the properties for the SMSC connection. NowSMS will then listen for connections from the operator SMSC on this port. (Leave "Receive Port" blank for the default behaviour.)


Assuming that messages are being received by NowSMS, go back to the "2-way" page of the configuration dialog, and define a command in the command table.

A good test command is the "ECHO" example in the NowSMS documentation:

http://www.nowsms.com/documentation/ProductDocumentation/2_way_sms_support.htm

Specify a command prefix of "*". If you are using a version that has a "receive phone" prompt, leave that blank (it is for defining different commands for messages received on different phone numbers). In the "Command to Execute" field, define "c:\windows\system32\cmd.exe /c echo Echo @@FULLSMS@@". (Verify that CMD.EXE is in this directory before defining the command. On some systems it will be in c:\winnt\system32, or wherever Windows is installed.)

Check "Command returns response text".

Press "Add" to add the command to the "Received SMS Command Table".

When an SMS is received that matches this SMS command prefix (in the case of "*", any SMS that doesn’t match another defined prefix), the gateway launches a command processor (CMD) that simply echoes the text back to the screen adding the word "Echo" to the beginning of the received text. In this example, the sender of the SMS message will receive an "Echo" back of the command that they sent in to the gateway. While not an extremely useful command, this is a useful way of testing to see that the gateway is alive and capable of receiving SMS messages.

"Command to Execute" can also point to an HTTP request instead of an executable command. In this case, NowSMS can connect to a script running on another web server, so you can use scripting languages like PHP, ASP or Perl for processing received SMS messages.

There is a good simple PHP example here:

http://support.nowsms.com/discus/messages/1/3991.html

There's also a simple example of a Windows script being used in a 2-way command at the following link:

http://support.nowsms.com/discus/messages/1/333.html

And a very simple ASP example at the following link:

http://support.nowsms.com/discus/messages/1/4420.html

If you get stuck debugging 2-way SMS commands, try enabling the debug log in NowSMS. This is done by manually editing the SMSGW.INI file, and under the [SMSGW] header, add Debug=Yes. Then restart the NowSMS service. NowSMS will create an SMSDEBUG.LOG as it runs. Part of the information in this log will show the 2-way commands that NowSMS is attempting to process, as well as the responses that are returned from HTTP commands.
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 2638
Registered: 10-2002
Posted on Monday, May 24, 2004 - 04:25 pm:   

An additional useful link related to 2-way SMS, this one talks about how to use the "redirect" response to send a command back to NowSMS:

http://www.nowsms.com/support/bulletins/tb-nowsms-003.htm

Also, for the PHP example above, note that your PHP script could call other functions that initiate a new request to NowSMS to send different types of messages. Some good examples of using PHP scripts to send messages to NowSMS can be found at the following links:

http://support.nowsms.com/discus/messages/1/867.html
http://support.nowsms.com/discus/messages/1/1113.html
http://support.nowsms.com/discus/messages/1/1490.html
http://support.nowsms.com/discus/messages/1/4077.html


Login Login / Register Logout Logout Search Last 30 Days Topics Topics