2005-01-22 15:45:58

by Paul Ionescu

[permalink] [raw]
Subject: [Bluez-devel] snd-bt-sco blocking audio mode

Hi,

Currently when snd-bt-sco is loaded but btsco is not connected, any
attempt to play something will be blocked until a btsco connection is made.
Sometimes, a "play anyway" mode would be preferred.
Example:
If I watch a movie with mplayer with output to my headset, and I
disconnect the headset, the movie will stop playing, because snd-bt-sco is
not sending positive response.
Can snd-bt-sco be made to send positive response even if there is no
headset connected ?
This should be user selectable.

Thanks,
Paul




-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-devel


2005-01-23 15:57:46

by Lars Grunewaldt

[permalink] [raw]
Subject: Re: [Bluez-devel] snd-bt-sco blocking audio mode

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

the problem seems to be that we are reporting "interface available" even
if it's not. Maybe there's something like an "idle state" or such thing
so that we can have an existing alsa interface, but tell the application
it's not worth sending data?

The internal problem should be that snd-bt-sco reads the input buffer
only when the hardware buffer is filled. I think it's not possible to
simple "empty" the buffer when there's not output socket available,
because this should mess up the timing of the input application.

I never tested this, but someone on the list stated that it would be
like that.

But it should be possible to test this by modifiing the input buffer
read thread of snd-bt-sco...

best regards,
~ Lars

Brad Midgley wrote:
| Paul,
|
| Do you know what the OSS and ALSA api has to say about nonblocking
| open/write? I'm a little clueless here about whether or not we are
| producing the behavior the client is asking for.
|
| I do see what you mean. Another example for which you'd want nonblocking
| writes is live streaming.
|
| Brad
|
| Paul Ionescu wrote:
|
|> Hi,
|>
|> Currently when snd-bt-sco is loaded but btsco is not connected, any
|> attempt to play something will be blocked until a btsco connection is
|> made.
|> Sometimes, a "play anyway" mode would be preferred.
|> Example:
|> If I watch a movie with mplayer with output to my headset, and I
|> disconnect the headset, the movie will stop playing, because
|> snd-bt-sco is
|> not sending positive response.
|> Can snd-bt-sco be made to send positive response even if there is no
|> headset connected ?
|> This should be user selectable.
|>
|> Thanks,
|> Paul
|>
|>
|>
|>
|> -------------------------------------------------------
|> This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
|> Tool for open source databases. Create drag-&-drop reports. Save time
|> by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
|> Download a FREE copy at http://www.intelliview.com/go/osdn_nl
|> _______________________________________________
|> Bluez-devel mailing list
|> [email protected]
|> https://lists.sourceforge.net/lists/listinfo/bluez-devel
|
|
|
| -------------------------------------------------------
| This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
| Tool for open source databases. Create drag-&-drop reports. Save time
| by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
| Download a FREE copy at http://www.intelliview.com/go/osdn_nl
| _______________________________________________
| Bluez-devel mailing list
| [email protected]
| https://lists.sourceforge.net/lists/listinfo/bluez-devel
|


- --
Lars Grunewaldt
* software development
* multimedia design
skills: C/C++/Java/PHP/(X)HTML/Flash/audio/video
web: http://www.dark-reality.de
mail: [email protected]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFB88l5QWC6DTWkDAoRArEBAJ9Jt5lJa/tYA2QKdTFCDsa3NvzvbQCfd+ru
6GOVUnKk2QBvYtnk3QnuuN0=
=tQIw
-----END PGP SIGNATURE-----


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-devel

2005-01-23 04:46:14

by Brad Midgley

[permalink] [raw]
Subject: Re: [Bluez-devel] snd-bt-sco blocking audio mode

Paul,

Do you know what the OSS and ALSA api has to say about nonblocking
open/write? I'm a little clueless here about whether or not we are
producing the behavior the client is asking for.

I do see what you mean. Another example for which you'd want nonblocking
writes is live streaming.

Brad

Paul Ionescu wrote:
> Hi,
>
> Currently when snd-bt-sco is loaded but btsco is not connected, any
> attempt to play something will be blocked until a btsco connection is made.
> Sometimes, a "play anyway" mode would be preferred.
> Example:
> If I watch a movie with mplayer with output to my headset, and I
> disconnect the headset, the movie will stop playing, because snd-bt-sco is
> not sending positive response.
> Can snd-bt-sco be made to send positive response even if there is no
> headset connected ?
> This should be user selectable.
>
> Thanks,
> Paul
>
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
> Tool for open source databases. Create drag-&-drop reports. Save time
> by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
> Download a FREE copy at http://www.intelliview.com/go/osdn_nl
> _______________________________________________
> Bluez-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/bluez-devel


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-devel