Senin, 25 Mei 2009

Build Sms Gateway

build SMS Gateway is Trustix 3.0. Before the installation we do see you-please read the information about the Gammu

http://www.mwiacek.com/gsm/soft/gammu.html

What! I finished reading it? Okay .. just start and not a lot of doubt, let's start it needs to collect
build Gammu SMS Gateway using this.

1. Gammu.tar.gz
You can download at: http://www.mwiacek.com/zips/gsm/gammu/gammu.tar.gz
or # wget http://www.mwiacek.com/zips/gsm/gammu/gammu.tar.gz

2. Web Server (If you already have a webserver, just ignore this no 2, if you have not had to install apache first, myslq, php)

3. Handphone Nokia 3310 or Siemens C35i, to support other mobile phone, please read more

http://www.mwiacek.com/gsm/soft/gammu.html

Gammu support with a variety of brand mobile phone I see this:
Gammu currently supports:
majority of Nokia phones from Nokia DCT3 generation with operating system - for example Nokia 3210, 3310, 3315, 3410, 5110, 5130, 6110,

6130, 6150, 6210, 7110, 8210
majority of Nokia phones from Nokia DCT4 generation with operating system - for example Nokia 3100, 3510, 3510i, 6220, 6230, 6310, 6310i,

6510, 6610, 7210, 8310
many AT devices - for example many Siemens, Sony Ericsson, Nokia, Alcatel models
Alcatel from BE5/BF5/BH4 generation - for example 501, 511, 512
some functions with OBEX and Symbian devices

4. Serial cable for mobile phone

If you have successfully mendonwload gammu.tar.gz, please extract the
# tar xvfz gammu.tar.gz

After you extract you will automatically find the folder gammu-1.05.00, now go to the folder

# cd gammu-1.05.00

Before you install biasakan read README, INSTALL, etc.
#. / configure
# make
Here you need to see whether there are errors or if there is no error, means that the mysql library you are still sketchy, it is usually

error found was "lssl" not often found when doing "make" or mysql database with gammu does not support it.
(Solutions will try to re-install mysql or its complete library is needed)
# make shared
# make install
# make installshared

Next you need to upgrade "the library"
# Vi / etc / ld.so.conf
Add a link to the type library / usr / local / lib in the ld.so.conf file, then do the upgrade the library by typing
# / sbin / ldconfig

Note: If you can not find the error apa2 up to this stage means you have successfully mengintall Gammu SMS Gateway

Now try again to enter the folder where you extract gammu.tar.gz and copy-lah file in the folder

/ docs / example / config / there you will find 3 files with the name of the fruit gammurc, mysql.sql, smsdrc ago gammurc and file

smsdrc you just copy-to folder / etc

gammurc smsdrc # cp / etc /

Then edit the file looking like this:

[gammu]
port = / dev/ttyS0 # If you are using COM2 instead of ttyS1
# # model = 6110 model mobile phone it you ignore it, because if diaktifin problems often arise
connection = fbus # If you use Nokia phone connection to its "fbus" if you use hp Siemens replace "fbus" to "at19200"
synchronizetime # = yes
# logfile = gammulog
# logformat = textall
use_locking # = yes
# gammuloc = locfile
startinfo # = yes
# gammucoding = UTF8
rsslevel = teststable # # usephonedb = yes

If you are still confused, in the file already exists gammurc usage instructions see the bottom of it.
If you are lazy to edit the file is, you can also get the file in its www.posmetropadang.com / gammu / gammurc

Now make sure the data cable and mobile phone you are connected to the COM1 port on your computer, then type in your living

# gammu-Identify

I hope you can see the output as below:

Manufacturer: Nokia
Model: 3310 (NHM-5)
Firmware: 06.33 F (28-11-03)
Hardware: 1012
IMEI: 350835608671298
Original IMEI: 350835608671298
Manufactured: 0802
Product code: 0505201
Simlock 1: MCC + MNC 00101, opened, user, counter 0
Simlock 2: GID1 0000, opened, factory, counter 0
Simlock 3: GID2 0000, opened, factory, counter 0
Simlock 4: MSIN 0000000001, opened, factory, counter 0
MSID: 830d50880846870ebedd126096
MCU checksum: 9C79
DSP ROM: 6

If you already have a connection means such as over gammu can recognize your mobile phone and we can proceed to the step

another.

So now we make a living, how all the incoming sms ago saved to mysql database and can be shown to

website using php scripts.

Oke bro ... go work we have already nearly completed, there may be a coffee or a cigarette can disruputt first ... hehe?

Now you try to open the file smsdrc you have a copy-to folder / etc before

# vi / etc / smsdrc
leave under this section is only
[smsd]
PIN = 1234
logfile = smsdlog
commtimeout = 1
sendtimeout = 10

find and edit under this section in accordance with the circumstances you mysql

# --------- Settings smsd FOR MYSQL----------
user = root
password = password_mysql_anda
pc = localhost
database = nama_database

Note: In addition to the above mentioned that I love you please sign "#" because we need here only as part of

I just mentioned above, in order to connect to its database mysql.

Now you go to the directory / docs / example / config / there is a file 'mysql.sql', the table structure is used, you

include living in your MySQL database.

Create a database sms
# mysqladmin-u root-p create sms

Create a table of file gammu 'mysql.sql'
# mysql-u root-p

Or in a way that's easier, you can create a database and create table gammu via phpmyadmin

http://localhost/phpmyadmin

Once finished you can run the daemon smsd its
# gammu-smsd MYSQL / etc / smsdrc
Log filename is "smsdlog"
Press Ctrl + C to stop the program ...

If the exit as the above means your SMS Gateway has been running well and you can use according your needs,

sms and all that is on your handphone akan lansung into the mysql database.

For your next live stage show sms to your web using php scripts, php scripts it can be downloaded at
http://posmetropadang.com/gammu/sms.zip

You need to edit a few sms.php its condition in accordance with your database server.

Now you can open the browser via sms by typing your pet http://localhost/sms.php

So now what should you do? you need to do is service daemon to run automatically when smsd

restart the computer.

Create a file with a name and save gammu.sh in the directory / usr / local / bin /
# cd / usr / local / bin /
# vi gammu.sh

Its contents are as follows:

#! / bin / sh
export LANG = da_DK
/ usr / local / bin / gammu-smsd MYSQL / etc / smsdrc

Then edit the file / etc / inittab you
# vi / etc / inittab

Add the line below in your inittab

GA: 345: respawn: / usr / local / bin / gammu.sh

0 Comments:

  © Blogger templates 'Neuronic' by Ourblogtemplates.com 2008

Back to TOP