windows mobile - TCP socket read hangs when wi fi connection breaks -
windows mobile - TCP socket read hangs when wi fi connection breaks -
i facing peculiar problem read on tcp sockets when wi fi connectivity goes off , 1 time again reconnects
scenario : continously pinging server on windows pocket pc device on wi fi. when device in area of wifi weak signal strength , socket read blocks indefinately , freezes device totally , when wi fi signal strength becomes stronger read homecoming , previous operations on screen executed.
can give solution problem
this feature of tcp -- tcp reliable, if there's sort of network problem (such wifi signal loss describe), info buffered , held until problem goes away, @ point info sent 1 time again , connection resume.
you can modify or tune behavior bit changing tcp timeout values -- if connection unable send info @ timeout period (usually 10 minutes default), connection shut down. depending on api using may able alter timeout several seconds instead (though careful of making short, cause drop connections due more transient network problems.)
it sounds have problem in code paused connection locks device -- caused holding lock shouldn't while trying read info connection. create sure release locks before doing socket read (or write). if can prepare problem, may find don't care tcp timeout.
windows-mobile tcp wifi pocketpc
Comments
Post a Comment