rfcomm_pppd fails (T40p and Nokia 7650)

Maksim Yevmenkin m_evmenkin at yahoo.com
Sun Aug 3 14:51:43 PDT 2003


Hello Peter,
 
> after much delay...
> 
> > >         rfcomm_pppd[39117]: Could not connect socket. Connection refused
> > > (61)
> > 
> > this means that PC was not able to establish Bluetooth RFCOMM connection.
> > perhaps phone rejected it, or could be other reason. i would like to see
> > HCI dump. could you please compile hcidump(1) from the snapshot's ports/
> > directory and then run it 
> 
> As I mentioned I am still getting occational "connection refused" messages.
> Retrying always solves it. Following are two typescripts from an hcidump
> session. The first contains the dump during two sessions where there was no
> rfcomm problems. First there is a session that failes due to a "NO CARRIER"
> error from the phone (I am consistently getting this on every other
> connection attempt, so I always have to initiate a connect twice, but I
> assume it has nothing what so ever to do with rfcomm), and the second is
> from a fully successful connection. I figured I'd include this for reference
> just in case.

thank you very much for these traces. yes, the "NO CARRIER" error is not
RFCOMM's fault. Bluetooth/RFCOMM in fact work because you can send commands
to the phone and receive replies back. so "NO CARRIER" means that your phone
was not able to establish GPRS connection. just like a normal modem sometimes
can not establish connection to the modem on the other end.
 
> The second contains the dump from an attempt where I got the connection
> refused error. I don't know if it is useful though given that it's just one
> command and two events.

right

  Script started on Sat Aug  2 16:20:16 2003
  thunderbolt# hcidump -x

  HCIDump - HCI packet analyzer ver 1.4
  device: any snap_len: 65535 filter: 0xffffffff

  < HCI Command: Create Connection(0x01|0x0005) plen 13
    0B 89 73 EE 02 00 18 CC 00 00 00 00 01 

this command ask local (attached to the PC) device to create baseband 
connection to the remote device with BD_ADDR 00:02:EE:73:89:0B

  > HCI Event: Command Status(0x0f) plen 4
    00 01 05 04 

this is local device tells that it has received the command and started
execution of the command (status == 0x00).

  > HCI Event: Connect Complete(0x03) plen 11
    04 00 00 0B 89 73 EE 02 00 01 00 

this is local device tells that it has failed to create baseband connection
to the remote with BD_ADDR 00:02:EE:73:89:0B (link type ACL/no encryption).
the status code is 0x04 - Page Timeout. 

bottom line: the local device has failed to create baseband connection to the
phone. when device is idle the radio is only turned on for a brief periods of
time to scan for page attempts (from remote devices). it is possible for the
device to miss such page attempt and thus incoming connection may fail. i
think
that is what might be going on. 

could you please put your phone into "discoverable" mode, run 
"hccontrol -n <dev>hci inquiry" and send me the output?

> Btw, in order to compile hcidump successfully (make depend && make && make
> install) I had to comment out line 209 and 210 of parse/sdp.c. Otherwise
> it would complain about the size of 0x1000.....000L being too big for its
> type. (I just commented it out because I wasn't sure how to deal with
> numbers that large in C. I'm not sure if mishandling 128 bit numbers
> in print_int screwed up anything in the above dumps though.)

thank you for the report. i will take a look and fix this.

> Again, I can live with occational "connection refused" messages. So look at
> this if you feel it is of interest for improving the code; otherwise
> nevermind.

of course i'm interesting in improving the code :) btw, do you have the same
problems on other systems (Windows or Linux)?

thanks,
max

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com


More information about the freebsd-mobile mailing list