From mboxrd@z Thu Jan 1 00:00:00 1970 Content-Type: multipart/mixed; boundary="===============4280266157136423132==" MIME-Version: 1.0 From: Johan Hedberg Subject: Re: [RFC v0 01/11] hfp_hf: Add HFP external Profile registration Date: Mon, 26 Nov 2012 13:08:41 +0200 Message-ID: <20121126110841.GA24078@x220> In-Reply-To: <1353606808-25032-2-git-send-email-claudio.takahasi@openbossa.org> List-Id: To: ofono@ofono.org --===============4280266157136423132== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Claudio, On Thu, Nov 22, 2012, Claudio Takahasi wrote: > +int bluetooth_register_profile(const char *uuid, const char *name, > + const char *object) > +{ > + DBusMessageIter iter, dict; > + DBusPendingCall *c; > + DBusMessage *msg; > + > + DBG("Bluetooth: Registering %s (%s) profile", uuid, name); > + > + msg =3D dbus_message_new_method_call(BLUEZ_SERVICE, "/org/bluez", > + BLUEZ_PROFILE_MGMT_INTERFACE, "RegisterProfile"); > + > + dbus_message_iter_init_append(msg, &iter); > + dbus_message_iter_append_basic(&iter, DBUS_TYPE_OBJECT_PATH, &object); > + dbus_message_iter_append_basic(&iter, DBUS_TYPE_STRING, &uuid); > + > + dbus_message_iter_open_container(&iter, DBUS_TYPE_ARRAY, "{sv}", &dict); > + dict_append_entry(&dict, "Name", DBUS_TYPE_STRING, &name); > + dbus_message_iter_close_container(&iter, &dict); You're missing the "AutoConnect" dict entry here. Without it HFP will not be connected using Device.Connect (only remotely initiated or with Device.ConnectProfile). Johan --===============4280266157136423132==--