From: Johan Hedberg <johan.hedberg@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH] doc: Add experimental handsfree-audio API
Date: Wed, 20 Feb 2013 11:19:43 +0200 [thread overview]
Message-ID: <20130220091943.GA17522@x220> (raw)
In-Reply-To: <CANT-zCXA0E-5MOu-KWu9HL=8e3BrPRavufd3cM3mY_-u3jaKvA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3175 bytes --]
Hi Mikel,
On Wed, Feb 20, 2013, Mikel Astiz wrote:
> > +Handsfree Audio Card hierarchy [experimental]
> > +==============================
> > +
> > +Service org.ofono
> > +Interface org.ofono.HandsfreeAudioCard
> > +Object path /{device0,device1,...}
>
> I'd propose dropping this interface entirely or at least using the
> conventional modem object path, assuming that every HandsfreeAudioCard
> would necessarily have an associated modem.
>
> After all, the Audio agent would typically have to match cards with
> modems, probably because the associated voicecall status needs to be
> known (e.g. if the HS wants to ignore the inband-ringing and instead
> use another ring tone).
What you describe would only cover the HF role of HFP but not AG. With
AG you can have multiple HF devices connected to you (hence multiple
"cards") while still having just one oFono modem object.
> > +Methods dict GetProperties()
> > +
> > + Returns properties for the device object. See
> > + the properties section for available properties.
> > +
> > + void Connect()
> > +
> > + Attempts to establish the SCO audio connection.
> > + The Agent NewConnection() method will be called
> > + whenever the SCO audio link has been established. If
> > + the audio connection could not be established, this
> > + method will return an error.
>
> Isn't Disconnect() missing here? How would the agent release an SCO?
I think the idea was that the client can just use the shutdown() system
call.
> > +Handsfree Audio Agent hierarchy [experimental]
> > +===============================
> > +
> > +Service <freely defined>
> > +Interface org.ofono.HandsfreeAudioAgent
> > +Object <freely defined>
> > +
> > +Methods void NewConnection(object card, fd sco, byte codec)
> > +
> > + Notifies the handler that a new SCO connection is
> > + available. Returning an error will cause oFono to
> > + disconnect the SCO connection.
>
> Same here. How would the agent receive a release-notification? Perhaps
> this would be implicit in the socket HUP?
I think that was the idea (but I'll let Denis clarify if I'm wrong).
> If so, I have some concerns about the potential race conditions. If
> SCO was closed and reopen immediately afterwards, the client could
> receive the (second) NewConnection before the HUP.
>
> Besides, is this D-Bus API intended to support SCO-over-PCM as well?
> If yes, several considerations seems to be missing, specially
> regarding the socket fd. In particular, the HUP approach for
> disconnections would not be valid anymore.
I don't see why it would not be valid. Even if you do SCO over PCM the
SCO socket will give you the right connection state info since it's
hooked to the same connect and disconnect HCI events which occur
regardless of how you route the SCO data.
Johan
next prev parent reply other threads:[~2013-02-20 9:19 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-20 8:04 [PATCH] doc: Add experimental handsfree-audio API Mikel Astiz
2013-02-20 8:55 ` Mikel Astiz
2013-02-20 9:19 ` Frederic Danis
2013-02-20 9:19 ` Johan Hedberg [this message]
2013-02-20 11:04 ` Mikel Astiz
2013-02-20 15:45 ` Denis Kenzior
2013-02-20 16:50 ` Mikel Astiz
2013-02-20 17:34 ` Denis Kenzior
2013-02-22 10:06 ` Mikel Astiz
2013-02-22 19:14 ` Denis Kenzior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130220091943.GA17522@x220 \
--to=johan.hedberg@gmail.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.