RiiiDD
Posts: 8
Joined: Tue Jun 23, 2009 8:48 pm

Bluetools / lostconnection too long in slave

Wed Aug 05, 2009 4:42 pm

hi,

When my Pocket Pc is connected to a slave device,
when the slave device shut down, i try to inform my pocket PC user.
Actually i use the catch of exception of the stream.endread instruction.

The problem is this exception occurs something like 15 seconds after the device really shuts down.
Those 15 seconds are way too long in my case. Do you have something for me for reducing this delay to 1 or 2 seconds ??

(When the device is Master, the delay is really cool (like 1 sec), but most of my users have their device in slave)

Thanks a lot !

RiiiDD
Posts: 8
Joined: Tue Jun 23, 2009 8:48 pm

RE: Bluetools / lostconnection too long in slave

Wed Aug 05, 2009 7:39 pm

add on :
it takes exactly 20 sec to raise it.
Where could i set this time out ?

Jonas
Posts: 2319
Joined: Mon Jan 09, 2006 2:20 pm
Location: Sweden

RE: Bluetools / lostconnection too long in slave

Wed Aug 05, 2009 11:01 pm

You can't, it's probably something built into the stack to prevent you from losing the connection when the device temporarily gets out of range (so you can get it back into range without having to restore the connection)

Regards,
Jonas

RiiiDD
Posts: 8
Joined: Tue Jun 23, 2009 8:48 pm

RE: Bluetools / lostconnection too long in slave

Thu Aug 06, 2009 1:34 pm

ty for reply but your answer surprise me.

YOu say it comes from the stack. But in fact, i can be using widcomm or microsoft and i get the same results. Are you sure you dont have a timeout in your objects ?

if i get out of range it s not a problem for me : i indicate the lost connection, the user connect back.

But the problem, it tooks me 20 sec to inform user that the connection is lost.
And even worst, if i try to reconnect in those 20 sec, that doesn't work.

It s too bad all works very fine except this, and this is a REAL big problem in my case :(

Jonas
Posts: 2319
Joined: Mon Jan 09, 2006 2:20 pm
Location: Sweden

RE: Bluetools / lostconnection too long in slave

Thu Aug 06, 2009 3:24 pm

Well, maybe. I don't know. It was just a guess.
I don't know of any way to change this timeout in any case.

Regards,
Jonas

Return to “BlueTools”