Return-Path: Message-ID: <5bab330d0602041925h53623f50h8560344f37a62d0d@mail.gmail.com> From: Nigel Sim To: bluez-devel@lists.sourceforge.net Subject: Re: [Bluez-devel] A2DP w/ Blueant headset In-Reply-To: <43A9B384.5040202@xmission.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_22099_9587040.1139109934498" References: <5bab330d0512192018o281f89a6l242586c487297e8f@mail.gmail.com> <43A78D40.7070209@xmission.com> <5bab330d0512201659w8af0301r7fd09cba76c6ca92@mail.gmail.com> <43A9B384.5040202@xmission.com> Sender: bluez-devel-admin@lists.sourceforge.net Errors-To: bluez-devel-admin@lists.sourceforge.net Reply-To: bluez-devel@lists.sourceforge.net List-Unsubscribe: , List-Id: BlueZ development List-Post: List-Help: List-Subscribe: , List-Archive: Date: Sun, 5 Feb 2006 13:25:34 +1000 ------=_Part_22099_9587040.1139109934498 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Brad, I've just cracked it. For some reason the avdtp_discover is not returning the codec list straight away (see the hci dump http://hpc-external.jcu.edu.au/~nigel/uploads/Main/brokenHCIDump.txt). Rather after the second command the required response is returned. This is what happens after a2play decides the stream discovery has failed, and it sends the disconnect signal. SO, I've just made it call this line twice: a2play.c:848 size =3D read(cmdfd, &get_resp, sizeof(get_resp)); And then the headset works! I wonder if the two byte reply means something like wait. The bytes are 0x0= 0 0x00, so I'm guessing that message_type =3D 0 and packet_type =3D 0. However, I seem to have to totally reset the headset between sessions. I'm not sure whats happening here. Is there a BT command I could send to make the device reset? Nigel On 12/22/05, Brad Midgley wrote: > > Nigel > > Your headset is misbehaving. We are supposed to be able to discover the > stream endpoint id in the reply to the avdtp_discover request. > > You could try adding code to work around this problem and guess at the > seid. The seid seems to always be 1 on my headsets. > > Brad > > > OK, new cvs version, I get this: > > mpg123 --au - /home/nigel/03\ -\ They\ Got\ Lost.mp3 | ./a2play > > 00:0A:56:00:B5:91 - > > subbands =3D 8 blocks =3D 16 bitpool =3D 32 > > High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and 3. > > Version 0.59q (2002/03/23). Written and copyrights by Joe Drew. > > ... > > MPEG 1.0 layer III, 128 kbit/s, 44100 Hz stereo > > len=3D2048 > > Header size=3D28 > > Sample Rate:44100 > > Channels:2 > > Using address: 00:0A:56:00:B5:91 > > Found A2DP Sink > > Found A2DP Sink at the destination > > Connected [imtu 672, omtu 672, flush_to 65535] > > Sent the Stream End Point Discovery Command > > couldn't get avdtp_discover (only 2 bytes read) > > > > On 12/20/05, *Brad Midgley* > > wrote: > > > > Nigel > > > > > A2DP with the bluetooth-alsa project doesn't work with the Bluean= t > > > stereo headphones, and by looking at this page it appears that it > > might > > > be because these headphones don't support AVDTP > > > (http://www.robertwebbe.nl/extendedA2DP.html > > ) Is this possible? > > > > if I remember my alphabet soup correctly, avdtp is a fundamental > part of > > a2dp. > > > > > couldn't get avdtp_discover > > > Sent the Stream End Point Discovery Command > > > > i'm not sure why it can't read this information back. perhaps the > > headset for some reason does not report any supported codecs? > > > > i've improved the debug output somewhat. you could try it again. > > > > brad > > > > > > ------------------------------------------------------- > > This SF.net email is sponsored by: Splunk Inc. Do you grep through > > log files > > for problems? Stop! Download the new AJAX search engine that make= s > > searching your log files as easy as surfing the web. DOWNLOAD > SPLUNK! > > http://ads.osdn.com/?ad_id=3D7637&alloc_id=3D16865&op=3Dclick > > > > _______________________________________________ > > Bluez-devel mailing list > > Bluez-devel@lists.sourceforge.net > > > > https://lists.sourceforge.net/lists/listinfo/bluez-devel > > > > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep through log > files > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! > http://ads.osdn.com/?ad_id=3D7637&alloc_id=3D16865&op=3Dclick > _______________________________________________ > Bluez-devel mailing list > Bluez-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/bluez-devel > ------=_Part_22099_9587040.1139109934498 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Brad, I've just cracked it. For some reason the avdtp_discover is not retur= ning the codec list straight away (see the hci dump http://hpc-extern= al.jcu.edu.au/~nigel/uploads/Main/brokenHCIDump.txt ). Rather after the second command the required response is returned. T= his is what happens after a2play decides the stream discovery has failed, a= nd it sends the disconnect signal. SO, I've just made it call this line twi= ce:
a2play.c:848    size =3D read(cmdfd, &get_resp, sizeof(ge= t_resp));

And then the headset works!

I wonder if the two byt= e reply means something like wait. The bytes are 0x00 0x00, so I'm guessing= that message_type =3D 0 and packet_type =3D 0.

However, I seem to have to totally reset the headset between sessio= ns. I'm not sure whats happening here. Is there a BT command I could send t= o make the device reset?

Nigel


On 12/22/05, Brad Midgley <bmidgley@xmission.com> wrote: Nigel

Your headset is misbehaving. We are supposed to be able to dis= cover the
stream endpoint id in the reply to the avdtp_discover request.=

You could try adding code to work around this problem and guess at = the
seid. The seid seems to always be 1 on my headsets.

Brad

= > OK, new cvs version, I get this:
> mpg123 --au - /home/nigel/03\= -\ They\ Got\ Lost.mp3 | ./a2play
> 00:0A:56:00:B5:91 -
> subb= ands =3D 8 blocks =3D 16 bitpool =3D 32
> High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and= 3.
> Version 0.59q (2002/03/23). Written and copyrights by Joe Drew.=
> ...
> MPEG 1.0 layer III, 128 kbit/s, 44100 Hz stereo
> len=3D2048
> Header size=3D28
> Sample Rate:44100
> = Channels:2
> Using address: 00:0A:56:00:B5:91
> Found A2DP Sink=
> Found A2DP Sink at the destination
> Connected [imtu 672, om= tu 672, flush_to 65535]
> Sent the Stream End Point Discovery Command
> couldn't get a= vdtp_discover (only 2 bytes read)
>
> On 12/20/05, *Brad Midgle= y* <bmidgley@xmission.com
> <mailto:bmidgley@xmiss= ion.com>> wrote:
>
>     Nigel>
>     > A2DP with the bluetooth-alsa pro= ject doesn't work with the Blueant
>     > stereo headphones, and by looking at this= page it appears that it
>     might
> = ;    > be because these headphones don't support AVDTP>     > ( http://www.robertwebbe.nl/extendedA2DP.html
>   &n= bsp; <http://www= .robertwebbe.nl/extendedA2DP.html>) Is this possible?
>
>= ;     if I remember my alphabet soup correctly, avdtp i= s a fundamental part of
>     a2dp.
>
>   &nb= sp; > couldn't get avdtp_discover
>     > S= ent the Stream End Point Discovery Command
>
>   = ;  i'm not sure why it can't read this information back. perhaps the >     headset for some reason does not report any su= pported codecs?
>
>     i've improved the d= ebug output somewhat. you could try it again.
>
>  &n= bsp;  brad
>
>
>     -----------= --------------------------------------------
>     This SF.net email is sponsored by: Splunk = Inc. Do you grep through
>     log files
>&= nbsp;    for problems?  Stop!  Download = the new AJAX search engine that makes
>     searc= hing your log files as easy as surfing the  web.  DOWNL= OAD SPLUNK!
>     http://ads.osdn.com/?ad_id=3D7637&a= mp;alloc_id=3D16865&op=3Dclick
>     <= http://ads.osdn.com/?ad_id=3D7637&alloc_id=3D16865&op=3Dclick&g= t;
>     ________________________________________= _______
>     Bluez-devel mailing list
>&nb= sp;    Bluez-devel@lists.sourceforge.net
>     <m= ailto:Bluez-devel@list= s.sourceforge.net>
>     https://lists.sourceforge.net/lists/listinfo/bluez-devel
>
>= ;



-------------------------------------------------------This SF.net email is sponsored by: Splunk Inc. Do you grep through log fil= es
for problems?  Stop!  Download the new AJAX search = engine that makes
searching your log files as easy as surfing the &= nbsp;web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=3D7637&alloc_id=3D16865&op=3Dclick_______________________________________________
Bluez-devel mailing li= st
Bluez-devel@list= s.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bluez-devel

------=_Part_22099_9587040.1139109934498-- ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642 _______________________________________________ Bluez-devel mailing list Bluez-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bluez-devel