ftp hangs

7 thoughts on “ftp hangs

  1. My ftp hangs after sending the ftpput, and doesn’t timeout. The CONNECT message does not come.

     

     

    Checking the ftp server by browser, the file is created, but 0 size.

     

    This is the session log

     

    AT+CGDCONT= 1,"IP","","0.0.0.0",0,0

    OK

    AT#SCFG = 1, 1, 512, 30, 300,100

    OK

    AT+CREG?

    +CREG: 0,5

     

    OK

    AT#SGACT = 1,1

    #SGACT: 10.179.255.136

     

    OK

    AT#FTPOPEN="123.456.789.0","******",******",0

    OK

    AT#FTPTO=1000

    OK

    AT#FTPTYPE=1

    OK

    AT#FTPPUT="file3.txt"

     

     

    1. Still not working.

       

      I’ve tried pinging the module after SGACT gives me the ip. Should this work??

       

      C:UsersChris>ping 10.179.188.208

       

      Pinging 10.179.188.208 with 32 bytes of data:

      Reply from 193.253.172.164: Destination net unreachable.

      Reply from 193.253.172.164: Destination net unreachable.

      Reply from 193.253.172.164: Destination net unreachable.

      Reply from 193.253.172.164: Destination net unreachable.

       

      Ping statistics for 10.179.188.208:

          Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

       

       C:UsersChris> 

  2. The IP 10.x… is provider’s internal network, the module is under their firewall/gateway so cannot be ping, and you cannot run server applications on your module. This can be a reason for your FTP problem, you are trying to use an active FTP connection, which means the client (module) acts as a server for data connection. You should use passive connections, the client (module) initiating both connections, control and data.

    Pay attention also to flow control, which is by default  enabled for data connections, if you don’t use flow control lines disable with AT&K0.

    Active FTP vs. Passive FTP, a Definitive Explanation

    1. aha, it works now 😀 

       

      Thank you VERY much !

       

      I have a supplemental question..

       

      If I’m doing binary file transfers, how do I signal the end of transfer?  

  3. As usual, +++ guarded by silence (no transfer) times.

     

    Note: use the escape sequence +++ to close the data connection.