2 Replies Latest reply on Jun 15, 2015 2:51 PM by hmoore

    Maintaining TCP through powersave.

      [SDK-2.3.0, BCM943362WCD4]



      I have been trying to test the ability of Wiced to maintain a TCP connection across powersaves.



      I have effectively merged tcp_client and ping_powersave to create an app that


      creates a TCP connection and then sleeps. It wakes every N seconds to send and receive data


      down the same connection (i.e. the connection is not destroyed).  Its talking to a HTTP 1.1 server (i.e. with keep-alive).



      It works, i.e. it wakes and successfully sends and receives data on the same connection.


      The trouble is I cant seem to keep the service up for more than a few wakes.



      From wireshark the AP does not seem to be deauthing and I can see no connection resets from the server side.



      If I enable the connection to be setup and destroyed on every wake (see #define CONNECT_EVERY_TIME)  then


      the system will stay awake for at least 500 seconds (perhaps a separate issue here).



      So it would seem that somehow the TCP state is not being maintained across a sleep, or it is but it loses its mind fairly quickly.



      App is attached - just need to provide SSID.