LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

AT commands and GPRS connection

Hi,
I would like to establish new GPRS connection on my PC to send measurements via TCP to a database.
I use Siemens MC35 GSM/GPRS terminal.
I have tried to create such GPRS connection using AT commands of MC35 terminal sent by LabView or HyperTerminal (I use Windows XP Pro.) to the terminal:
         ....
         ....
          AT+CGDCONT=1,"IP","internet"
          ATDT*99***1#
 
In both cases the response was:
          CONNECT
          ~Q#$^*&()*(&)...............
          ............................
          &*()$%^@&$%&$~
          NO CARRIER
 
In the same time I don't have any problems with sending SMS' using AT commands in LabView or HyperTerminal.
Also there is no problem with establishing that GPRS using dial-up connection created in Connection Wizard under Windows XP.
I have spied COM port (by HHD Serial Monitor software) which is used to communicate with the terminal during this dial-up connection and then I used exactly the same set of AT commands but in HyperTerminal:
           AT
           ATE0V1
           AT
           AT+CGDCONT=1,"IP","internet"
           ATS0=0
           AT
           ATE0V1
           AT
           AT+CGDCONT=1,"IP","internet"
           ATDT*99***1#
 
The result was as before: ...NO CARRIER
 
What is wrong?
Thanks!
 
Message 1 of 3
(7,492 Views)
This is what looks like is happening:
 
The AT command is dialing the modem and the remote end is answering
    thereby proving that the phone number is correct
 
You next get a CONNECT message
    thereby indicating that your modem is connecting up with the one at the other end of the line
 
What follows next is a block of "random" characters (including, ironically, a smiley face) and a DISCONNECT message.
    the "random" characters are the terminal at the other end attempting to establish communications via
    some protocol that it uses. You don't know how to respond, so it eventually drops the connection.
 
After making connection you still need LV code that can speak the protocol the system at the other end of the wire is expectng. I am not familier with the Siemens MC35 GSM/GPRS terminal, but my first step would be to determine whether the protocol it speaks is a standard protocol. You can find that out by either calling Siemens (probibly a long-shot) or getting on their website.
 
If the protocol is a standard, or Siemens is willing to document the protocol, you can begin writing the drivers that can understand it.
 
Another alternative is to see if there is a way to put the terminal into some sort of "plain ASCII" mode that allows you to send and receive human readable commands and responses.
 
Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 2 of 3
(7,478 Views)

What happened is that your GSM/GPRS modem established a "physical" connection to the internet service provider (your cellular network operator) and service provider required to establish the "logical" connection using PPP protocol.

There are two standard ways to deal with it:

* use the GPRS modem as a standard modem under windows (in linux it would be KPPP, if I am not mistaken), establish the GPRS connection and do NOT disconnect (you pay per MB-s, not per minutes). You would probably want to set the connection to automatically re-establish itself, if disconnected. This is proably the best way: a) the least hussle, b) full TCP/IP functionality in the sense that your remote PC is "permanenty" present on the Internet.

* use modem's built-in PPP and TCP/IP stack to handle the connection. You will need to write software to control it (or use a commercial library, like www.lysko.com - > products) but become independent of the operating system and know what happens and when. The limitation here is that you have limited number (often only one) port on TCP and therefore have to handle many detals of data transfer by yourself. On the other hand, this is better than firewall since the TCP is handled by the modem, not by the operating system.

From the same link, you can also look at the real-world performance of different levels of wireless connectivity (GSM, GPRS, E-GPRS (EGPRS), EDGE, 3G and HSDPA) and economics of the subject.

 

Message 3 of 3
(7,290 Views)