Hi Claudio,

On 02/28/2013 12:52 PM, Claudio Takahasi wrote:
This patch adds a new function to read the local supported Handsfree
Profile version.
---
  include/handsfree-audio.h | 1 +
  src/handsfree-audio.c     | 5 +++++
  2 files changed, 6 insertions(+)

diff --git a/include/handsfree-audio.h b/include/handsfree-audio.h
index c5403c7..96597c2 100644
--- a/include/handsfree-audio.h
+++ b/include/handsfree-audio.h
@@ -34,6 +34,7 @@ struct ofono_handsfree_card 
*ofono_handsfree_card_create(const char *remote,
                                                        const char *local);
  int ofono_handsfree_card_register(struct ofono_handsfree_card *card);
  void ofono_handsfree_card_remove(struct ofono_handsfree_card *card);
+enum hfp_version ofono_handsfree_get_version();


I'd like to avoid such details in the card functionality.

Are our possible scenarios the following?

1. SCO defer in kernel, CVSD mSBC supported
2. SCO defer not in kernel, CVSD mSBC supported
3. SCO defer in kernel, CVSD supported
4. SCO defer not in kernel, CVSD supported

If so, can we always advertise HFP 1.6, but only declare support for CVSD in case 2?

  void ofono_handsfree_audio_ref(void);
  void ofono_handsfree_audio_unref(void);
diff --git a/src/handsfree-audio.c b/src/handsfree-audio.c
index d0ccf29..955c6ef 100644
--- a/src/handsfree-audio.c
+++ b/src/handsfree-audio.c
@@ -363,6 +363,11 @@ void ofono_handsfree_card_remove(struct 
ofono_handsfree_card *card)
        g_free(card);
  }

+enum hfp_version ofono_handsfree_get_version()
+{
+       return local_hfp_version;
+}
+
  static void agent_free(struct agent *agent)
  {
        if (agent->watch>  0)

Regards,
-Denis
_______________________________________________
ofono mailing list
ofono@ofono.org
http://lists.ofono.org/listinfo/ofono

Reply via email to