Author |
Post |
|
#1 Tue Jul 14, 2009 05:41, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
|
Hi, Can I send same SMS to different Users using single SMS file as per below: ------------------------------------------------------------------------------------- To:919999039589,919910653416 alphabet:ISO HI,ALL this is Dinesh ------------------------------------------------------------------------------------------ will it be work.
|
|
#2 Tue Jul 14, 2009 07:57, 190 months ago.
|
Member
Registered: Jul 2009
Location: NCR, Philippines
|
Hi,
I have tought of this also, but when I read and read all of the stuff here, its mentioned, its only1 to 1 sending. if you want multiple, you must create a script that will automate the whole process.
|
|
#3 Tue Jul 14, 2009 08:05, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Hi, Do you have any idea abut scripts that will automate the whole process.Guide me PLease
|
|
#4 Tue Jul 14, 2009 08:18, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Below are script posted for sending single message to different which I found posted in forum.But I have doubt over, once this scripts run then using only command line we can send message. Will it wont work for specify destination phone number directly in SMS file instead of sending through command line. Edit by keke: The script copied had the last line missing and was not "code" formatted. I changed it to link to the original post. It can be found here: How to configure sms recipients list
Links to older posts can always be done, even if they are locked, I do not remove any old posts which may contain any useful information or which are referred by a link.« Last edit by keke on Tue Jul 14, 2009 09:54, 190 months ago. »
|
|
#5 Tue Jul 14, 2009 11:22, 190 months ago.
|
Administrator
Registered: May 2009
Location: Jyväskylä, Finland
|
Quote Do you have any idea abut scripts that will automate the whole process.Guide me PLease
There is now a new sample script available: Multiple recipients in single SMS fileNotice the message format, To: numbers are one line for each.
|
|
#6 Wed Jul 15, 2009 13:53, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Thanx for Guidance I am using automated script for sending SMS simultaneously to different recipient as posted above in this forum.Below is SMS file format : ------------------------------------------------------------ #sms file format To:919312048374 To:919911702052 Alphabet:ISO Hi ALL THIS IS DINESH.. ---------------------------------------------------------------- #below are sms.conf devices = GSM1 outgoing=/var/spool/sms/outgoing checked=/var/spool/sms/checked loglevel=4 for logfile,7 for syslog alarmlevel=LOG_WARNING delaytime=10 errorsleeptime=10 blocktime=3600 receive_before_send=no autosplit=3 checkhandler=/etc/din.sh executable_check=yes logfile = /var/log/smsd.log loglevel = 7 [GSM1] init=AT+CPMS="SM" device = /dev/ttyAM0 baudrate=115200 SMSC=+919811009998 pre_init=yes rtscts=no cs_convert=yes outgoing=yes check_network=1 messageids=2 init2=AT+CSQ read_timeout=60 #Where checkhandler is path of automated script din.sh for sending SMS to different recipient. ------------------------------------------------------------------------------------------------------------------------------ # sms.log file ------------------------------------------------------------------------------------------------------------------------------------------------ Again same thing is happening in sms file its skipping 9312048734 number and sending only to 99117020502 when I am using automated script for sending SMS.While I am using automated script as checkhandler as per set in the sms.conf file.So is their any more modification is needed in sms.conf file so that I will able to send sms to different recipient .Kindly guide me how can I proceed further to solve this problem.??? « Last edit by keke on Thu Aug 06, 2009 20:12, 189 months ago. »
|
|
#7 Wed Jul 15, 2009 14:40, 190 months ago.
|
Administrator
Registered: May 2009
Location: Jyväskylä, Finland
|
I think that you do not have formail command available. Try which formail, what it says? If it's not available, install procmail package.
The script executes very long time, 13 sec. It returns zero value, which means that it did not detect multiple recipients. Because of this: "smsd: Moved file /var/spool/sms/outgoing/file_1 to /var/spool/sms/checked". That's the original file, not a created copy.When this file is sent, only last To: field has effect, all previous fields are overridden.
You can also test the checkhandler. Change outgoing="/tmp" and manually call the script with filename of a message as first argument. All possible error messages can then be seen.
In the message file there of course is one empty line between headers and message body, your sample just does not show it.
In the smsd.conf, there is "loglevel=4 for logfile,7 for syslog" which could be commented out. Effective loglevel is set later. Also remove the + sign from the SMSC= setting, smsd will insert it by itself and now there is two signs going to the modem.
|
|
#8 Fri Jul 17, 2009 04:36, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Thanx, Finally It Work. Problem was procmail package not install once it installed it work fine.
|
|
#9 Fri Jul 17, 2009 05:53, 190 months ago.
|
Member
Registered: Jul 2009
Location: NCR, Philippines
|
Do you have full details how did you do it or setup?
Please help
Thanks Dexter
|
|
#10 Fri Jul 17, 2009 09:35, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
step 1)Download the set up and untar the folder and then make +make install. 1)then their is configuration file /etc/sms.conf setting below .. #below are sms.conf devices = GSM1 outgoing=/var/spool/sms/outgoing checked=/var/spool/sms/checked alarmlevel=LOG_WARNING delaytime=10 errorsleeptime=10 blocktime=3600 receive_before_send=no autosplit=3 checkhandler=/etc/din.sh executable_check=yes logfile = /var/log/smsd.log loglevel = 7
[GSM1] init=AT+CPMS="SM" device = /dev/ttyAM0 baudrate=115200 SMSC=919811009998 pre_init=yes rtscts=no cs_convert=yes outgoing=yes check_network=1 messageids=2 init2=AT+CSQ read_timeout=60 ---------------------------------------------- 3)If you want to send single SMS to different recipient used automated script posted below and in config file used it as checkhandler=/etc/din.sh and then /var/spool/sms/outgoing/xxxx you define destination phone number 1,2,3 etc. annd message text also in sms file. 4)run sms tool using /etc/init.d/sms3 start command 5)tail -f /var/log/sms.log to
|
|
#11 Mon Jul 20, 2009 07:26, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Hi, Now I am Trying to use status monitor.For that I have downloaded the mm library from below link http://www.ossp.org/pkg/lib/mm/ and then comment the statistics to enable it.And then recompile the smstools but during make error is coming. --------------------------------------------------- stats.c:error:mm.h:no such file or directory stats.c:warning:implicit declaration of function 'MM_create' stats.c:warning:implicit declaration of function 'MM_maloc' stats.c:warning:implicit declaration of function 'MM_destroy' make[1]: [stats.o] Error1 make[1]:leaving directory '/root/smstools3/src' make:***[compile] error 2 -------------------------------------------------------------------------------------- Can somebody help me why its failed during make.
|
|
#12 Mon Jul 20, 2009 15:57, 190 months ago.
|
Administrator
Registered: May 2009
Location: Jyväskylä, Finland
|
You downloaded libmm but did you also install it with good directory settings and with success? This packages has a file named INSTALL which instructs to run ./configure --prefix=/path/to/mm. Good value for directory is --prefix=/usr.
Then make, make test and make install may take some time, but everything should run without error messages.
|
|
#13 Wed Jul 22, 2009 05:58, 190 months ago.
|
Member
Registered: Jul 2009
Location: Delhi, India
Topic owner
|
Hi, First of all Thanx for Assistance. Step1): ./configure --prefix=/path/to/mm and then make make test make install everything gone on a smooth manner without any error. Step2): In smstool directory /src/Makefile I had made one change i.e. #CFLAGS += -D NOSTATS Commneted above option to enable status monitor and again make and make install the smstoo3.During Making same error is coming. --------------------------------------------------- stats.c:error:mm.h:no such file or directory stats.c:warning:implicit declaration of function 'MM_create' stats.c:warning:implicit declaration of function 'MM_maloc' stats.c:warning:implicit declaration of function 'MM_destroy' make[1]: [stats.o] Error1 make[1]:leaving directory '/root/smstools3/src' make:***[compile] error 2 -------------------------------------------------------------------------------------- Am I following up right procedure.? Is more amendment is needed to make it working.?
|
|
#14 Wed Jul 22, 2009 10:02, 190 months ago.
|
Administrator
Registered: May 2009
Location: Jyväskylä, Finland
|
Other include files work fine, but compiler does not find a file mm.h. It's not in any directories which are defined as include directories for the compiler.
How did you exactly run the libmm install? Did you change the command to ./configure --prefix=/usr?
If you run ./configure again, you could first run make clean to get back the starting state.
As your smsd source code is under the root's home directory, I assume that libmm also was installed as a root, right?
You can use the following command to check what are the include directories for the compiler: cpp -v </dev/null
The output will have something like: #include <...> search starts here: /usr/local/include /usr/lib/gcc/i486-linux-gnu/4.2.3/include /usr/include End of search list.
If your compiler outputs something else than /usr/local/include and / or /usr/include, you must reinstall libmm using a different --prefix= setting.
|