You Are Here:

Community: Developer Discussion Boards

#1 Old Bluetooth cancel Connection - 2007-02-03, 17:17

Join Date: Jun 2006
Posts: 11
goonii
Offline
Registered User
Hallo,
I'm playing a bit with the Avetana Library and i try to send
a txt file from a Sony Ericsson to a Nokia 6600 using the OPP (0x1105).

This is the code:
Code:
cs = (ClientSession) OBEXConnector.open(myConUrl);
HeaderSet hs = cs.connect(cs.createHeaderSet());
hs.setHeader (HeaderSet.NAME, "test.txt");
hs.setHeader (HeaderSet.TYPE, "text");
po = cs.put(hs);
po.openOutputStream().write(text);
po.close();
cs.disconnect(null);
cs.close();
It works fine, but my Problem is:
If i connect to the Nokia and the User does NOT press any button ('yes' or 'no') for
accepting connection my code is stopping here:
Code:
cs = (ClientSession) OBEXConnector.open (myConUrl);
That is ok, but how can i cancel that Process without waiting for the Timeout (up to 2 min.) ?

I hope, you know what I mean!

Thank you for help!

goonii
Reply With Quote

#2 Old Re: Bluetooth cancel Connection - 2007-02-05, 12:42

Join Date: Jun 2006
Posts: 11
goonii
Offline
Registered User
Really nobody knows how to solve that Problem?
Reply With Quote

#3 Old Re: Bluetooth cancel Connection - 2007-02-05, 17:59

Join Date: Dec 2005
Posts: 1,159
Location: England,UK
jimgilmour1's Avatar
jimgilmour1
Offline
Forum Nokia Champion
Quote:
Originally Posted by goonii
Hallo,
I'm playing a bit with the Avetana Library and i try to send
a txt file from a Sony Ericsson to a Nokia 6600 using the OPP (0x1105).

That is ok, but how can i cancel that Process without waiting for the Timeout (up to 2 min.) ?

I hope, you know what I mean!

Thank you for help!

goonii
Have you paired with the other device if no then you will get this message.
There is no way to bypass this as its a security feature.

Jim
Last edited by jimgilmour1 : 2007-02-05 at 19:57.
Reply With Quote

#4 Old Re: Bluetooth cancel Connection - 2007-02-05, 18:27

Join Date: Jun 2006
Posts: 11
goonii
Offline
Registered User
Quote:
There is no way to by pass this as its a security feature.
I don't try to by pass any security features. I only try to cancel that connection process.
On all other Devices it works fine.
Reply With Quote

#5 Old Re: Bluetooth cancel Connection - 2007-02-05, 20:14

Join Date: Dec 2005
Posts: 1,159
Location: England,UK
jimgilmour1's Avatar
jimgilmour1
Offline
Forum Nokia Champion
Hi,
You have an encountered problem with 6600
see
"Known Issues In The Nokia 6600 MIDP 2.0"

http://discussion.forum.nokia.com/fo...highlight=6600
Quote:
Reading incoming stream does not work properly. When the Bluetooth Serial Port Profile (RFCOMM protocol) is used, reading incoming stream is sometimes interrupted with IOException. The read() method of the InputStream class may throw an IOException if the other end has closed the stream while the InputStream is still reading it.
I believe the problem is probably due to an i/o error, hence the cancel is ignored

Jim
Reply With Quote

#6 Old Re: Bluetooth cancel Connection - 2007-02-05, 22:26

Join Date: Jun 2006
Posts: 11
goonii
Offline
Registered User
Ok, thank you Jim!

goonii
Reply With Quote
Reply « Previous Thread | Next Thread »
Display Modes
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules

You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump
Similar Threads
Thread Thread Starter Forum Replies Last Post
Internet connection over Bluetooth (6600<->PC) cbruegg Bluetooth Technology 0 2003-11-12 20:28
Ipaq 5450 and Nokia 8910/i bluetooth connection ferceska Bluetooth Technology 0 2003-07-07 15:23
Connection Manager does not with 6310i over bluetooth with ACER USB Stick BT 500 haumi General Discussion 0 2003-07-06 12:58
sharing internet connection over bluetooth naivri Bluetooth Technology 2 2003-06-02 21:50
GPRS Connection from Laptop over Bluetooth ChicMac Bluetooth Technology 1 2003-05-19 19:22

Rate This

 
Bookmark this page: DeliciousDiggFacebookGoogleYahooStumbleUponRedditDiigoTechnocratiTwitter  Share this page Share this page Print this Page Print this page Invite a friend Invite a friend
京ICP备05048969号    Email Newsletters Press Terms & Conditions Privacy Policy Sitemap Contact Us © 2009 Nokia