Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Data transfer between GPRS modem and Remote server

Status
Not open for further replies.
vivekraju said:
Ya its exactly wat u said.... Is it possible???????
Place code in your web page to send data back to the client (modem). The response will be at the end of the data returned from the server.

www.W3Schools.com has some good tutorials on how to return data using various server languages (PHP, ASP, etc.)
 
Thanks for your information and now i am able to read data from server.:D

Added after 3 hours:

One more question what will happen if i receive a sms while sending data. what should i do in that to send the data without error.
 

vivekraju said:
Thanks for your information and now i am able to read data from server.:D

Added after 3 hours:

One more question what will happen if i receive a sms while sending data. what should i do in that to send the data without error.

Try this, it work fine to send data. The same when recievin data.

ati

SIMCOM_Ltd
SIMCOM_SIM300
Revision:1008B15SIM300M32_SST34HF3284_MULTIPLEXIP

OK
at+cipmux?

+CIPMUX: 1

OK
at+cstt

OK
at+ciicr

OK
at+cifsr

10.76.58.102
AT+CIPSTART=0,"TCP","205.234.235.188",21

OK

0, CONNECT OK

+RECEIVE:0,310
220---------- Welcome to Pure-FTPd [TLS] ----------
220-You are user number 4 of 50 allowed.
220-Local time is now 10:48. Server port: 21.
220-This is a private system - No anonymous login
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
at+cipsend=0

> user xxxxxx

SEND OK

+RECEIVE:0,40
331 User infolog OK. Password required
at+cipsend=0

> pass xxxxxx

SEND OK

+RECEIVE:0,92
230-User infolog has group access to: infolog
230 OK. Current restricted directory is /
at+cipsend=0

> pasv

SEND OK

+RECEIVE:0,52
227 Entering Passive Mode (205,234,235,188,145,83)
AT+CIPSTART=1,"TCP","205.234.235.188",37203

OK

1, CONNECT OK
at+cipsend=0

> cwd simcom

SEND OK

+RECEIVE:0,38
250 OK. Current directory is /simcom
at+cipsend=0

> stor sim.txt

SEND OK

+RECEIVE:0,30
150 Accepted data connection
at+cipsend=1

> hello from infolog
SEND OK
at+cipsend=0

> bye

SEND OK

1, CLOSED

0, CLOSED
 

Hello GSM MAN,

Here Is an solution for Remote data logging using gprs.(SIM300 is used here and data is successfully sen to real Ip server).

I Want to send data from remote place to server using the Benq M23/M22 gprs Modem.Is it possible to do with benq M23/M22 gprs modem?

I think SIMCOM at command and BenQ AT command will not be same.....

What should I do If I want to data send data to real IP server from benq gprs Modem.

Please Help.


Thanks and Regards
Kamanashish
 

Hi meyerlo, I have question about your modem, I try transfer files on remote server ftp, and I use your commands , but the modem say "already have connection".
With the command at+cipstart=1,
With the command at+cipmux, the modem say "ERROR".
And the command ATI don't say MULTIPLEXIP.

What model of modem do you have?
I have SIMCOM 340CZ Thanks.
 

hello guys,
i am developing a program which will send data from remote location to server using SIMCOM 300 GPRS modem. on server side a socket program will accept each data packets coming from remote location on port 52500. Right now I am trying to send data to server on port 52500 using hyperterminal. But it throws an error Connection failed. I am trying to connect using following commands

at
OK
at+cipstatus
STATUS: IP INITIAL

at+cstt="APN","USERNAME","PASSWORD"
at+ciicr
OK
at+cifsr
SOME IP
at+cdnsorip=0
OK
at+cipstart="TCP","IP OF SERVER","52500"
STATE: TCP CONNECTING
CONNECT FAILED

please help me out
 

felichejp said:
Hi meyerlo, I have question about your modem, I try transfer files on remote server ftp, and I use your commands , but the modem say "already have connection".
With the command at+cipstart=1,
With the command at+cipmux, the modem say "ERROR".
And the command ATI don't say MULTIPLEXIP.

What model of modem do you have?
I have SIMCOM 340CZ Thanks.
The SIM340 allows only one GPRS connection at a time.

Added after 1 minutes:

nisargupadhyay87 said:
hello guys,
i am developing a program which will send data from remote location to server using SIMCOM 300 GPRS modem. on server side a socket program will accept each data packets coming from remote location on port 52500. Right now I am trying to send data to server on port 52500 using hyperterminal. But it throws an error Connection failed. I am trying to connect using following commands
Have you tried connecting to your server using a PC - i.e. TELNET?
 

GSM Man said:
felichejp said:
Hi meyerlo, I have question about your modem, I try transfer files on remote server ftp, and I use your commands , but the modem say "already have connection".
With the command at+cipstart=1,
With the command at+cipmux, the modem say "ERROR".
And the command ATI don't say MULTIPLEXIP.

What model of modem do you have?
I have SIMCOM 340CZ Thanks.
The SIM340 allows only one GPRS connection at a time.

Added after 1 minutes:

nisargupadhyay87 said:
hello guys,
i am developing a program which will send data from remote location to server using SIMCOM 300 GPRS modem. on server side a socket program will accept each data packets coming from remote location on port 52500. Right now I am trying to send data to server on port 52500 using hyperterminal. But it throws an error Connection failed. I am trying to connect using following commands
Have you tried connecting to your server using a PC - i.e. TELNET?
hi GSMMAN
sorry for late reply.
i had tried to connect it using telnet but it didnt connect, but when i tried to connect it using remote desktop, it connected successfully. my sever is not dedicated server, its a VPS. few weeks ago i was able to float data from client to server using broadband internet, but when i tried GPRS, i was unable to connect on 52500 port. Is it an issue of port restriction??

Thanks
 

Hi,

where can i find this SIM300 firmware relase

Revision:1008B15SIM300M32_SST34HF3284_MULTIPLEXIP

for the AT+CIPMUX command?

Thank you
 

Hi All
First post here and I am a newbie so patience please.

I am using a telit GE865 modem to try to FTP files to a server.
I can connect to the FTP server from outside computers but not with the Module.
The error I get is either "bad or no response from server" or "can not connect to control socket"<-(my server)

I cannot get past the AT#FTPOPEN command on any FTP site including the one I setup. I have tried passive and active modes. I have even tried to connect to FTP sites using SKTD command.

I have CSQ of 14. I use AT+CREG=2 and CMEE=2 to get verbose error messages.
I have turned off all the module firewalls. I have checked that it has the correct autoband set to 1 (automatic selection)

I can do SMS with it. I can connect to websites using #SKTD. I can ping other sites and the module, with the module.

Thanks in advance for any suggestions-
Please feel free to PM me.


[/i]
 

Hi vivekraju, we are trying to do the similar thing to what you did on your server using PHP. We are struggling to receive the data on the server. We are also using the GET command to send data to the server. I think there is a problem with our PHP server script. May you please send us your server script gprs.php which you used to test your application please
 

can anyone help me to combine these two programmes I want to read Gps data(latitude&longitude) and send with Gsm :
gps :
$regfile = "m16def.dat"
$crystal = 11059200
$baud = 9600
'-------------------------------------------------------------------------------
Config Lcd = 20 * 4
Cls
Cursor Off
'-------------------------------------------------------------------------------
Config Porta.1 = Output : Reset Porta.1
Config Portb.0 = Output : Led1 Alias Portb.0
'-------------------------------------------------------------------------------
Deflcdchar 0 , 7 , 5 , 7 , 32 , 32 , 32 , 32 , 32
'-------------------------------------------------------------------------------
On Urxc Rec_isr
Enable Urxc
Enable Interrupts
'-------------------------------------------------------------------------------
'GPS variables
Dim Urx_buff As String * 550
Dim Cnt As Word
Dim M As String * 5
Dim Gpgga As String * 80
Dim Gpvtg As String * 80
Dim Gpgga_flag As Bit
Dim Gpvtg_flag As Bit
Dim V_counter As Byte
Dim I As Byte
Dim L As Byte
Dim F_utc_time As Byte
Dim E_utc_time As Byte
Dim F_longitude As Byte
Dim E_longitude As Byte
Dim F_latitude As Byte
Dim E_latitude As Byte
Dim F_altitude As Byte
Dim E_altitude As Byte
Dim F_speed As Byte
Dim E_speed As Byte
Dim F_sat_num As Byte
Dim E_sat_num As Byte
Dim Utc_time As String * 10
Dim Utc_time_k As String * 10
Dim Longitude As String * 12
Dim Latitude As String * 12
Dim Altitude As String * 8
Dim Speed As String * 8
Dim Sat_num As String * 4
Dim Sat_inuse As Byte
Dim S_k1 As Single
Dim S_k2 As Single
Dim R_k1 As String * 15
Dim N As Byte
'-------------------------------------------------------------------------------
Locate 1 , 1 : Lcd "GPS"
Locate 2 , 1 : Lcd "connecting..."
Locate 3 , 1 : Lcd "Please wait..."

Do
'-------------------------------------------------------------------------------
If Cnt > 520 Then
Set Led1
Disable Urxc
Gosub Get_nmeapaket
Gosub Extract
Reset Led1
Urx_buff = ""
Cnt = 0
Enable Urxc
End If
'--------------------------------------------------
Loop
End
'-------------------------------------------------------------------------------
Get_nmeapaket:
For Cnt = 1 To 500
M = Mid(urx_buff , Cnt , 5)
If M = "GPGGA" Then
Gpgga = ""
V_counter = 0
Do
M = Mid(urx_buff , Cnt , 1)
Incr V_counter
Incr Cnt
Gpgga = Gpgga + M
Loop Until V_counter > 78 Or M = "*"
Exit For
End If
Next
For Cnt = 1 To 500
M = Mid(urx_buff , Cnt , 5)
If M = "GPVTG" Then
Gpvtg = ""
V_counter = 0
Do
M = Mid(urx_buff , Cnt , 1)
Incr V_counter
Incr Cnt
Gpvtg = Gpvtg + M
Loop Until V_counter > 78 Or M = "*"
Exit For
End If
Next
Urx_buff = ""
Cnt = 0
Return
'-------------------------------------------------------------------------------
Extract:
V_counter = 0
L = Len(gpgga)
For I = 1 To L
M = Mid(gpgga , I , 1)
If M = "," Then
Incr V_counter
If V_counter = 1 Then
F_utc_time = I + 1

Elseif V_counter = 2 Then
E_utc_time = I - F_utc_time
F_latitude = I + 1

Elseif V_counter = 3 Then
E_latitude = I - F_latitude

Elseif V_counter = 4 Then
F_longitude = I + 1

Elseif V_counter = 5 Then
E_longitude = I - F_longitude

Elseif V_counter = 7 Then
F_sat_num = I + 1

Elseif V_counter = 8 Then
E_sat_num = I - F_sat_num

Elseif V_counter = 9 Then
F_altitude = I + 1

Elseif V_counter = 10 Then
E_altitude = I - F_altitude
End If

End If
Next
Utc_time = Mid(gpgga , F_utc_time , E_utc_time) : Utc_time = Left(utc_time , 6)
Latitude = Mid(gpgga , F_latitude , E_latitude)
Longitude = Mid(gpgga , F_longitude , E_longitude)
Altitude = Mid(gpgga , F_altitude , E_altitude)
Sat_num = Mid(gpgga , F_sat_num , E_sat_num)

R_k1 = Left(latitude , 2)
S_k1 = Val(r_k1)
Latitude = Mid(latitude , 3 , 7)
S_k2 = Val(latitude)
S_k2 = S_k2 / 60
S_k2 = S_k2 + S_k1
Latitude = Fusing(s_k2 , "#.######")

R_k1 = Left(longitude , 3)
S_k1 = Val(r_k1)
Longitude = Mid(longitude , 4 , 7)
S_k2 = Val(longitude)
S_k2 = S_k2 / 60
S_k2 = S_k2 + S_k1
Longitude = Fusing(s_k2 , "#.######")
N = Val(sat_num)

If S_k2 <> 0 And N > 1 Then
Locate 1 , 1 : Lcd "Latitude=" ; Latitude ; Chr(0) ; " "
Locate 2 , 1 : Lcd "Longitud=" ; Longitude ; Chr(0) ; " "
Locate 3 , 1 : Lcd "Utc_time=" ; Utc_time
Locate 4 , 1 : Lcd "Altitud=" ; Altitude ; "m N=" ; Sat_num
End If
Return
'-------------------------------------------------------------------------------
Rec_isr:
Incr Cnt
Urx_buff = Urx_buff + Chr(udr)
Return








and GSM programme:




$regfile = "m16def.dat"
$crystal = 11059200
$baud = 9600
'$sim

Declare Sub Getline(s As String)
Declare Sub Flushbuf()
Declare Sub Showsms(s As String )


Dim I As Byte , B As Byte
Dim Sret As String * 200 , Stemp As String * 6 , W As Word
Dim S1 As String * 200 , S2 As String * 200



Ddrb.0 = 1
Ddrd.4 = 1

Config Lcdpin = Pin , Db4 = Pinc.4 , Db5 = Pinc.5 , Db6 = Pinc.6 , Db7 = Pinc.7 , E = Pinc.3 , Rs = Pinc.2
Config Lcd = 16 * 2

Cls
Home
Lcd "nEW"
'---------------------------------------------

Lowerline : Lcd "ON Process"
Toggle Portd.4
Portb.0 = 1
Wait 2
Toggle Portd.4
Portb.0 = 0
Wait 4
Toggle Portd.4
Portb.0 = 1
Wait 15
Toggle Portd.4

Print "AT" ; Chr(13)
Wait 1

Print "AT" ; Chr(13)
Wait 1

Print "AT" ; Chr(13)
Wait 1
Print "AT" ; Chr(13)
Wait 1
Print "AT" ; Chr(13)
Wait 1
Print "ATE0" ; Chr(13)
Wait 1



'----------------------------------------------
'sms settings

Cls : Home : Lcd "send sms"
Wait 1
Print "AT+CMGF=1" ; Chr(13)
Wait 1
Print "AT+CMGS=" ; Chr(34) ; "0913322222" ; Chr(34) ; Chr(13)
Wait 1
Print "SIM IS Restarted" ; Chr(26)
Lowerline : Lcd "sent sms1"
Getline Sret
Cls : Lowerline
Lcd Sret
Wait 4

Print "AT+CGATT=1" ; Chr(13)
Getline Sret
' get data from modem
Cls : Lowerline
Lcd Sret
Wait 4
Print "AT+CIPSTART=" ; Chr(34) ; "UDP" ; Chr(34) ; "," ; Chr(34) ; "91.98.32.182" ; Chr(34) ; "," ; Chr(34) ; "8830" ; Chr(34) ; Chr(13)
Getline Sret
Cls : Lowerline
Lcd Sret
Wait 4
Print "AT+CIPSEND" ; Chr(13)
Wait 1
Print Chr(01) ; Chr(02) ; Chr(03) ; Chr(26)
Getline Sret
Cls : Lowerline
Lcd Sret
Wait 4

Print "AT+CIPSEND" ; Chr(13)
Wait 1
Print 123
Getline Sret
Cls : Lowerline
Lcd Sret
Wait 4

Print "AT+CIPSEND" ; Chr(13)
Wait 1
Print "123"
Getline Sret
Cls : Lowerline
Lcd Sret
Wait 4


'--------------------------------------------------


Do
Getline Sret ' get data from modem
Cls : Lowerline
Lcd Sret
Wait 1
I = Instr(sret , ":") ' look for :
If I > 0 Then 'found it
Stemp = Left(sret , I)
Select Case Stemp
Case "+CMTI:" : Showsms Sret ' we received an SMS
' hanle other cases here
End Select
End If

Loop
Flushbuf




End



Sub Showsms(s As String )
Cls : Home
I = Instr(s , ",") ' find comma
I = I + 1
Stemp = Mid(s , I) ' s now holds the index number
Lcd "Number=" ; Stemp
Wait 1

Print "AT+CMGR=" ; Stemp ' get the message
Getline S1
Getline S2 ' header +CMGR: "REC READ","+316xxxxxxxx",,"02/04/05,01:42:49+00"
Cls : Home : Lcd "back sms"
Wait 1
Print "AT+CMGF=1" ; Chr(13)
Wait 1
Print "AT+CMGS=" ; Chr(34) ; "0913333333" ; Chr(34) ; Chr(13)
Wait 1
Print S1
Wait 1
Print S2 ; Chr(26)
Lowerline : Lcd "backed sms1"
Wait 4
Cls : Home
Lcd "remove sms"
Print "AT+CMGD=" ; Stemp ' delete the message
End Sub


Sub Getline(s As String)
S = ""
Do
B = Inkey()
Select Case B
Case 0 'nothing
Case 13 : If S <> "" Then Exit Do ' we do not need this one
Case 10 : If S <> "" Then Exit Do ' if we have received something
Case Else
S = S + Chr(b) ' build string
End Select
Loop
End Sub


'flush input buffer
Sub Flushbuf()
Waitms 100 'give some time to get data if it is there
Do
B = Inkey() ' flush buffer
Loop Until B = 0
End Sub
 

hello evryone
i am new to this stuff plz help me i studied all the entire post here but i goe one doubt here i am using here for the server side coding in VB.NET so shell i write here
GET /gprs.vb.net? HTTP/1.1CRLF

plz reply me and here i am not sending only one data iam sending here multiple data
thanx
 

hi,..
i am creating a tcp server code,..and when i check it can only receive from client mode,.. and display's in my server terminal,..but it can't get data from my terminal,.here is the terminal window contents...
[GPRS] : open--> Disconnected
[GPRS] : start--> Connected
[WIP] : new TCp server
[SAMPLE]: some Data Arrived
hi
hello

AT

OK

pls tell why i cat type and send data back to the client,..
 

>>AT+CDNSCFG?
<<EXT: I

<<ERROR
<<AT+CDNSCFG=?
<<EXT: I

<<ERROR
What type of error it is?
Does my modem (BenQ M23A) not support this command?
Please help me?
 

Hi,,
I'm seaching for "sim900 Customer flash loader V1.01"
named in the AN_900_Update Tool_UGD_V1.01, attached here

Give me a repply

Best regards
 

Please help!!

I pass the AT command to connect with the server and the get the result as connected

AT+CIPSTART="UDP","www.google.com","80"
ok

Connect ok

AT+CIPSEND
>GET/HTTP/1.1
host:www.google.com^z
send fail

AT+CIPSTATUS
8 // TCP/UDP connection is working
ok

if the modem is connected then why the web page request is not being sent??? please help debugging this issue
 

Hi GSM MAN,

I saw u r helping many members out here.

I have same query, I am using quectel GSM/GPRS enabled modem. I want to send data of device connected to this modem to server with static IP via GPRS. Kindly help me out in doing this.
 

hi guys i could connect server so how i send data from my gprs to another gprs? and where i take off ip (another gprs )?

Added after 1 minutes:

i don't understand well
please help

Added after 5 minutes:

hi guys
so how i send data from my gprs to another gprs?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top