Not receiving server data

10 thoughts on “Not receiving server data

  1. Good morning,


    Im on a project that works with GPRS module GE864 and im being annoyed with a problem. The problem is that when I send data to my server, the server cant succesfully send me back some sort of acknowledgement message(its not TCP ACK, its a project specifc ACK). The server response is a 15 bytes message and is not being received by the module although its being sent by the server. The code:





    for j in ack1:

    ack2=ack2+hex((ord(j))+’ ‘

    SER.send(‘ACK: ‘+ack2+’rn’) 


    Thanks in advance,


    João Francisco 

    1. 1. Maybe there isn’t enough time for the ACK to be received, use a loop as shown in Telit Easy Script in Pyton at MDM.receive function (page 25), waiting for all 15 bytes and a timeout.

      2. Are you able to receive anything else? Check flow control on MDM, try with AT&K0.



  2. Thanks Cosmin, but it didn’t worked. I used AT&V to see if the modem was operating with flow control. It was(K3) then I used AT&K0 to disable it.  Yes im able to receive data. The modem is connected in a physical module which send data via the serial port. I use the MDM module to send this data to the server, as seen on MDM.send(readFile(i),9), but I dont really know if it is correct to look at the AT Interface expecting the server answer(again, its not a premade protocol).Surprisingly, before I made any change in the script, Python was accusing error on "for j in ack1:" and I really don’t know why. I made some changes, as you recommended, to extend the timeout and used 1 minute this time. I commented the FOR problem because its just formating the data:

    ack1 = ”
    timeout = MOD.secCounter() + 60
    ack1 =
    while((len(ack1) == 0) and (MOD.secCounter() < timeout)):

    ack1 = ack1 + 

  3. Even after all the changes I have made, nothing did work. Even adding the code showed no results at all:





    SER.send(‘FLOW: ‘+r+’rn’) 

     Does anyone have another guess ? 
    1. Do you have a debug system in place, you rely on messages on SER? Can you receive anything on SER from the module?

  4. No, I dont have a debug system in place, because I dont know how to do it with python easy script. The Telit Module is inside a GPRS modem made here in Brazil, so I connect a USB to Serial cable from the PC to it. When im not running the script I can send AT commands trought the RealTerm program. When the script is running, when I use something like SER.send("Hi"), the message shows up on RealTerm Display.


    I have tested if the server sends the message back, and it does, but i don’t know how, I just cant read it. I dont know where is the problem. It is right to use MDM.receive/read to receive something from the server, right ?

    1. Maybe if you post a more complete program I can help more. Anyway, did you try the same procedures with AT commands, not in a Python script?

  5. Hello Cosmin, the problem is that where I work we have a term of confidentiality and the code is long. I use lots of AT commands before the modem starts running the script, but its not viable to reproduce the commands on the script just in AT because its very large. The function is basically that:


    def enviaFrames(frame,stored):
    SER.send(‘Entrou no EnviaFramesrn’)
    global frames
    SER.send(‘n1- FRAMES em enviaFrames:rn’)
    if(not stored):
    SER.send(‘Frame enviadorn’)
    for i in frames:
    timeout = MOD.secCounter() + 20
    ack1 =
    while((len(ack1) == 0) and (MOD.secCounter() < timeout)):
    ack1 = ack1 +
    for j in ack1:
    ack2=ack2+hex(ord(j))+’ ‘
    SER.send(‘ACK: ‘+ack2+’rn’)


    Frame is some sort of data that is not relevant right now. If the frame is stored in the memory of the module, stored will be equals 1. This ACK, as said, is not the TCP/IP ACK, but it is a 15 bytes server response which contains the frame ID and other things. 
  6. I tried the command:




    Although Im on online mode at the time of the reading(reconecta() functions does this), I used this code to see if there was something in the buffer. There wasn’t as I received NO CARRIER message on RealTerm display.  Nothing seems to work…