summaryrefslogtreecommitdiff
path: root/contrib/bluez-api-5.20-fixed
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/bluez-api-5.20-fixed')
-rw-r--r--contrib/bluez-api-5.20-fixed/adapter-api.txt155
-rw-r--r--contrib/bluez-api-5.20-fixed/agent-api.txt182
-rw-r--r--contrib/bluez-api-5.20-fixed/agent.xml37
-rw-r--r--contrib/bluez-api-5.20-fixed/alert-api.txt108
-rw-r--r--contrib/bluez-api-5.20-fixed/assigned-numbers.txt24
-rw-r--r--contrib/bluez-api-5.20-fixed/cyclingspeed-api.txt99
-rw-r--r--contrib/bluez-api-5.20-fixed/device-api.txt195
-rw-r--r--contrib/bluez-api-5.20-fixed/health-api.txt152
-rw-r--r--contrib/bluez-api-5.20-fixed/heartrate-api.txt77
-rw-r--r--contrib/bluez-api-5.20-fixed/media-api.txt646
-rw-r--r--contrib/bluez-api-5.20-fixed/mgmt-api.txt2324
-rw-r--r--contrib/bluez-api-5.20-fixed/network-api.txt76
-rw-r--r--contrib/bluez-api-5.20-fixed/obex-agent-api.txt61
-rw-r--r--contrib/bluez-api-5.20-fixed/obex-api.txt834
-rw-r--r--contrib/bluez-api-5.20-fixed/obex_agent.xml13
-rw-r--r--contrib/bluez-api-5.20-fixed/profile-api.txt147
-rw-r--r--contrib/bluez-api-5.20-fixed/proximity-api.txt56
-rw-r--r--contrib/bluez-api-5.20-fixed/sap-api.txt20
-rw-r--r--contrib/bluez-api-5.20-fixed/settings-storage.txt228
-rw-r--r--contrib/bluez-api-5.20-fixed/supported-features.txt52
-rw-r--r--contrib/bluez-api-5.20-fixed/test-coverage.txt69
-rw-r--r--contrib/bluez-api-5.20-fixed/thermometer-api.txt134
22 files changed, 5689 insertions, 0 deletions
diff --git a/contrib/bluez-api-5.20-fixed/adapter-api.txt b/contrib/bluez-api-5.20-fixed/adapter-api.txt
new file mode 100644
index 0000000..74d235a
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/adapter-api.txt
@@ -0,0 +1,155 @@
+BlueZ D-Bus Adapter API description
+***********************************
+
+
+Adapter hierarchy
+=================
+
+Service org.bluez
+Interface org.bluez.Adapter1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods void StartDiscovery()
+
+ This method starts the device discovery session. This
+ includes an inquiry procedure and remote device name
+ resolving. Use StopDiscovery to release the sessions
+ acquired.
+
+ This process will start creating Device objects as
+ new devices are discovered.
+
+ Possible errors: org.bluez.Error.NotReady
+ org.bluez.Error.Failed
+
+ void StopDiscovery()
+
+ This method will cancel any previous StartDiscovery
+ transaction.
+
+ Note that a discovery procedure is shared between all
+ discovery sessions thus calling StopDiscovery will only
+ release a single session.
+
+ Possible errors: org.bluez.Error.NotReady
+ org.bluez.Error.Failed
+ org.bluez.Error.NotAuthorized
+
+ void RemoveDevice(object device)
+
+ This removes the remote device object at the given
+ path. It will remove also the pairing information.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.Failed
+
+Properties string Address [readonly]
+
+ The Bluetooth device address.
+
+ string Name [readonly]
+
+ The Bluetooth system name (pretty hostname).
+
+ This property is either a static system default
+ or controlled by an external daemon providing
+ access to the pretty hostname configuration.
+
+ string Alias [readwrite]
+
+ The Bluetooth friendly name. This value can be
+ changed.
+
+ In case no alias is set, it will return the system
+ provided name. Setting an empty string as alias will
+ convert it back to the system provided name.
+
+ When resetting the alias with an empty string, the
+ property will default back to system name.
+
+ On a well configured system, this property never
+ needs to be changed since it defaults to the system
+ name and provides the pretty hostname. Only if the
+ local name needs to be different from the pretty
+ hostname, this property should be used as last
+ resort.
+
+ uint32 Class [readonly]
+
+ The Bluetooth class of device.
+
+ This property represents the value that is either
+ automatically configured by DMI/ACPI information
+ or provided as static configuration.
+
+ boolean Powered [readwrite]
+
+ Switch an adapter on or off. This will also set the
+ appropriate connectable state of the controller.
+
+ The value of this property is not persistent. After
+ restart or unplugging of the adapter it will reset
+ back to false.
+
+ boolean Discoverable [readwrite]
+
+ Switch an adapter to discoverable or non-discoverable
+ to either make it visible or hide it. This is a global
+ setting and should only be used by the settings
+ application.
+
+ If the DiscoverableTimeout is set to a non-zero
+ value then the system will set this value back to
+ false after the timer expired.
+
+ In case the adapter is switched off, setting this
+ value will fail.
+
+ When changing the Powered property the new state of
+ this property will be updated via a PropertyChanged
+ signal.
+
+ For any new adapter this settings defaults to false.
+
+ boolean Pairable [readwrite]
+
+ Switch an adapter to pairable or non-pairable. This is
+ a global setting and should only be used by the
+ settings application.
+
+ Note that this property only affects incoming pairing
+ requests.
+
+ For any new adapter this settings defaults to true.
+
+ uint32 PairableTimeout [readwrite]
+
+ The pairable timeout in seconds. A value of zero
+ means that the timeout is disabled and it will stay in
+ pairable mode forever.
+
+ The default value for pairable timeout should be
+ disabled (value 0).
+
+ uint32 DiscoverableTimeout [readwrite]
+
+ The discoverable timeout in seconds. A value of zero
+ means that the timeout is disabled and it will stay in
+ discoverable/limited mode forever.
+
+ The default value for the discoverable timeout should
+ be 180 seconds (3 minutes).
+
+ boolean Discovering [readonly]
+
+ Indicates that a device discovery procedure is active.
+
+ array{string} UUIDs [readonly]
+
+ List of 128-bit UUIDs that represents the available
+ local services.
+
+ string Modalias [readonly, optional]
+
+ Local Device ID information in modalias format
+ used by the kernel and udev.
diff --git a/contrib/bluez-api-5.20-fixed/agent-api.txt b/contrib/bluez-api-5.20-fixed/agent-api.txt
new file mode 100644
index 0000000..c6a024c
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/agent-api.txt
@@ -0,0 +1,182 @@
+BlueZ D-Bus Agent API description
+**********************************
+
+
+Agent Manager hierarchy
+=======================
+
+Service org.bluez
+Interface org.bluez.AgentManager1
+Object path /org/bluez
+
+Methods void RegisterAgent(object agent, string capability)
+
+ This registers an agent handler.
+
+ The object path defines the path of the agent
+ that will be called when user input is needed.
+
+ Every application can register its own agent and
+ for all actions triggered by that application its
+ agent is used.
+
+ It is not required by an application to register
+ an agent. If an application does chooses to not
+ register an agent, the default agent is used. This
+ is on most cases a good idea. Only application
+ like a pairing wizard should register their own
+ agent.
+
+ An application can only register one agent. Multiple
+ agents per application is not supported.
+
+ The capability parameter can have the values
+ "DisplayOnly", "DisplayYesNo", "KeyboardOnly",
+ "NoInputNoOutput" and "KeyboardDisplay" which
+ reflects the input and output capabilities of the
+ agent.
+
+ If an empty string is used it will fallback to
+ "DisplayYesNo".
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.AlreadyExists
+
+ void UnregisterAgent(object agent)
+
+ This unregisters the agent that has been previously
+ registered. The object path parameter must match the
+ same value that has been used on registration.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+
+ void RequestDefaultAgent(object agent)
+
+ This requests is to make the application agent
+ the default agent. The application is required
+ to register an agent.
+
+ Special permission might be required to become
+ the default agent.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+
+
+Agent hierarchy
+===============
+
+Service unique name
+Interface org.bluez.Agent1
+Object path freely definable
+
+Methods void Release()
+
+ This method gets called when the service daemon
+ unregisters the agent. An agent can use it to do
+ cleanup tasks. There is no need to unregister the
+ agent, because when this method gets called it has
+ already been unregistered.
+
+ string RequestPinCode(object device)
+
+ This method gets called when the service daemon
+ needs to get the passkey for an authentication.
+
+ The return value should be a string of 1-16 characters
+ length. The string can be alphanumeric.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void DisplayPinCode(object device, string pincode)
+
+ This method gets called when the service daemon
+ needs to display a pincode for an authentication.
+
+ An empty reply should be returned. When the pincode
+ needs no longer to be displayed, the Cancel method
+ of the agent will be called.
+
+ This is used during the pairing process of keyboards
+ that don't support Bluetooth 2.1 Secure Simple Pairing,
+ in contrast to DisplayPasskey which is used for those
+ that do.
+
+ This method will only ever be called once since
+ older keyboards do not support typing notification.
+
+ Note that the PIN will always be a 6-digit number,
+ zero-padded to 6 digits. This is for harmony with
+ the later specification.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ uint32 RequestPasskey(object device)
+
+ This method gets called when the service daemon
+ needs to get the passkey for an authentication.
+
+ The return value should be a numeric value
+ between 0-999999.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void DisplayPasskey(object device, uint32 passkey,
+ uint16 entered)
+
+ This method gets called when the service daemon
+ needs to display a passkey for an authentication.
+
+ The entered parameter indicates the number of already
+ typed keys on the remote side.
+
+ An empty reply should be returned. When the passkey
+ needs no longer to be displayed, the Cancel method
+ of the agent will be called.
+
+ During the pairing process this method might be
+ called multiple times to update the entered value.
+
+ Note that the passkey will always be a 6-digit number,
+ so the display should be zero-padded at the start if
+ the value contains less than 6 digits.
+
+ void RequestConfirmation(object device, uint32 passkey)
+
+ This method gets called when the service daemon
+ needs to confirm a passkey for an authentication.
+
+ To confirm the value it should return an empty reply
+ or an error in case the passkey is invalid.
+
+ Note that the passkey will always be a 6-digit number,
+ so the display should be zero-padded at the start if
+ the value contains less than 6 digits.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void RequestAuthorization(object device)
+
+ This method gets called to request the user to
+ authorize an incoming pairing attempt which
+ would in other circumstances trigger the just-works
+ model.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void AuthorizeService(object device, string uuid)
+
+ This method gets called when the service daemon
+ needs to authorize a connection/service request.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void Cancel()
+
+ This method gets called to indicate that the agent
+ request failed before a reply was returned.
diff --git a/contrib/bluez-api-5.20-fixed/agent.xml b/contrib/bluez-api-5.20-fixed/agent.xml
new file mode 100644
index 0000000..c5f92e1
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/agent.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<node name="/org/blueztools">
+ <interface name="org.bluez.Agent1">
+ <method name="Release">
+ </method>
+ <method name="RequestPinCode">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="pincode" direction="out" type="s"/>
+ </method>
+ <method name="DisplayPinCode">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="pincode" direction="in" type="s"/>
+ </method>
+ <method name="RequestPasskey">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="passkey" direction="out" type="u"/>
+ </method>
+ <method name="DisplayPasskey">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="passkey" direction="in" type="u"/>
+ <arg name="entered" direction="in" type="q"/>
+ </method>
+ <method name="RequestConfirmation">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="passkey" direction="in" type="u"/>
+ </method>
+ <method name="RequestAuthorization">
+ <arg name="device" direction="in" type="o"/>
+ </method>
+ <method name="AuthorizeService">
+ <arg name="device" direction="in" type="o"/>
+ <arg name="uuid" direction="in" type="s"/>
+ </method>
+ <method name="Cancel">
+ </method>
+ </interface>
+</node>
diff --git a/contrib/bluez-api-5.20-fixed/alert-api.txt b/contrib/bluez-api-5.20-fixed/alert-api.txt
new file mode 100644
index 0000000..fc427c8
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/alert-api.txt
@@ -0,0 +1,108 @@
+BlueZ D-Bus Alert API description
+*********************************
+
+
+Introduction
+------------
+
+Currently, there are two different GATT server profiles that depend on
+receiving alerts or notifications from the platform: Phone Alert Status (PASP)
+and Alert Notification (ANP). PASP is very specific to mobile phones, and also
+allows limited control to alerts (i.e. mute once or switch to a silent mode).
+
+This document presents a unified API that allows to register and notify alerts,
+and to control some alerts (using the provided agent object).
+
+
+Alert hierarchy
+===============
+
+Service org.bluez
+Interface org.bluez.Alert1
+Object path /org/bluez
+
+Methods void RegisterAlert(string category, object agent)
+
+ Register a new alert category and an agent for it. This
+ means the application will be responsible for notifying
+ BlueZ of any alerts of that category, using the
+ NewAlert() method.
+
+ Supported ANP categories: simple, email, news, call,
+ missed-call, sms-mms, voice-mail, schedule,
+ high-priority, instant-message
+ Supported PASP categories: ringer, vibrate, display
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ void NewAlert(string category, uint16 count, string description)
+
+ Notify BlueZ of new alert(s) for the given category. The
+ description is relative to the last received alert and
+ can be sender name, caller ID, title, or other
+ information specific to the category.
+
+ For ringer, vibrate and display categories, valid
+ descriptions are "active" and "not active". Alerts from
+ ringer category also accept "enabled" and "disabled",
+ depending on whether ringer is in silent mode or not.
+
+ Description must not exceed 18 bytes when encoded in
+ UTF-8 format, otherwise an error is returned. If there
+ is no description, an empty string should be used.
+
+ The count argument contains the number of alerts not
+ yet acknowledged by the user on the UI. To save D-Bus
+ traffic, events that may generate multiple alerts at
+ the same time (like email, sms, news) should trigger a
+ single NewAlert().
+
+ If there are more than 254 new alerts, count must be
+ set to 255. PASP alerts should always set count to 1.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ void UnreadAlert(string category, uint16 count)
+
+ Some services (like SMS and e-mail) keep track of
+ number of unread items. This method allows to update
+ this counter, so peer devices can be notified using
+ Alert Notification Profile.
+
+ If there are more than 254 unread alerts, count must be
+ set to 255.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+Alert Agent hierarchy
+=====================
+
+Service org.bluez
+Interface org.bluez.AlertAgent1
+Object path freely definable
+
+Methods void MuteOnce()
+
+ This method is only called if "ringer" alert category
+ is specified when registering the agent.
+
+ Mute the ringer once (e.g. during a incoming call). If
+ ringer is not active, does nothing.
+
+ void SetRinger(string mode)
+
+ This method is only called if "ringer" alert category
+ is specified when registering the agent.
+
+ Set ringer to the specified mode. If mode is "enabled",
+ ringer is set to the default mode, as defined by the
+ current active profile. If mode is "disabled", ringer
+ will not activate on incoming calls, until it is set
+ back to "enabled" mode.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ void Release()
+
+ Release this agent. At this point, it will not be used
+ by BlueZ anymore and can be destroyed by the owner.
diff --git a/contrib/bluez-api-5.20-fixed/assigned-numbers.txt b/contrib/bluez-api-5.20-fixed/assigned-numbers.txt
new file mode 100644
index 0000000..ca171c4
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/assigned-numbers.txt
@@ -0,0 +1,24 @@
+RFCOMM Channels
+===============
+
+Since there are a limited amount of possible RFCOMM channels (1-31)
+they've been pre-allocated for currently known profiles in order to
+avoid conflicts.
+
+Profile Channel
+-----------------------
+DUN 1
+HFP HF 7
+OPP 9
+FTP 10
+BIP 11
+HSP AG 12
+HFP AG 13
+SYNCH (IrMC) 14
+PBAP 15
+MAP MAS 16
+MAP MNS 17
+SyncEvolution 19
+PC/Ovi Suite 24
+SyncML Client 25
+SyncML Server 26
diff --git a/contrib/bluez-api-5.20-fixed/cyclingspeed-api.txt b/contrib/bluez-api-5.20-fixed/cyclingspeed-api.txt
new file mode 100644
index 0000000..a1f1a93
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/cyclingspeed-api.txt
@@ -0,0 +1,99 @@
+Cycling Speed and Cadence API description
+*****************************************
+
+
+Cycling Speed and Cadence Manager hierarchy
+===========================================
+
+Service org.bluez
+Interface org.bluez.CyclingSpeedManager1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods RegisterWatcher(object agent)
+
+ Registers a watcher to monitor cycling speed and
+ cadence measurements.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ UnregisterWatcher(object agent)
+
+ Unregisters a watcher.
+
+Cycling Speed and Cadence Profile hierarchy
+===========================================
+
+Service org.bluez
+Interface org.bluez.CyclingSpeed1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods SetCumulativeWheelRevolutions(uint32 value)
+
+ Sets cumulative wheel revolutions value if
+ Cumulative Wheel Revolutions feature is supported.
+
+ Possible Errors: org.bluez.Error.NotSupported
+
+Properties string Location (optional) [readwrite]
+
+ Current sensor location, if supported.
+ If Multiple Sensor Locations feature is supported,
+ this property can be set to one of values read from
+ SupportedLocations property.
+
+ Possible values: "other", "top-of-shoe", "in-shoe",
+ "hip", "front-wheel", "left-crank",
+ "right-crank", "left-pedal",
+ "right-pedal", "front-hub",
+ "rear-dropout", "chainstay",
+ "rear-wheel", "rear-hub"
+
+ array{string} SupportedLocations (optional) [readonly]
+
+ List of locations supported by sensor, only present
+ if Multiple Sensor Locations feature is supported.
+
+ boolean WheelRevolutionDataSupported [readonly]
+
+ true if sensor can read and set Cumulative Wheel
+ Revolutions value, false otherwise.
+
+ boolean MultipleLocationsSupported [readonly]
+
+ true if sensor supports Multiple Sensor Locations
+ feature and can set Location, false otherwise.
+
+Cycling Speed and Cadence Watcher hierarchy
+===========================================
+
+Service unique name
+Interface org.bluez.CyclingSpeedWatcher1
+Object path freely definable
+
+Methods void MeasurementReceived(object device, dict measurement)
+
+ This callback is called whenever wheel and/or crank
+ revolutions measurement is received from sensor.
+
+ Measurement:
+
+ uint32 WheelRevolutions (optional):
+
+ Cumulative number of wheel revolutions.
+
+ uint16 LastWheelEventTime (optional):
+
+ Time of last event from wheel sensor.
+ Value is expressed in 1/1024 second
+ units and can roll over during a ride.
+
+ uint16 CrankRevolutions (optional):
+
+ Cumulative number of crank revolutions.
+ This value can occasionally roll over.
+
+ uint16 LastCrankEventTime (optional):
+
+ Time of last event from crank sensor.
+ Value is expressed in 1/1024 second
+ units and can roll over during a ride.
diff --git a/contrib/bluez-api-5.20-fixed/device-api.txt b/contrib/bluez-api-5.20-fixed/device-api.txt
new file mode 100644
index 0000000..577ee60
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/device-api.txt
@@ -0,0 +1,195 @@
+BlueZ D-Bus Device API description
+**********************************
+
+
+Device hierarchy
+================
+
+Service org.bluez
+Interface org.bluez.Device1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods void Connect()
+
+ This is a generic method to connect any profiles
+ the remote device supports that can be connected
+ to and have been flagged as auto-connectable on
+ our side. If only subset of profiles is already
+ connected it will try to connect currently disconnected
+ ones.
+
+ If at least one profile was connected successfully this
+ method will indicate success.
+
+ Possible errors: org.bluez.Error.NotReady
+ org.bluez.Error.Failed
+ org.bluez.Error.InProgress
+ org.bluez.Error.AlreadyConnected
+
+ void Disconnect()
+
+ This method gracefully disconnects all connected
+ profiles and then terminates low-level ACL connection.
+
+ ACL connection will be terminated even if some profiles
+ were not disconnected properly e.g. due to misbehaving
+ device.
+
+ This method can be also used to cancel a preceding
+ Connect call before a reply to it has been received.
+
+ Possible errors: org.bluez.Error.NotConnected
+
+ void ConnectProfile(string uuid)
+
+ This method connects a specific profile of this
+ device. The UUID provided is the remote service
+ UUID for the profile.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+ org.bluez.Error.AlreadyConnected
+ org.bluez.Error.ConnectFailed
+
+ void DisconnectProfile(string uuid)
+
+ This method disconnects a specific profile of
+ this device. The profile needs to be registered
+ client profile.
+
+ There is no connection tracking for a profile, so
+ as long as the profile is registered this will always
+ succeed.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+ org.bluez.Error.Failed
+ org.bluez.Error.NotConnected
+ org.bluez.Error.NotSupported
+
+ void Pair()
+
+ This method will connect to the remote device,
+ initiate pairing and then retrieve all SDP records
+ (or GATT primary services).
+
+ If the application has registered its own agent,
+ then that specific agent will be used. Otherwise
+ it will use the default agent.
+
+ Only for applications like a pairing wizard it
+ would make sense to have its own agent. In almost
+ all other cases the default agent will handle
+ this just fine.
+
+ In case there is no application agent and also
+ no default agent present, this method will fail.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.Failed
+ org.bluez.Error.AlreadyExists
+ org.bluez.Error.AuthenticationCanceled
+ org.bluez.Error.AuthenticationFailed
+ org.bluez.Error.AuthenticationRejected
+ org.bluez.Error.AuthenticationTimeout
+ org.bluez.Error.ConnectionAttemptFailed
+
+ void CancelPairing()
+
+ This method can be used to cancel a pairing
+ operation initiated by the Pair method.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+ org.bluez.Error.Failed
+
+Properties string Address [readonly]
+
+ The Bluetooth device address of the remote device.
+
+ string Name [readonly, optional]
+
+ The Bluetooth remote name. This value can not be
+ changed. Use the Alias property instead.
+
+ This value is only present for completeness. It is
+ better to always use the Alias property when
+ displaying the devices name.
+
+ If the Alias property is unset, it will reflect
+ this value which makes it more convenient.
+
+ string Icon [readonly, optional]
+
+ Proposed icon name according to the freedesktop.org
+ icon naming specification.
+
+ uint32 Class [readonly, optional]
+
+ The Bluetooth class of device of the remote device.
+
+ uint16 Appearance [readonly, optional]
+
+ External appearance of device, as found on GAP service.
+
+ array{string} UUIDs [readonly, optional]
+
+ List of 128-bit UUIDs that represents the available
+ remote services.
+
+ boolean Paired [readonly]
+
+ Indicates if the remote device is paired.
+
+ boolean Connected [readonly]
+
+ Indicates if the remote device is currently connected.
+ A PropertiesChanged signal indicate changes to this
+ status.
+
+ boolean Trusted [readwrite]
+
+ Indicates if the remote is seen as trusted. This
+ setting can be changed by the application.
+
+ boolean Blocked [readwrite]
+
+ If set to true any incoming connections from the
+ device will be immediately rejected. Any device
+ drivers will also be removed and no new ones will
+ be probed as long as the device is blocked.
+
+ string Alias [readwrite]
+
+ The name alias for the remote device. The alias can
+ be used to have a different friendly name for the
+ remote device.
+
+ In case no alias is set, it will return the remote
+ device name. Setting an empty string as alias will
+ convert it back to the remote device name.
+
+ When resetting the alias with an empty string, the
+ property will default back to the remote name.
+
+ object Adapter [readonly]
+
+ The object path of the adapter the device belongs to.
+
+ boolean LegacyPairing [readonly]
+
+ Set to true if the device only supports the pre-2.1
+ pairing mechanism. This property is useful in the
+ Adapter.DeviceFound signal to anticipate whether
+ legacy or simple pairing will occur.
+
+ Note that this property can exhibit false-positives
+ in the case of Bluetooth 2.1 (or newer) devices that
+ have disabled Extended Inquiry Response support.
+
+ string Modalias [readonly, optional]
+
+ Remote Device ID information in modalias format
+ used by the kernel and udev.
+
+ int16 RSSI [readonly, optional]
+
+ Received Signal Strength Indicator of the remote
+ device (inquiry or advertising).
diff --git a/contrib/bluez-api-5.20-fixed/health-api.txt b/contrib/bluez-api-5.20-fixed/health-api.txt
new file mode 100644
index 0000000..2c48ff2
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/health-api.txt
@@ -0,0 +1,152 @@
+BlueZ D-Bus Health API description
+**********************************
+
+
+HealthManager hierarchy
+=======================
+
+Service org.bluez
+Interface org.bluez.HealthManager1
+Object path /org/bluez/
+
+Methods object CreateApplication(dict config)
+
+ Returns the path of the new registered application.
+ Application will be closed by the call or implicitly
+ when the programs leaves the bus.
+
+ config:
+ uint16 DataType:
+
+ Mandatory
+
+ string Role:
+
+ Mandatory. Possible values: "source",
+ "sink"
+
+ string Description:
+
+ Optional
+
+ ChannelType:
+
+ Optional, just for sources. Possible
+ values: "reliable", "streaming"
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ void DestroyApplication(object application)
+
+ Closes the HDP application identified by the object
+ path. Also application will be closed if the process
+ that started it leaves the bus. Only the creator of the
+ application will be able to destroy it.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotFound
+ org.bluez.Error.NotAllowed
+
+
+HealthDevice hierarchy
+======================
+
+Service org.bluez
+Interface org.bluez.HealthDevice1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods boolean Echo()
+
+ Sends an echo petition to the remote service. Returns
+ True if response matches with the buffer sent. If some
+ error is detected False value is returned.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.OutOfRange
+
+ object CreateChannel(object application, string configuration)
+
+ Creates a new data channel. The configuration should
+ indicate the channel quality of service using one of
+ this values "reliable", "streaming", "any".
+
+ Returns the object path that identifies the data
+ channel that is already connected.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.HealthError
+
+ void DestroyChannel(object channel)
+
+ Destroys the data channel object. Only the creator of
+ the channel or the creator of the HealthApplication
+ that received the data channel will be able to destroy
+ it.
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotFound
+ org.bluez.Error.NotAllowed
+
+Signals void ChannelConnected(object channel)
+
+ This signal is launched when a new data channel is
+ created or when a known data channel is reconnected.
+
+ void ChannelDeleted(object channel)
+
+ This signal is launched when a data channel is deleted.
+
+ After this signal the data channel path will not be
+ valid and its path can be reused for future data
+ channels.
+
+Properties object MainChannel [readonly]
+
+ The first reliable channel opened. It is needed by
+ upper applications in order to send specific protocol
+ data units. The first reliable can change after a
+ reconnection.
+
+
+HealthChannel hierarchy
+=======================
+
+Service org.bluez
+Interface org.bluez.HealthChannel1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX/chanZZZ
+
+Only the process that created the data channel or the creator of the
+HealthApplication that received it will be able to call these methods.
+
+Methods fd Acquire()
+
+ Returns the file descriptor for this data channel. If
+ the data channel is not connected it will also
+ reconnect.
+
+ Possible Errors: org.bluez.Error.NotConnected
+ org.bluez.Error.NotAllowed
+
+ void Release()
+
+ Releases the fd. Application should also need to
+ close() it.
+
+ Possible Errors: org.bluez.Error.NotAcquired
+ org.bluez.Error.NotAllowed
+
+Properties string Type [readonly]
+
+ The quality of service of the data channel. ("reliable"
+ or "streaming")
+
+ object Device [readonly]
+
+ Identifies the Remote Device that is connected with.
+ Maps with a HealthDevice object.
+
+ object Application [readonly]
+
+ Identifies the HealthApplication to which this channel
+ is related to (which indirectly defines its role and
+ data type).
diff --git a/contrib/bluez-api-5.20-fixed/heartrate-api.txt b/contrib/bluez-api-5.20-fixed/heartrate-api.txt
new file mode 100644
index 0000000..665db12
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/heartrate-api.txt
@@ -0,0 +1,77 @@
+Heart Rate API description
+**************************
+
+
+Heart Rate Manager hierarchy
+============================
+
+Service org.bluez
+Interface org.bluez.HeartRateManager1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods RegisterWatcher(object agent)
+
+ Registers a watcher to monitor heart rate measurements.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ UnregisterWatcher(object agent)
+
+ Unregisters a watcher.
+
+Heart Rate Profile hierarchy
+============================
+
+Service org.bluez
+Interface org.bluez.HeartRate1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods Reset()
+
+ Restart the accumulation of energy expended from zero.
+
+ Possible Errors: org.bluez.Error.NotSupported
+
+Properties string Location (optional) [readonly]
+
+ Possible values: "other", "chest", "wrist","winger",
+ "hand", "earlobe", "foot"
+
+ boolean ResetSupported [readonly]
+
+ True if energy expended is supported.
+
+Heart Rate Watcher hierarchy
+============================
+
+Service unique name
+Interface org.bluez.HeartRateWatcher1
+Object path freely definable
+
+Methods void MeasurementReceived(object device, dict measurement)
+
+ This callback is called whenever a heart rate
+ measurement is received from the heart rate device.
+
+ Measurement:
+
+ uint16 Value:
+
+ Measurement value expressed in beats per
+ minute (bpm)
+
+ uint16 Energy (optional):
+
+ Accumulated energy expended in kilo Joules
+
+ boolean Contact (optional):
+
+ true if skin contact is detected by sensor,
+ false otherwise
+
+ array{uint16} Interval (optional):
+
+ RR-Interval values which represent the time
+ between two consecutive R waves in an ECG.
+ Values are ordered starting from oldest to
+ most recent.
diff --git a/contrib/bluez-api-5.20-fixed/media-api.txt b/contrib/bluez-api-5.20-fixed/media-api.txt
new file mode 100644
index 0000000..60e0ef0
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/media-api.txt
@@ -0,0 +1,646 @@
+BlueZ D-Bus Media API description
+*********************************
+
+
+Media hierarchy
+===============
+
+Service org.bluez
+Interface org.bluez.Media1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods void RegisterEndpoint(object endpoint, dict properties)
+
+ Register a local end point to sender, the sender can
+ register as many end points as it likes.
+
+ Note: If the sender disconnects the end points are
+ automatically unregistered.
+
+ possible properties:
+
+ string UUID:
+
+ UUID of the profile which the endpoint
+ is for.
+
+ byte Codec:
+
+ Assigned number of codec that the
+ endpoint implements. The values should
+ match the profile specification which
+ is indicated by the UUID.
+
+ array{byte} Capabilities:
+
+ Capabilities blob, it is used as it is
+ so the size and byte order must match.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotSupported - emitted
+ when interface for the end-point is
+ disabled.
+
+ void UnregisterEndpoint(object endpoint)
+
+ Unregister sender end point.
+
+ void RegisterPlayer(object player, dict properties)
+
+ Register a media player object to sender, the sender
+ can register as many objects as it likes.
+
+ Object must implement at least
+ org.mpris.MediaPlayer2.Player as defined in MPRIS 2.2
+ spec:
+
+ http://specifications.freedesktop.org/mpris-spec/latest/
+
+ Note: If the sender disconnects its objects are
+ automatically unregistered.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotSupported
+
+ void UnregisterPlayer(object player)
+
+ Unregister sender media player.
+
+
+Media Control hierarchy
+=======================
+
+Service org.bluez
+Interface org.bluez.MediaControl1 [Deprecated]
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods void Play()
+
+ Resume playback.
+
+ void Pause()
+
+ Pause playback.
+
+ void Stop()
+
+ Stop playback.
+
+ void Next()
+
+ Next item.
+
+ void Previous()
+
+ Previous item.
+
+ void VolumeUp()
+
+ Adjust remote volume one step up
+
+ void VolumeDown()
+
+ Adjust remote volume one step down
+
+ void FastForward()
+
+ Fast forward playback, this action is only stopped
+ when another method in this interface is called.
+
+ void Rewind()
+
+ Rewind playback, this action is only stopped
+ when another method in this interface is called.
+
+Properties
+
+ boolean Connected [readonly]
+
+
+MediaPlayer1 hierarchy
+======================
+
+Service org.bluez (Controller role)
+Interface org.bluez.MediaPlayer1 [Experimental]
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX/playerX
+
+Methods void Play()
+
+ Resume playback.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void Pause()
+
+ Pause playback.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void Stop()
+
+ Stop playback.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void Next()
+
+ Next item.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void Previous()
+
+ Previous item.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void FastForward()
+
+ Fast forward playback, this action is only stopped
+ when another method in this interface is called.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void Rewind()
+
+ Rewind playback, this action is only stopped
+ when another method in this interface is called.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+Properties string Equalizer [readwrite]
+
+ Possible values: "off" or "on"
+
+ string Repeat [readwrite]
+
+ Possible values: "off", "singletrack", "alltracks" or
+ "group"
+
+ string Shuffle [readwrite]
+
+ Possible values: "off", "alltracks" or "group"
+
+ string Scan [readwrite]
+
+ Possible values: "off", "alltracks" or "group"
+
+ string Status [readonly]
+
+ Possible status: "playing", "stopped", "paused",
+ "forward-seek", "reverse-seek"
+ or "error"
+
+ uint32 Position [readonly]
+
+ Playback position in milliseconds. Changing the
+ position may generate additional events that will be
+ sent to the remote device. When position is 0 it means
+ the track is starting and when it's greater than or
+ equal to track's duration the track has ended. Note
+ that even if duration is not available in metadata it's
+ possible to signal its end by setting position to the
+ maximum uint32 value.
+
+ dict Track [readonly]
+
+ Track metadata.
+
+ Possible values:
+
+ string Title:
+
+ Track title name
+
+ string Artist:
+
+ Track artist name
+
+ string Album:
+
+ Track album name
+
+ string Genre:
+
+ Track genre name
+
+ uint32 NumberOfTracks:
+
+ Number of tracks in total
+
+ uint32 TrackNumber:
+
+ Track number
+
+ uint32 Duration:
+
+ Track duration in milliseconds
+
+ object Device [readonly]
+
+ Device object path.
+
+ string Name [readonly]
+
+ Player name
+
+ string Type [readonly]
+
+ Player type
+
+ Possible values:
+
+ "Audio"
+ "Video"
+ "Audio Broadcasting"
+ "Video Broadcasting"
+
+ string Subtype [readonly]
+
+ Player subtype
+
+ Possible values:
+
+ "Audio Book"
+ "Podcast"
+
+ boolean Browsable [readonly]
+
+ If present indicates the player can be browsed using
+ MediaFolder interface.
+
+ Possible values:
+
+ True: Supported and active
+ False: Supported but inactive
+
+ Note: If supported but inactive clients can enable it
+ by using MediaFolder interface but it might interfere
+ in the playback of other players.
+
+
+ boolean Searchable [readonly]
+
+ If present indicates the player can be searched using
+ MediaFolder interface.
+
+ Possible values:
+
+ True: Supported and active
+ False: Supported but inactive
+
+ Note: If supported but inactive clients can enable it
+ by using MediaFolder interface but it might interfere
+ in the playback of other players.
+
+ object Playlist
+
+ Playlist object path.
+
+MediaFolder1 hierarchy
+======================
+
+Service unique name (Target role)
+ org.bluez (Controller role)
+Interface org.bluez.MediaFolder1 [Experimental]
+Object path freely definable (Target role)
+ [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX/playerX
+ (Controller role)
+
+Methods object Search(string value, dict filter)
+
+ Return a folder object containing the search result.
+
+ To list the items found use the folder object returned
+ and pass to ChangeFolder.
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ array{objects, properties} ListItems(dict filter)
+
+ Return a list of items found
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void ChangeFolder(object folder)
+
+ Change current folder.
+
+ Note: By changing folder the items of previous folder
+ might be destroyed and have to be listed again, the
+ exception is NowPlaying folder which should be always
+ present while the player is active.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+Properties uint32 NumberOfItems [readonly]
+
+ Number of items in the folder
+
+ string Name [readonly]
+
+ Folder name:
+
+ Possible values:
+ "/Filesystem/...": Filesystem scope
+ "/NowPlaying/...": NowPlaying scope
+
+ Note: /NowPlaying folder might not be listed if player
+ is stopped, folders created by Search are virtual so
+ once another Search is perform or the folder is
+ changed using ChangeFolder it will no longer be listed.
+
+Filters uint32 Start:
+
+ Offset of the first item.
+
+ Default value: 0
+
+ uint32 End:
+
+ Offset of the last item.
+
+ Default value: NumbeOfItems
+
+ array{string} Attributes
+
+ Item properties that should be included in the list.
+
+ Possible Values:
+
+ "title", "artist", "album", "genre",
+ "number-of-tracks", "number", "duration"
+
+ Default Value: All
+
+MediaItem1 hierarchy
+====================
+
+Service unique name (Target role)
+ org.bluez (Controller role)
+Interface org.bluez.MediaItem1 [Experimental]
+Object path freely definable (Target role)
+ [variable
+ prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX/playerX/itemX
+ (Controller role)
+
+Methods void Play()
+
+ Play item
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+ void AddtoNowPlaying()
+
+ Add item to now playing list
+
+ Possible Errors: org.bluez.Error.NotSupported
+ org.bluez.Error.Failed
+
+Properties object Player [readonly]
+
+ Player object path the item belongs to
+
+ string Name [readonly]
+
+ Item displayable name
+
+ string Type [readonly]
+
+ Item type
+
+ Possible values: "video", "audio", "folder"
+
+ string FolderType [readonly, optional]
+
+ Folder type.
+
+ Possible values: "mixed", "titles", "albums", "artists"
+
+ Available if property Type is "Folder"
+
+ boolean Playable [readonly, optional]
+
+ Indicates if the item can be played
+
+ Available if property Type is "folder"
+
+ dict Metadata [readonly]
+
+ Item metadata.
+
+ Possible values:
+
+ string Title
+
+ Item title name
+
+ Available if property Type is "audio"
+ or "video"
+
+ string Artist
+
+ Item artist name
+
+ Available if property Type is "audio"
+ or "video"
+
+ string Album
+
+ Item album name
+
+ Available if property Type is "audio"
+ or "video"
+
+ string Genre
+
+ Item genre name
+
+ Available if property Type is "audio"
+ or "video"
+
+ uint32 NumberOfTracks
+
+ Item album number of tracks in total
+
+ Available if property Type is "audio"
+ or "video"
+
+ uint32 Number
+
+ Item album number
+
+ Available if property Type is "audio"
+ or "video"
+
+ uint32 Duration
+
+ Item duration in milliseconds
+
+ Available if property Type is "audio"
+ or "video"
+
+MediaEndpoint1 hierarchy
+========================
+
+Service unique name
+Interface org.bluez.MediaEndpoint1
+Object path freely definable
+
+Methods void SetConfiguration(object transport, dict properties)
+
+ Set configuration for the transport.
+
+ array{byte} SelectConfiguration(array{byte} capabilities)
+
+ Select preferable configuration from the supported
+ capabilities.
+
+ Returns a configuration which can be used to setup
+ a transport.
+
+ Note: There is no need to cache the selected
+ configuration since on success the configuration is
+ send back as parameter of SetConfiguration.
+
+ void ClearConfiguration(object transport)
+
+ Clear transport configuration.
+
+ void Release()
+
+ This method gets called when the service daemon
+ unregisters the endpoint. An endpoint can use it to do
+ cleanup tasks. There is no need to unregister the
+ endpoint, because when this method gets called it has
+ already been unregistered.
+
+
+MediaTransport1 hierarchy
+=========================
+
+Service org.bluez
+Interface org.bluez.MediaTransport1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX/fdX
+
+Methods fd Acquire()
+
+ Acquire transport file descriptor and the MTU for read
+ and write respectively.
+
+ Possible Errors: org.bluez.Error.NotAuthorized
+ org.bluez.Error.Failed
+
+ fd TryAcquire()
+
+ Acquire transport file descriptor only if the transport
+ is in "pending" state at the time the message is
+ received by BlueZ. Otherwise no request will be sent
+ to the remote device and the function will just fail
+ with org.bluez.Error.NotAvailable.
+
+ Possible Errors: org.bluez.Error.NotAuthorized
+ org.bluez.Error.Failed
+ org.bluez.Error.NotAvailable
+
+ void Release()
+
+ Releases file descriptor.
+
+Properties object Device [readonly]
+
+ Device object which the transport is connected to.
+
+ string UUID [readonly]
+
+ UUID of the profile which the transport is for.
+
+ byte Codec [readonly]
+
+ Assigned number of codec that the transport support.
+ The values should match the profile specification which
+ is indicated by the UUID.
+
+ array{byte} Configuration [readonly]
+
+ Configuration blob, it is used as it is so the size and
+ byte order must match.
+
+ string State [readonly]
+
+ Indicates the state of the transport. Possible
+ values are:
+ "idle": not streaming
+ "pending": streaming but not acquired
+ "active": streaming and acquired
+
+ uint16 Delay [readwrite]
+
+ Optional. Transport delay in 1/10 of millisecond, this
+ property is only writeable when the transport was
+ acquired by the sender.
+
+ boolean NREC [readwrite]
+
+ Optional and HFP specific (external to BlueZ).
+ Indicates if echo cancelling and noise reduction
+ functions are active in the transport, this
+ property is only writeable when the transport
+ was acquired by the sender.
+
+ boolean InbandRingtone [readwrite]
+
+ Optional and HFP specific (external to BlueZ).
+ Indicates if the transport support sending
+ ringtones, this property is only writeable when
+ the transport was acquired by the sender.
+
+ string Routing [readonly]
+
+ Optional and HFP specific (external to BlueZ).
+ Indicates where is the transport being routed.
+
+ Possible Values: "HCI" or "PCM"
+
+ uint16 Volume [readwrite]
+
+ Optional. Indicates volume level of the transport,
+ this property is only writeable when the transport was
+ acquired by the sender.
+
+ Note: the property will not be present for HSP/HFP
+ transports and MicrophoneGain/SpeakerGain should be
+ used instead.
+
+ Possible Values: 0-127
+
+ byte MicrophoneGain [readwrite]
+
+ Optional. Indicates volume level of the transport's
+ incoming audio stream for HSP/HFP transports. This
+ property is only writeable when the transport was
+ acquired by the sender.
+
+ Possible Values: 0-15
+
+ byte SpeakerGain [readwrite]
+
+ Optional. Indicates volume level of the transport's
+ outgoing audio stream for HSP/HFP transports. This
+ property is only writeable when the transport was
+ acquired by the sender.
+
+ Possible Values: 0-15
diff --git a/contrib/bluez-api-5.20-fixed/mgmt-api.txt b/contrib/bluez-api-5.20-fixed/mgmt-api.txt
new file mode 100644
index 0000000..e15a78f
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/mgmt-api.txt
@@ -0,0 +1,2324 @@
+Bluetooth Management API
+*************************
+
+Copyright (C) 2008-2009 Marcel Holtmann <marcel@holtmann.org>
+
+
+Overview
+========
+
+This document describes the format of data used for communicating with
+the kernel using a so-called Bluetooth Management sockets. These sockets
+are available starting with Linux kernel version 3.4
+
+The following kernel versions introduced new commands, new events or
+important fixes to the Bluetooth Management API:
+
+Linux kernel v3.4 Version 1.0
+Linux kernel v3.5 Version 1.1
+Linux kernel v3.7 Version 1.2
+Linux kernel v3.9 Version 1.3
+Linux kernel v3.13 Version 1.4
+Linux kernel v3.15 Version 1.5
+Linux kernel v3.16 Version 1.6 (not yet released)
+
+Version 1.1 introduces Set Device ID command.
+
+Version 1.2 introduces Passkey Notify event.
+
+Version 1.3 does not introduce any new command or event.
+
+Version 1.4 introduces Set Advertising, Set BR/EDR, Set Static Address
+and Set Scan Parameters commands.
+
+Version 1.5 introduces Set Secure Connections, Set Debug Keys, Set Privacy
+and Load Identity Resolving Keys commands. It also introduces New Identity
+Resolving Key and New Signature Resolving Key events.
+
+Version 1.6 introduces Get Connection Information command. It also updates
+the Device Found event to combine advertising data and scan response data
+into a single event.
+
+
+Example
+=======
+
+The Bluetooth management sockets can be created by setting the hci_channel
+member of struct sockaddr_hci to HCI_CHANNEL_CONTROL (3) when creating a
+raw HCI socket. In C the needed code would look something like the following:
+
+int mgmt_create(void)
+{
+ struct sockaddr_hci addr;
+ int fd;
+
+ fd = socket(PF_BLUETOOTH, SOCK_RAW | SOCK_CLOEXEC | SOCK_NONBLOCK,
+ BTPROTO_HCI);
+ if (fd < 0)
+ return -errno;
+
+ memset(&addr, 0, sizeof(addr));
+ addr.hci_family = AF_BLUETOOTH;
+ addr.hci_dev = HCI_DEV_NONE;
+ addr.hci_channel = HCI_CHANNEL_CONTROL;
+
+ if (bind(fd, (struct sockaddr *) &addr, sizeof(addr)) < 0) {
+ int err = -errno;
+ close(fd);
+ return err;
+ }
+
+ return fd;
+}
+
+The process creating the mgmt socket is required to have the
+CAP_NET_ADMIN capability (e.g. root would have this).
+
+
+Packet Structures
+=================
+
+ Commands:
+
+ 0 4 8 12 16 22 24 28 31 35 39 43 47
+ +-------------------+-------------------+-------------------+
+ | Command Code | Controller Index | Parameter Length |
+ +-------------------+-------------------+-------------------+
+ | |
+
+ Events:
+
+ 0 4 8 12 16 22 24 28 31 35 39 43 47
+ +-------------------+-------------------+-------------------+
+ | Event Code | Controller Index | Parameter Length |
+ +-------------------+-------------------+-------------------+
+ | |
+
+All fields are in little-endian byte order (least significant byte first).
+
+Controller Index can have a special value <non-controller> to indicate that
+command or event is not related to any controller. Possible values:
+
+ <controller id> 0x0000 to 0xFFFE
+ <non-controller> 0xFFFF
+
+
+Error Codes
+===========
+
+The following values have been defined for use with the Command Status
+and Command Complete events:
+
+0x00 Success
+0x01 Unknown Command
+0x02 Not Connected
+0x03 Failed
+0x04 Connect Failed
+0x05 Authentication Failed
+0x06 Not Paired
+0x07 No Resources
+0x08 Timeout
+0x09 Already Connected
+0x0A Busy
+0x0B Rejected
+0x0C Not Supported
+0x0D Invalid Parameters
+0x0E Disconnected
+0x0F Not Powered
+0x10 Cancelled
+0x11 Invalid Index
+
+
+Read Management Version Information Command
+===========================================
+
+ Command Code: 0x0001
+ Controller Index: <non-controller>
+ Command Parameters:
+ Return Parameters: Version (1 Octets)
+ Revision (2 Octets)
+
+ This command returns the Management version and revision.
+ Besides, being informational the information can be used to
+ determine whether certain behavior has changed or bugs fixed
+ when interacting with the kernel.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+
+Read Management Supported Commands Command
+==========================================
+
+ Command Code: 0x0002
+ Controller Index: <non-controller>
+ Command Parameters:
+ Return Parameters: Num_Of_Commands (2 Octets)
+ Num_Of_Events (2 Octets)
+ Command1 (2 Octets)
+ Command2 (2 Octets)
+ ...
+ Event1 (2 Octets)
+ Event2 (2 Octets)
+ ...
+
+ This command returns the list of supported Management commands
+ and events.
+
+ The commands Read Management Version Information and Read
+ management Supported Commands are not included in this list.
+ Both commands are always supported and mandatory.
+
+ The events Command Status and Command Complete are not included
+ in this list. Both are implicit and mandatory.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+
+Read Controller Index List Command
+==================================
+
+ Command Code: 0x0003
+ Controller Index: <non-controller>
+ Command Parameters:
+ Return Parameters: Num_Controllers (2 Octets)
+ Controller_Index[i] (2 Octets)
+
+ This command returns the list of currently known controllers.
+ Controllers added or removed after calling this command can be
+ monitored using the Index Added and Index Removed events.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+
+Read Controller Information Command
+===================================
+
+ Command Code: 0x0004
+ Controller Index: <controller id>
+ Command Parameters:
+ Return Parameters: Address (6 Octets)
+ Bluetooth_Version (1 Octet)
+ Manufacturer (2 Octets)
+ Supported_Settings (4 Octets)
+ Current_Settings (4 Octets)
+ Class_Of_Device (3 Octets)
+ Name (249 Octets)
+ Short_Name (11 Octets)
+
+ This command is used to retreive the current state and basic
+ information of a controller. It is typically used right after
+ getting the response to the Read Controller Index List command
+ or an Index Added event.
+
+ If not short name is set the Short_Name parameter will be empty
+ (begin with a nul byte).
+
+ Current_Settings & Supported_Settings is a bitmask with
+ currently the following available bits:
+
+ 0 Powered
+ 1 Connectable
+ 2 Fast Connectable
+ 3 Discoverable
+ 4 Pairable
+ 5 Link Level Security (Sec. mode 3)
+ 6 Secure Simple Pairing
+ 7 Basic Rate/Enhanced Data Rate
+ 8 High Speed
+ 9 Low Energy
+ 10 Advertising
+ 11 Secure Connections
+ 12 Debug Keys
+ 13 Privacy
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Set Powered Command
+===================
+
+ Command Code: 0x0005
+ Controller Index: <controller id>
+ Command Parameters: Powered (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to power on or off a controller. The
+ allowed Powered command parameter values are 0x00 and 0x01. All
+ other values will return Invalid Parameters.
+
+ If discoverable setting is activated with a timeout, then
+ switching the controller off will expire this timeout and
+ disable discoverable.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Invalid Parameters
+ Invalid Index
+
+
+Set Discoverable Command
+========================
+
+ Command Code: 0x0006
+ Controller Index: <controller id>
+ Command Parameters: Discoverable (1 Octet)
+ Timeout (2 Octets)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to set the discoverable property of a
+ controller. The allowed Discoverable command parameter values
+ are 0x00, 0x01 and 0x02. All other values will return Invalid
+ Parameters.
+
+ Timeout is the time in seconds and is only meaningful when
+ Discoverable is set to 0x01 or 0x02. Providing a timeout
+ with 0x00 return Invalid Parameters. For 0x02, the timeout
+ value is required.
+
+ The value 0x00 disables discoverable, the value 0x01 enables
+ general discoverable and the value 0x02 enables limited
+ discoverable.
+
+ This command is only available for BR/EDR capable controllers
+ (e.g. not for single-mode LE ones). It will return Not Supported
+ otherwise.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ However using a timeout when the controller is not powered will
+ return Not Powered error.
+
+ When switching discoverable on and the connectable setting is
+ off it will return Rejected error.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Rejected
+ Not Supported
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Set Connectable Command
+=======================
+
+ Command Code: 0x0007
+ Controller Index: <controller id>
+ Command Parameters: Connectable (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to set the connectable property of a
+ controller. The allowed Connectable command parameter values are
+ 0x00 and 0x01. All other values will return Invalid Parameters.
+
+ This command is available for BR/EDR, LE-only and also dual
+ mode controllers. For BR/EDR is changes the page scan setting
+ and for LE controllers it changes the advertising type. For
+ dual mode controllers it affects both settings.
+
+ For LE capable controllers the connectable setting only takes
+ affect when advertising is enabled.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ When switching connectable off, it will also switch off the
+ discoverable setting. Switching connectable back on will not
+ restore a previous discoverable. It will stay off and needs
+ to be manually switched back on.
+
+ When switching connectable off, it will expire a discoverable
+ setting with a timeout.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Fast Connectable Command
+============================
+
+ Command Code: 0x0008
+ Controller Index: <controller id>
+ Command Parameters: Enable (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to set the controller into a connectable
+ state where the page scan parameters have been set in a way to
+ favor faster connect times with the expense of higher power
+ consumption.
+
+ The allowed values of the Enable command parameter are 0x00 and
+ 0x01. All other values will return Invalid Parameters.
+
+ This command is only available for BR/EDR capable controllers
+ (e.g. not for single-mode LE ones). It will return Not Supported
+ otherwise.
+
+ This command can only be used when the controller is powered on
+ and will return Not Powerd otherwise.
+
+ If connectable is not set, then this command will fail with
+ Rejected error.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Failed
+ Busy
+ Rejected
+ Not Supported
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Set Pairable Command
+====================
+
+ Command Code: 0x0009
+ Controller Index: <controller id>
+ Command Parameters: Pairable (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to set the pairable property of an
+ controller. The allowed values for the Pairable command
+ parameter are 0x00 and 0x01. All other values will return
+ Invalid Parameters.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ Turning pairable on will not automatically switch the controller
+ into connectable mode. That needs to be done separately.
+
+ The setting will be remembered during power down/up toggles.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Set Link Security Command
+=========================
+
+ Command Code: 0x000A
+ Controller Index: <controller id>
+ Command Parameters: Link_Security (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to either enable or disable link level
+ security for an controller (also known as Security Mode 3). The
+ allowed values for the Link_Security command parameter are 0x00
+ and 0x01. All other values will return Invalid Parameters.
+
+ This command is only available for BR/EDR capable controllers
+ (e.g. not for single-mode LE ones). It will return Not Supported
+ otherwise.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Secure Simple Pairing Command
+=================================
+
+ Command Code: 0x000B
+ Controller Index: <controller id>
+ Command Parameters: Secure_Simple_Pairing (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable/disable Secure Simple Pairing
+ support for a controller. The allowed values for the
+ Secure_Simple_Pairing command parameter are 0x00 and 0x01. All
+ other values will return Invalid Parameters.
+
+ This command is only available for BR/EDR capable controllers
+ supporting the core specification version 2.1 or greater
+ (e.g. not for single-mode LE controllers or pre-2.1 ones).
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the controller does not support Secure Simple Pairing,
+ the command will fail regardless with Not Supported error.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+Set High Speed Command
+======================
+
+ Command Code: 0x000C
+ Controller Index: <controller id>
+ Command Parameters: High_Speed (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable/disable Bluetooth High Speed
+ support for a controller. The allowed values for the High_Speed
+ command parameter are 0x00 and 0x01. All other values will
+ return Invalid Parameters.
+
+ This command is only available for BR/EDR capable controllers
+ (e.g. not for single-mode LE ones).
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ To enable High Speed support, it is required that Secure Simple
+ Pairing support is enabled first. High Speed support is not
+ possible for connections without Secure Simple Pairing.
+
+ When switching Secure Simple Pairing off, the support for High
+ Speed will be switched off as well. Switching Secure Simple
+ Pairing back on, will not re-enable High Speed support. That
+ needs to be done manually.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Low Energy Command
+======================
+
+ Command Code: 0x000D
+ Controller Index: <controller id>
+ Command Parameters: Low_Energy (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable/disable Low Energy support for a
+ controller. The allowed values of the Low_Energy command
+ parameter are 0x00 and 0x01. All other values will return
+ Invalid Parameters.
+
+ This command is only available for LE capable controllers and
+ will yield in a Not Supported error otherwise.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the kernel subsystem does not support Low Energy or the
+ controller does not either, the command will fail regardless.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Device Class
+================
+
+ Command Code: 0x000E
+ Controller Index: <controller id>
+ Command Parameters: Major_Class (1 Octet)
+ Minor_Class (1 Octet)
+ Return Parameters: Class_Of_Device (3 Octets)
+
+ This command is used to set the major and minor device class for
+ BR/EDR capable controllers.
+
+ This command will also implicitly disable caching of pending CoD
+ and EIR updates.
+
+ This command is only available for BR/EDR capable controllers
+ (e.g. not for single-mode LE ones).
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the controller is powered off, 0x000000 will be returned
+ for the class of device parameter. And after power on the new
+ value will be announced via class of device changed event.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Local Name Command
+======================
+
+ Command Code: 0x000F
+ Controller Index: <controller id>
+ Command Parameters: Name (249 Octets)
+ Short_Name (11 Octets)
+ Return Parameters: Name (249 Octets)
+ Short_Name (11 Octets)
+
+ This command is used to set the local name of a controller. The
+ command parameters also include a short name which will be used
+ in case the full name doesn't fit within EIR/AD data.
+
+ The name parameters need to always end with a null byte (failure
+ to do so will cause the command to fail).
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ The values of name and short name will be remembered when
+ switching the controller off and back on again. So the name
+ and short name only have to be set once when a new controller
+ is found and will stay until removed.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Add UUID Command
+================
+
+ Command Code: 0x0010
+ Controller Index: <controller id>
+ Command Parameters: UUID (16 Octets)
+ SVC_Hint (1 Octet)
+ Return Parameters: Class_Of_Device (3 Octets)
+
+ This command is used to add a UUID to be published in EIR
+ and/or AD data. The accompanied SVC_Hint parameter is used to
+ tell the kernel whether the service class bits of the Class of
+ Device value need modifying due to this UUID.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the controller is powered off, 0x000000 will be returned
+ for the class of device parameter. And after power on the new
+ value will be announced via class of device changed event.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Invalid Parameters
+ Invalid Index
+
+
+Remove UUID Command
+===================
+
+ Command Code: 0x0011
+ Controller Index: <controller id>
+ Command Parameters: UUID (16 Octets)
+ Return Parameters: Class_Of_Device (3 Octets)
+
+ This command is used to remove a UUID previously added using the
+ Add UUID command.
+
+ When the UUID parameter is an empty UUID (16 x 0x00), then all
+ previously loaded UUIDs will be removed.
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the controller is powered off, 0x000000 will be returned
+ for the class of device parameter. And after power on the new
+ value will be announced via class of device changed event.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Invalid Parameters
+ Invalid Index
+
+
+Load Link Keys Command
+======================
+
+ Command Code: 0x0012
+ Controller Index: <controller id>
+ Command Parameters: Debug_Keys (1 Octet)
+ Key_Count (2 Octets)
+ Key1 {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Key_Type (1 Octet)
+ Value (16 Octets)
+ PIN_Length (1 Octet)
+ }
+ Key2 { }
+ ...
+ Return Parameters:
+
+ This command is used to feed the kernel with currently known
+ link keys. The command does not need to be called again upon the
+ receiption of New Link Key events since the kernel updates its
+ list automatically.
+
+ The Debug_Keys parameter is used to tell the kernel whether to
+ accept the usage of debug keys or not. The allowed values for
+ this parameter are 0x00 and 0x01. All other values will return
+ an Invalid Parameters response.
+
+ Usage of the Debug_Keys parameter is deprecated and has been
+ replaced with the Set Debug Keys command. When setting the
+ Debug_Keys option via Load Link Keys command it has the same
+ affect as setting it via Set Debug Keys and applies to all
+ keys in the system.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 Reserved (not in use)
+ 2 Reserved (not in use)
+
+ Public and random LE addresses are not valid and will be rejected.
+
+ Currently defined Key_Type values are:
+
+ 0x00 Combination key
+ 0x01 Local Unit key
+ 0x02 Remote Unit key
+ 0x03 Debug Combination key
+ 0x04 Unauthenticated Combination key from P-192
+ 0x05 Authenticated Combination key from P-192
+ 0x06 Changed Combination key
+ 0x07 Unauthenticated Combination key from P-256
+ 0x08 Authenticated Combination key from P-256
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Load Long Term Keys Command
+===========================
+
+ Command Code: 0x0013
+ Controller Index: <controller id>
+ Command Parameters: Key_Count (2 Octets)
+ Key1 {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Key_Type (1 Octet)
+ Master (1 Octet)
+ Encryption_Size (1 Octet)
+ Encryption_Diversifier (2 Octets)
+ Random_Number (8 Octets)
+ Value (16 Octets)
+ }
+ Key2 { }
+ ...
+ Return Parameters:
+
+ This command is used to feed the kernel with currently known
+ (SMP) Long Term Keys. The command does not need to be called
+ again upon the receiption of New Long Term Key events since the
+ kernel updates its list automatically.
+
+ Possible values for the Address_Type parameter:
+ 0 Reserved (not in use)
+ 1 LE Public
+ 2 LE Random
+
+ The provided Address and Address_Type are the identity of
+ a device. So either its public address or static random address.
+
+ Unresolvable random addresses and resolvable random addresses are
+ not valid and will be rejected.
+
+ Currently defined Key_Type values are:
+
+ 0x00 Unauthenticated key
+ 0x01 Authenticated key
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Disconnect Command
+==================
+
+ Command Code: 0x0014
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to force the disconnection of a currently
+ connected device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Busy
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Get Connections Command
+=======================
+
+ Command Code: 0x0015
+ Controller Index: <controller id>
+ Command Parameters:
+ Return Parameters: Connection_Count (2 Octets)
+ Address1 {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ }
+ Address2 { }
+ ...
+
+ This command is used to retreive a list of currently connected
+ devices.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ For devices using resolvable random addresses with a known
+ identity resolving key, the Address and Address_Type will
+ contain the identity information.
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+PIN Code Reply Command
+=======================
+
+ Command Code: 0x0016
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ PIN_Length (1 Octet)
+ PIN_Code (16 Octets)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to respond to a PIN Code request event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+PIN Code Negative Reply Command
+===============================
+
+ Command Code: 0x0017
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to return a negative response to a PIN Code
+ Request event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Set IO Capability Command
+=========================
+
+ Command Code: 0x0018
+ Controller Index: <controller id>
+ Command Parameters: IO_Capability (1 Octet)
+ Return Parameters:
+
+ This command is used to set the IO Capability used for pairing.
+ The command accepts both SSP and SMP values.
+
+ Possible values for the IO_Capability parameter:
+ 0 DisplayOnly
+ 1 DisplayYesNo
+ 2 KeyboardOnly
+ 3 NoInputNoOutput
+ 4 KeyboardDisplay
+
+ Passing a value 4 (KeyboardDisplay) will cause the kernel to
+ convert it to 1 (DisplayYesNo) in the case of a BR/EDR
+ connection (as KeyboardDisplay is specific to SMP).
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Pair Device Command
+===================
+
+ Command Code: 0x0019
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ IO_Capability (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to trigger pairing with a remote device.
+ The IO_Capability command parameter is used to temporarily (for
+ this pairing event only) override the global IO Capaility (set
+ using the Set IO Capability command).
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ Possible values for the IO_Capability parameter:
+ 0 DisplayOnly
+ 1 DisplayYesNo
+ 2 KeyboardOnly
+ 3 NoInputNoOutput
+ 4 KeyboardDisplay
+
+ Passing a value 4 (KeyboardDisplay) will cause the kernel to
+ convert it to 1 (DisplayYesNo) in the case of a BR/EDR
+ connection (as KeyboardDisplay is specific to SMP).
+
+ The Address and Address_Type of the return parameters will
+ return the identity address if know. In case of resolvable
+ random address given as command parameters and the remote
+ provides an identity resolving key, the return parameters
+ will provide the resolved address.
+
+ To allow tracking of which resolvable random address changed
+ into which identity address, the New Identity Resolving Key
+ event will be send before receiving Command Complete event
+ for this command.
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Connect Failed
+ Busy
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Cancel Pair Device
+==================
+
+ Command Code: 0x001A
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ The Address and Address_Type parameters should match what was
+ given to a preceding Pair Device command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Unpair Device Command
+=====================
+
+ Command Code: 0x001B
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Disconnect (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ Removes all keys associated with the remote device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The Disconnect parameter tells the kernel whether to forcefully
+ disconnect any existing connections to the device. It should in
+ practice always be 1 except for some special GAP qualification
+ test-cases where a key removal without disconnecting is needed.
+
+ When unpairing a device its link key, long term key and if
+ provided identity resolving key will be purged.
+
+ For devices using resolvable random addresses where the identity
+ resolving key was available, after this command they will now no
+ longer be resolved. The device will essentially become private
+ again.
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Paired
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+User Confirmation Reply Command
+===============================
+
+ Command Code: 0x001C
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to respond to a User Confirmation Request
+ event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+User Confirmation Negative Reply Command
+========================================
+
+ Command Code: 0x001D
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to return a negative response to a User
+ Confirmation Request event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+User Passkey Reply Command
+==========================
+
+ Command Code: 0x001E
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Passkey (4 Octets)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to respond to a User Confirmation Passkey
+ Request event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+User Passkey Negative Reply Command
+===================================
+
+ Command Code: 0x001F
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to return a negative response to a User
+ Passkey Request event.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Not Connected
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Read Local Out Of Band Data Command
+===================================
+
+ Command Code: 0x0020
+ Controller Index: <controller id>
+ Command Parameters:
+ Return Parameters: Hash_192 (16 Octets)
+ Randomizer_192 (16 Octets)
+ Hash_256 (16 Octets, Optional)
+ Randomizer_256 (16 Octets, Optional)
+
+ This command is used to read the local Out of Band data.
+
+ This command can only be used when the controller is powered.
+
+ If Secure Connections support is enabled, then this command
+ will return P-192 versions of hash and randomizer as well as
+ P-256 versions of both.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Not Supported
+ Busy
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Add Remote Out Of Band Data Command
+===================================
+
+ Command Code: 0x0021
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Hash_192 (16 Octets)
+ Randomizer_192 (16 Octets)
+ Hash_256 (16 Octets, Optional)
+ Randomizer_256 (16 Octets, Optional)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to provide Out of Band data for a remote
+ device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ Provided Out Of Band data is persistent over power down/up toggles.
+
+ This command also accept optional P-256 versions of hash and
+ randomizer. If they are not provided, then they are set to
+ zero value.
+
+ The P-256 versions of both can also be provided when the
+ support for Secure Connections is not enabled. However in
+ that case they will never be used.
+
+ To only provide the P-256 versions of hash and randomizer,
+ it is valid to leave both P-192 fields as zero values. If
+ Secure Connections is disabled, then of course this is the
+ same as not providing any data at all.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Failed
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Remove Remote Out Of Band Data Command
+======================================
+
+ Command Code: 0x0022
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to remove data added using the Add Remote
+ Out Of Band Data command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Start Discovery Command
+=======================
+
+ Command Code: 0x0023
+ Controller Index: <controller id>
+ Command Parameters: Address_Type (1 Octet)
+ Return Parameters: Address_Type (1 Octet)
+
+ This command is used to start the process of discovering remote
+ devices. A Device Found event will be sent for each discovered
+ device.
+
+ Possible values for the Address_Type parameter are a bit-wise or
+ of the following bits:
+
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ By combining these e.g. the following values are possible:
+
+ 1 BR/EDR
+ 6 LE (public & random)
+ 7 BR/EDR/LE (interleaved discovery)
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Not Powered
+ Invalid Index
+
+
+Stop Discovery Command
+======================
+
+ Command Code: 0x0024
+ Controller Index: <controller id>
+ Command Parameters: Address_Type (1 Octet)
+ Return Parameters: Address_Type (1 Octet)
+
+ This command is used to stop the discovery process started using
+ the Start Discovery command.
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Rejected
+ Invalid Parameters
+ Invalid Index
+
+
+Confirm Name Command
+====================
+
+ Command Code: 0x0025
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Name_Known (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is only valid during device discovery and is
+ expected for each Device Found event with the Confirm Name
+ flag set.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The Name_Known parameter should be set to 0x01 if user space
+ knows the name for the device and 0x00 if it doesn't. If set to
+ 0x00 the kernel will perform a name resolving procedure for the
+ device in question.
+
+ This command can only be used when the controller is powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Failed
+ Invalid Parameters
+ Invalid Index
+
+
+Block Device Command
+====================
+
+ Command Code: 0x0026
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to add a device to the list of devices
+ which should be blocked from being connect to the local
+ controller.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Failed
+ Invalid Parameters
+ Invalid Index
+
+
+Unblock Device Command
+======================
+
+ Command Code: 0x0027
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This command is used to remove a device from the list of blocked
+ devices (where it was added to using the Block Device command).
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success
+ or failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Set Device ID Command
+=====================
+
+ Command Code: 0x0028
+ Controller Index: <controller id>
+ Command Parameters: Source (2 Octets)
+ Vendor (2 Octets)
+ Product (2 Octets)
+ Version (2 Octets)
+ Return Parameters:
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ The Source parameter selects the organization that assigned the
+ Vendor parameter:
+
+ 0x0000 Disable Device ID
+ 0x0001 Bluetooth SIG
+ 0x0002 USB Implementer’s Forum
+
+ The information are put into the EIR data. If the controller does
+ not support EIR or if SSP is disabled, this command will still
+ succeed. The information are stored for later use and will survive
+ toggling SSP on and off.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Set Advertising Command
+=======================
+
+ Command Code: 0x0029
+ Controller Index: <controller id>
+ Command Parameters: Advertising (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable LE advertising on a controller
+ that supports it. The allowed values for the Advertising
+ command parameter are 0x00 and 0x01. All other values will
+ return Invalid Parameters.
+
+ A pre-requisite is that LE is already enabled, otherwise
+ this command will return a "rejected" response.
+
+ This command generates a Command Complete event on success or a
+ Command Status event on failure.
+
+ Possible errors: Busy
+ Rejected
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set BR/EDR Command
+==================
+
+ Command Code: 0x002A
+ Controller Index: <controller id>
+ Command Parameters: BR/EDR (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable or disable BR/EDR support
+ on a dual-mode controller. The allowed values for the Advertising
+ command parameter are 0x00 and 0x01. All other values will
+ return Invalid Parameters.
+
+ A pre-requisite is that LE is already enabled, otherwise
+ this command will return a "rejected" response. Enabling BR/EDR
+ can be done both when powered on and powered off, however
+ disabling it can only be done when powered off (otherwise the
+ command will again return "rejected"). Disabling BR/EDR will
+ automatically disable all other BR/EDR related settings.
+
+ This command generates a Command Complete event on success or a
+ Command Status event on failure.
+
+ Possible errors: Busy
+ Rejected
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Static Address Command
+==========================
+
+ Command Code: 0x002B
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Return Parameters:
+
+ This command allows for setting the static random address. It is
+ only supported on controllers with LE support. The static random
+ address is suppose to be valid for the lifetime of the
+ controller or at least until the next power cycle. To ensure
+ such behavior, setting of the address is limited to when the
+ controller is powered off.
+
+ The special BDADDR_ANY address (00:00:00:00:00:00) can be used
+ to disable the static address.
+
+ When a controller has a public address (which is required for
+ all dual-mode controllers), this address is not used. Only when
+ the controller information reports BDADDR_ANY (00:00:00:00:00:00),
+ it is required to configure a static address first.
+
+ If privacy mode is enabled and the controller is single mode
+ LE only without a public address, the static random address is
+ used as identity address.
+
+ This command generates a Command Complete event on success or a
+ Command Status event on failure.
+
+ Possible errors: Rejected
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Scan Parameters Command
+===========================
+
+ Command Code: 0x002C
+ Controller Index: <controller id>
+ Command Parameters: Interval (2 Octets)
+ Window (2 Octets)
+ Return Parameters:
+
+ This command allows for setting the Low Energy scan parameters
+ used for connection establishment and passive scanning. It is
+ only supported on controllers with LE support.
+
+ This command generates a Command Complete event on success or a
+ Command Status event on failure.
+
+ Possible errors: Rejected
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Secure Connections Command
+==============================
+
+ Command Code: 0x002D
+ Controller Index: <controller id>
+ Command Parameters: Secure_Connections (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable/disable Secure Connections
+ support for a controller. The allowed values for the
+ Secure_Connections command parameter are 0x00, 0x01 and 0x02.
+ All other values will return Invalid Parameters.
+
+ The value 0x00 disables Secure Connections, the value 0x01
+ enables Secure Connections and the value 0x02 enables Secure
+ Connections Only mode.
+
+ This command is only available for BR/EDR capable controllers
+ supporting the core specification version 4.1 or greater
+ (e.g. not for single-mode LE controllers or pre-4.1 ones).
+
+ This command can be used when the controller is not powered and
+ all settings will be programmed once powered.
+
+ In case the controller does not support Secure Connections
+ the command will fail regardless with Not Supported error.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Debug Keys Command
+======================
+
+ Command Code: 0x002E
+ Controller Index: <controller id>
+ Command Parameters: Debug_Keys (1 Octet)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to tell the kernel whether to accept the
+ usage of debug keys or not. The allowed values for this parameter
+ are 0x00 and 0x01. All other values will return an Invalid Parameters
+ response.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Set Privacy Command
+===================
+
+ Command Code: 0x002F
+ Controller Index: <controller id>
+ Command Parameters: Privacy (1 Octet)
+ Identity_Resolving_Key (16 Octets)
+ Return Parameters: Current_Settings (4 Octets)
+
+ This command is used to enable Low Energy Privacy feature using
+ resolvable private addresses.
+
+ The value 0x00 disables privacy mode, the value 0x01 enables
+ privacy mode.
+
+ When the controller has a public address (mandatory for dual-mode
+ controllers) it is used as identity address. In case the controller
+ is single mode LE only without a public address, it is required
+ to configure a static random andress first. The privacy mode can
+ only be enabled when an identity address is available.
+
+ The Identity_Resolving_Key is the local key assigned for the local
+ resolvable private address.
+
+ Possible errors: Busy
+ Not Supported
+ Invalid Parameters
+ Invalid Index
+
+
+Load Identity Resolving Keys Command
+====================================
+
+ Command Code: 0x0030
+ Controller Index: <controller id>
+ Command Parameters: Key_Count (2 Octets)
+ Key1 {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Value (16 Octets)
+ }
+ Key2 { }
+ ...
+ Return Parameters:
+
+ This command is used to feed the kernel with currently known
+ identity resolving keys. The command does not need to be called
+ again upon the receiption of New Identity Resolving Key events
+ since the kernel updates its list automatically.
+
+ Possible values for the Address_Type parameter:
+ 0 Reserved (not in use)
+ 1 LE Public
+ 2 LE Random
+
+ The provided Address and Address_Type are the identity of
+ a device. So either its public address or static random address.
+
+ Unresolvable random addresses and resolvable random addresses are
+ not valid and will be rejected.
+
+ This command can be used when the controller is not powered.
+
+ This command generates a Command Complete event on success or
+ a Command Status event on failure.
+
+ Possible errors: Invalid Parameters
+ Invalid Index
+
+
+Get Connection Information Command
+==================================
+
+ Command Code: 0x0031
+ Controller Index: <controller id>
+ Command Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Return Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ RSSI (1 Octet)
+ TX_Power (1 Octet)
+ Max_TX_Power (1 Octet)
+
+ This command is used to get connection information.
+
+ TX_Power and Max_TX_Power can be set to 127 if values are invalid or
+ unknown.
+
+ This command generates a Command Complete event on success and
+ on failure. In case of failure only Address and Address_Type fields
+ are valid and values of remaining parameters are considered invalid
+ and shall be ignored.
+
+ Possible errors: Not Connected
+ Not Powered
+ Invalid Parameters
+ Invalid Index
+
+
+Command Complete Event
+======================
+
+ Event Code: 0x0001
+ Controller Index: <controller id> or <non-controller>
+ Event Parameters: Command_Opcode (2 Octets)
+ Status (1 Octet)
+ Return_Parameters
+
+ This event is an indication that a command has completed. The
+ fixed set of parameters includes the opcode to identify the
+ command that completed as well as a status value to indicate
+ success or failure. The rest of the parameters are command
+ specific and documented in the section for each command
+ separately.
+
+
+Command Status Event
+====================
+
+ Event Code: 0x0002
+ Controller Index: <controller id> or <non-controller>
+ Event Parameters: Command_Opcode (2 Octets)
+ Status (1 Octet)
+
+ The command status event is used to indicate an early status for
+ a pending command. In the case that the status indicates failure
+ (anything else except success status) this also means that the
+ command has finished executing.
+
+
+Controller Error Event
+======================
+
+ Event Code: 0x0003
+ Controller Index: <controller id>
+ Event Parameters: Error_Code (1 Octet)
+
+ This event maps straight to the HCI Hardware Error event and is
+ used to indicate something wrong with the controller hardware.
+
+
+Index Added Event
+=================
+
+ Event Code: 0x0004
+ Controller Index: <controller id>
+ Event Parameters:
+
+ This event indicates that a new controller has been added to the
+ system. It is usually followed by a Read Controller Information
+ command.
+
+
+Index Removed Event
+===================
+
+ Event Code: 0x0005
+ Controller Index: <controller id>
+ Event Parameters:
+
+ This event indicates that a controller has been removed from the
+ system.
+
+
+New Settings Event
+==================
+
+ Event Code: 0x0006
+ Controller Index: <controller id>
+ Event Parameters: Current_Settings (4 Octets)
+
+ This event indicates that one or more of the settings for a
+ controller has changed.
+
+
+Class Of Device Changed Event
+=============================
+
+ Event Code: 0x0007
+ Controller Index: <controller id>
+ Event Parameters: Class_Of_Device (3 Octets)
+
+ This event indicates that the Class of Device value for the
+ controller has changed. When the controller is powered off the
+ Class of Device value will always be reported as zero.
+
+
+Local Name Changed Event
+========================
+
+ Event Code: 0x0008
+ Controller Index: <controller id>
+ Event Parameters: Name (249 Octets)
+ Short_Name (11 Octets)
+
+ This event indicates that the local name of the controller has
+ changed.
+
+
+New Link Key Event
+==================
+
+ Event Code: 0x0009
+ Controller Index: <controller id>
+ Event Parameters: Store_Hint (1 Octet)
+ Key {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Key_Type (1 Octet)
+ Value (16 Octets)
+ PIN_Length (1 Octet)
+ }
+
+ This event indicates that a new link key has bee generated for a
+ remote device.
+
+ The Store_Hint parameter indicates whether the host is expected
+ to store the key persistently or not (e.g. this would not be set
+ if the authentication requirement was "No Bonding").
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 Reserved (not in use)
+ 2 Reserved (not in use)
+
+ Public and random LE addresses are not valid and will be rejected.
+
+ Currently defined Key_Type values are:
+
+ 0x00 Combination key
+ 0x01 Local Unit key
+ 0x02 Remote Unit key
+ 0x03 Debug Combination key
+ 0x04 Unauthenticated Combination key from P-192
+ 0x05 Authenticated Combination key from P-192
+ 0x06 Changed Combination key
+ 0x07 Unauthenticated Combination key from P-256
+ 0x08 Authenticated Combination key from P-256
+
+ Receiving this event indicates that a pairing procecure has
+ been completed.
+
+
+New Long Term Key Event
+=======================
+
+ Event Code: 0x000A
+ Controller Index: <controller id>
+ Event Parameters: Store_Hint (1 Octet)
+ Key {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Key_Type (1 Octet)
+ Master (1 Octet)
+ Encryption Size (1 Octet)
+ Enc. Diversifier (2 Octets)
+ Random Number (8 Octets)
+ Value (16 Octets)
+ }
+
+ This event indicates that a new long term key has been generated
+ for a remote device.
+
+ The Store_Hint parameter indicates whether the host is expected
+ to store the key persistently or not (e.g. this would not be set
+ if the authentication requirement was "No Bonding").
+
+ Possible values for the Address_Type parameter:
+ 0 Reserved (not in use)
+ 1 LE Public
+ 2 LE Random
+
+ The provided Address and Address_Type are the identity of
+ a device. So either its public address or static random address.
+
+ For unresolvable random addresses and resolvable random addresses
+ without identity information and identity resolving key, the
+ Store_Hint will be set to not store the long term key.
+
+ Currently defined Key_Type values are:
+
+ 0x00 Unauthenticated key
+ 0x01 Authenticated key
+
+ Receiving this event indicates that a pairing procecure has
+ been completed.
+
+
+Device Connected Event
+======================
+
+ Event Code: 0x000B
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Flags (4 Octets)
+ EIR_Data_Length (2 Octets)
+ EIR_Data (0-65535 Octets)
+
+ This event indicates that a successful baseband connection has
+ been created to the remote device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ For devices using resolvable random addresses with a known
+ identity resolving key, the Address and Address_Type will
+ contain the identity information.
+
+ It is possible that devices get connected via its resolvable
+ random address and after New Identity Resolving Key event
+ start using its identity.
+
+ The following bits are defined for the Flags parameter:
+ 0 Reserved (not in use)
+ 1 Legacy Pairing
+
+
+Device Disconnected Event
+=========================
+
+ Event Code: 0x000C
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Reason (1 Octet)
+
+ This event indicates that the baseband connection was lost to a
+ remote device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ For devices using resolvable random addresses with a known
+ identity resolving key, the Address and Address_Type will
+ contain the identity information.
+
+ Possible values for the Reason parameter:
+ 0 Unspecified
+ 1 Connection timeout
+ 2 Connection terminated by local host
+ 3 Connection terminated by remote host
+
+ Note that the local/remote distinction just determines which side
+ terminated the low-level connection, regardless of the
+ disconnection of the higher-level profiles.
+
+ This can sometimes be misleading and thus must be used with care.
+ For example, some hardware combinations would report a locally
+ initiated disconnection even if the user turned Bluetooth off in
+ the remote side.
+
+
+Connect Failed Event
+====================
+
+ Event Code: 0x000D
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Status (1 Octet)
+
+ This event indicates that a connection attempt failed to a
+ remote device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ For devices using resolvable random addresses with a known
+ identity resolving key, the Address and Address_Type will
+ contain the identity information.
+
+
+PIN Code Request Event
+======================
+
+ Event Code: 0x000E
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Secure (1 Octet)
+
+ This event is used to request a PIN Code reply from user space.
+ The reply should either be returned using the PIN Code Reply or
+ the PIN Code Negative Reply command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ Secure: 0x01 secure PIN code required
+ 0x00 secure PIN code not required
+
+
+User Confirmation Request Event
+===============================
+
+ Event Code: 0x000F
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Confirm_Hint (1 Octet)
+ Value (4 Octets)
+
+ This event is used to request a user confirmation request from
+ user space.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ If the Confirm_Hint parameter value is 0x01 this means that
+ a simple "Yes/No" confirmation should be presented to the user
+ instead of a full numerical confirmation (in which case the
+ parameter value will be 0x00).
+
+ User space should respond to this command either using the User
+ Confirmation Reply or the User Confirmation Negative Reply
+ command.
+
+
+User Passkey Request Event
+==========================
+
+ Event Code: 0x0010
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This event is used to request a passkey from user space. The
+ response to this event should either be the User Passkey Reply
+ command or the User Passkey Negative Reply command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+
+Authentication Failed Event
+===========================
+
+ Event Code: 0x0011
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Status (1 Octet)
+
+ This event indicates that there was an authentication failure
+ with a remote device.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+
+Device Found Event
+==================
+
+ Event Code: 0x0012
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ RSSI (1 Octet)
+ Flags (4 Octets)
+ EIR_Data_Length (2 Octets)
+ EIR_Data (0-65535 Octets)
+
+ This event indicates that a device was found during device
+ discovery.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The following bits are defined for the Flags parameter:
+ 0 Confirm name
+ 1 Legacy Pairing
+
+ The Confirm name flag indicates that the kernel wants to know
+ whether user space knows the name for this device or not. If
+ this flag is set user space should respond to it using the
+ Confirm Name command.
+
+ The Legacy Pairing flag indicates that Legacy Pairing is likely
+ to occur when pairing with this device. An application could use
+ this information to optimize the pairing process by locally
+ pre-generating a PIN code and thereby eliminate the risk of
+ local input timeout when pairing. Note that there is a risk of
+ false-positives for this flag so user space should be able to
+ handle getting something else as a PIN Request when pairing.
+
+
+Discovering Event
+=================
+
+ Event Code: 0x0013
+ Controller Index: <controller id>
+ Event Parameters: Address_Type (1 Octet)
+ Discovering (1 Octet)
+
+ This event indicates that the controller has started discovering
+ devices. This discovering state can come and go multiple times
+ between a StartDiscover and a StopDiscovery command.
+
+ The valid values for the Discovering parameter are 0x01
+ (enabled) and 0x00 (disabled).
+
+
+Device Blocked Event
+====================
+
+ Event Code: 0x0014
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This event indicates that a device has been blocked using the
+ Block Device command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The event will only be sent to Management sockets other than the
+ one through which the command was sent.
+
+
+Device Unblocked Event
+======================
+
+ Event Code: 0x0015
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This event indicates that a device has been unblocked using the
+ Unblock Device command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The event will only be sent to Management sockets other than the
+ one through which the command was sent.
+
+
+Device Unpaired Event
+=====================
+
+ Event Code: 0x0016
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+
+ This event indicates that a device has been unpaired (i.e. all
+ its keys have been removed from the kernel) using the Unpair
+ Device command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ For devices using resolvable random addresses with a known
+ identity resolving key, the event paramters will contain
+ the identity. After receiving this event, the device will
+ become essentially private again.
+
+ The event will only be sent to Management sockets other than the
+ one through which the Unpair Device command was sent.
+
+
+Passkey Notify Event
+====================
+
+ Event Code: 0x0017
+ Controller Index: <controller id>
+ Event Parameters: Address (6 Octets)
+ Address_Type (1 Octet)
+ Passkey (4 Octets)
+ Entered (1 Octet)
+
+ This event is used to request passkey notification to the user.
+ Unlike the other authentication events it does not need
+ responding to using any Management command.
+
+ Possible values for the Address_Type parameter:
+ 0 BR/EDR
+ 1 LE Public
+ 2 LE Random
+
+ The Passkey parameter indicates the passkey to be shown to the
+ user whereas the Entered parameter indicates how many characters
+ the user has entered on the remote side.
+
+
+New Identity Resolving Key Event
+================================
+
+ Event Code: 0x0018
+ Controller Index: <controller id>
+ Event Parameters: Store_Hint (1 Octet)
+ Random_Address (6 Octets)
+ Key {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Value (16 Octets)
+ }
+
+ This event indicates that a new identity resolving key has been
+ generated for a remote device.
+
+ The Store_Hint parameter indicates whether the host is expected
+ to store the key persistently or not.
+
+ The Random_Address provides the resolvable random address that
+ was resolved into an identity. A value of 00:00:00:00:00:00
+ indicates that the identity resolving key was provided for
+ a public address or static random address.
+
+ Once this event has been send for a resolvable random address,
+ all further events mapping this device will send out using the
+ identity address information.
+
+ This event also indicates that now the identity address should
+ be used for commands instead of the resolvable random address.
+
+ Possible values for the Address_Type parameter:
+ 0 Reserved (not in use)
+ 1 LE Public
+ 2 LE Random
+
+ The provided Address and Address_Type are the identity of
+ a device. So either its public address or static random address.
+
+
+New Signature Resolving Key Event
+=================================
+
+ Event Code: 0x0019
+ Controller Index: <controller id>
+ Event Parameters: Store_Hint (1 Octet)
+ Key {
+ Address (6 Octets)
+ Address_Type (1 Octet)
+ Master (1 Octet)
+ Value (16 Octets)
+ }
+
+ This event indicates that a new signature resolving key has been
+ generated for either the master or slave device.
+
+ The Store_Hint parameter indicates whether the host is expected
+ to store the key persistently or not.
+
+ When the Master parameter is set to 0x01, then the signature
+ resolving key from the remote peer device is provided. It is
+ the key that is used for signature verification.
+
+ When the Master parameter is set to 0x00, then it is the local
+ signature resolving key that is used to sign data. The remote
+ peer device will be using it for signature verification.
+
+ The local signature resolving key will be generated with each
+ pairing request. Only after receiving this event with Master
+ parameter set to 0x00 it is possible to use ATT Signed Write
+ procedures.
+
+ Possible values for the Address_Type parameter:
+ 0 Reserved (not in use)
+ 1 LE Public
+ 2 LE Random
+
+ The provided Address and Address_Type are the identity of
+ a device. So either its public address or static random address.
diff --git a/contrib/bluez-api-5.20-fixed/network-api.txt b/contrib/bluez-api-5.20-fixed/network-api.txt
new file mode 100644
index 0000000..109da28
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/network-api.txt
@@ -0,0 +1,76 @@
+BlueZ D-Bus Network API description
+***********************************
+
+
+Network hierarchy
+=================
+
+Service org.bluez
+Interface org.bluez.Network1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Methods string Connect(string uuid)
+
+ Connect to the network device and return the network
+ interface name. Examples of the interface name are
+ bnep0, bnep1 etc.
+
+ uuid can be either one of "gn", "panu" or "nap" (case
+ insensitive) or a traditional string representation of
+ UUID or a hexadecimal number.
+
+ The connection will be closed and network device
+ released either upon calling Disconnect() or when
+ the client disappears from the message bus.
+
+ Possible errors: org.bluez.Error.AlreadyConnected
+ org.bluez.Error.ConnectionAttemptFailed
+
+ void Disconnect()
+
+ Disconnect from the network device.
+
+ To abort a connection attempt in case of errors or
+ timeouts in the client it is fine to call this method.
+
+ Possible errors: org.bluez.Error.Failed
+
+Properties boolean Connected [readonly]
+
+ Indicates if the device is connected.
+
+ string Interface [readonly]
+
+ Indicates the network interface name when available.
+
+ string UUID [readonly]
+
+ Indicates the connection role when available.
+
+
+Network server hierarchy
+========================
+
+Service org.bluez
+Interface org.bluez.NetworkServer1
+Object path /org/bluez/{hci0,hci1,...}
+
+Methods void Register(string uuid, string bridge)
+
+ Register server for the provided UUID. Every new
+ connection to this server will be added the bridge
+ interface.
+
+ Valid UUIDs are "gn", "panu" or "nap".
+
+ Initially no network server SDP is provided. Only
+ after this method a SDP record will be available
+ and the BNEP server will be ready for incoming
+ connections.
+
+ void Unregister(string uuid)
+
+ Unregister the server for provided UUID.
+
+ All servers will be automatically unregistered when
+ the calling application terminates.
diff --git a/contrib/bluez-api-5.20-fixed/obex-agent-api.txt b/contrib/bluez-api-5.20-fixed/obex-agent-api.txt
new file mode 100644
index 0000000..3923da6
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/obex-agent-api.txt
@@ -0,0 +1,61 @@
+OBEX D-Bus Agent API description
+********************************
+
+
+Agent Manager hierarchy
+=======================
+
+Service org.bluez.obex
+Interface org.bluez.obex.AgentManager1
+Object path /org/bluez/obex
+
+Methods void RegisterAgent(object agent)
+
+ Register an agent to request authorization of
+ the user to accept/reject objects. Object push
+ service needs to authorize each received object.
+
+ Possible errors: org.bluez.obex.Error.AlreadyExists
+
+ void UnregisterAgent(object agent)
+
+ This unregisters the agent that has been previously
+ registered. The object path parameter must match the
+ same value that has been used on registration.
+
+ Possible errors: org.bluez.obex.Error.DoesNotExist
+
+
+Agent hierarchy
+===============
+
+Service unique name
+Interface org.bluez.obex.Agent1
+Object path freely definable
+
+Methods void Release()
+
+ This method gets called when the service daemon
+ unregisters the agent. An agent can use it to do
+ cleanup tasks. There is no need to unregister the
+ agent, because when this method gets called it has
+ already been unregistered.
+
+ string AuthorizePush(object transfer)
+
+ This method gets called when the service daemon
+ needs to accept/reject a Bluetooth object push request.
+
+ Returns the full path (including the filename) where
+ the object shall be stored. The tranfer object will
+ contain a Filename property that contains the default
+ location and name that can be returned.
+
+ Possible errors: org.bluez.obex.Error.Rejected
+ org.bluez.obex.Error.Canceled
+
+ void Cancel()
+
+ This method gets called to indicate that the agent
+ request failed before a reply was returned. It cancels
+ the previous request.
diff --git a/contrib/bluez-api-5.20-fixed/obex-api.txt b/contrib/bluez-api-5.20-fixed/obex-api.txt
new file mode 100644
index 0000000..9542a30
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/obex-api.txt
@@ -0,0 +1,834 @@
+OBEX D-Bus API description
+**************************
+
+
+Client hierarchy
+================
+
+Service org.bluez.obex
+Interface org.bluez.obex.Client1
+Object path /org/bluez/obex
+
+Methods object CreateSession(string destination, dict args)
+
+ Create a new OBEX session for the given remote address.
+
+ The last parameter is a dictionary to hold optional or
+ type-specific parameters. Typical parameters that can
+ be set in this dictionary include the following:
+
+ string "Target" : type of session to be created
+ string "Source" : local address to be used
+ byte "Channel"
+
+ The currently supported targets are the following:
+
+ "ftp"
+ "map"
+ "opp"
+ "pbap"
+ "sync"
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void RemoveSession(object session)
+
+ Unregister session and abort pending transfers.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.NotAuthorized
+
+Session hierarchy
+=================
+
+Service org.bluez.obex
+Interface org.bluez.obex.Session1
+Object path /org/bluez/obex/server/session{0, 1, 2, ...} or
+ /org/bluez/obex/client/session{0, 1, 2, ...}
+
+Methods string GetCapabilities()
+
+ Get remote device capabilities.
+
+ Possible errors: org.bluez.obex.Error.NotSupported
+ org.bluez.obex.Error.Failed
+
+Properties string Source [readonly]
+
+ Bluetooth adapter address
+
+ string Destination [readonly]
+
+ Bluetooth device address
+
+ byte Channel [readonly]
+
+ Bluetooth channel
+
+ string Target [readonly]
+
+ Target UUID
+
+ string Root [readonly]
+
+ Root path
+
+
+Transfer hierarchy
+==================
+
+Service org.bluez.obex
+Interface org.bluez.obex.Transfer1
+Object path [Session object path]/transfer{0, 1, 2, ...}
+
+Methods void Cancel()
+
+ Stops the current transference.
+
+ Possible errors: org.bluez.obex.Error.NotAuthorized
+ org.bluez.obex.Error.InProgress
+ org.bluez.obex.Error.Failed
+
+ void Suspend()
+
+ Suspend transference.
+
+ Possible errors: org.bluez.obex.Error.NotAuthorized
+ org.bluez.obex.Error.NotInProgress
+
+ Note that it is not possible to suspend transfers
+ which are queued which is why NotInProgress is listed
+ as possible error.
+
+ void Resume()
+
+ Resume transference.
+
+ Possible errors: org.bluez.obex.Error.NotAuthorized
+ org.bluez.obex.Error.NotInProgress
+
+ Note that it is not possible to resume transfers
+ which are queued which is why NotInProgress is listed
+ as possible error.
+
+Properties string Status [readonly]
+
+ Inform the current status of the transfer.
+
+ Possible values: "queued", "active", "suspended",
+ "complete" or "error"
+
+ object Session [readonly]
+
+ The object path of the session the transfer belongs
+ to.
+
+ string Name [readonly]
+
+ Name of the transferred object. Either Name or Type
+ or both will be present.
+
+ string Type [readonly]
+
+ Type of the transferred object. Either Name or Type
+ or both will be present.
+
+ uint64 Time [readonly, optional]
+
+ Time of the transferred object if this is
+ provided by the remote party.
+
+ uint64 Size [readonly, optional]
+
+ Size of the transferred object. If the size is
+ unknown, then this property will not be present.
+
+ uint64 Transferred [readonly, optional]
+
+ Number of bytes transferred. For queued transfers, this
+ value will not be present.
+
+ string Filename [readonly, optional]
+
+ Complete name of the file being received or sent.
+
+ For incoming object push transaction, this will be
+ the proposed default location and name. It can be
+ overwritten by the AuthorizePush agent callback
+ and will be then updated accordingly.
+
+
+Object Push hierarchy
+=====================
+
+Service org.bluez.obex
+Interface org.bluez.obex.ObjectPush1
+Object path [Session object path]
+
+Methods object, dict SendFile(string sourcefile)
+
+ Send one local file to the remote device.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ object, dict PullBusinessCard(string targetfile)
+
+ Request the business card from a remote device and
+ store it in the local file.
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ object, dict ExchangeBusinessCards(string clientfile,
+ string targetfile)
+
+ Push the client's business card to the remote device
+ and then retrieve the remote business card and store
+ it in a local file.
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+
+File Transfer hierarchy
+=======================
+
+Service org.bluez.obex
+Interface org.bluez.obex.FileTransfer
+Object path [Session object path]
+
+Methods void ChangeFolder(string folder)
+
+ Change the current folder of the remote device.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void CreateFolder(string folder)
+
+ Create a new folder in the remote device.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ array{dict} ListFolder()
+
+ Returns a dictionary containing information about
+ the current folder content.
+
+ The following keys are defined:
+
+ string Name : Object name in UTF-8 format
+ string Type : Either "folder" or "file"
+ uint64 Size : Object size or number of items in
+ folder
+ string Permission : Group, owner and other
+ permission
+ uint64 Modified : Last change
+ uint64 Accessed : Last access
+ uint64 Created : Creation date
+
+ Possible errors: org.bluez.obex.Error.Failed
+
+ object, dict GetFile(string targetfile, string sourcefile)
+
+ Copy the source file (from remote device) to the
+ target file (on local filesystem).
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ object, dict PutFile(string sourcefile, string targetfile)
+
+ Copy the source file (from local filesystem) to the
+ target file (on remote device).
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void CopyFile(string sourcefile, string targetfile)
+
+ Copy a file within the remote device from source file
+ to target file.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void MoveFile(string sourcefile, string targetfile)
+
+ Move a file within the remote device from source file
+ to the target file.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void Delete(string file)
+
+ Deletes the specified file/folder.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+
+Phonebook Access hierarchy
+==========================
+
+Service org.bluez.obex
+Interface org.bluez.obex.PhonebookAccess1
+Object path [Session object path]
+
+Methods void Select(string location, string phonebook)
+
+ Select the phonebook object for other operations. Should
+ be call before all the other operations.
+
+ location : Where the phonebook is stored, possible
+ inputs :
+ "int" ( "internal" which is default )
+ "sim" ( "sim1" )
+ "sim2"
+ ...
+
+ phonebook : Possible inputs :
+ "pb" : phonebook for the saved contacts
+ "ich": incoming call history
+ "och": outgoing call history
+ "mch": missing call history
+ "cch": combination of ich och mch
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ object, dict PullAll(string targetfile, dict filters)
+
+ Return the entire phonebook object from the PSE server
+ in plain string with vcard format, and store it in
+ a local file.
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible filters: Format, Order, Offset, MaxCount and
+ Fields
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Forbidden
+
+ array{string vcard, string name} List(dict filters)
+
+ Return an array of vcard-listing data where every entry
+ consists of a pair of strings containing the vcard
+ handle and the contact name. For example:
+ "1.vcf" : "John"
+
+ Possible filters: Order, Offset and MaxCount
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Forbidden
+
+ object, dict
+ Pull(string vcard, string targetfile, dict filters)
+
+ Given a vcard handle, retrieve the vcard in the current
+ phonebook object and store it in a local file.
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possbile filters: Format and Fields
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Forbidden
+ org.bluez.obex.Error.Failed
+
+ array{string vcard, string name}
+ Search(string field, string value, dict filters)
+
+ Search for entries matching the given condition and
+ return an array of vcard-listing data where every entry
+ consists of a pair of strings containing the vcard
+ handle and the contact name.
+
+ vcard : name paired string match the search condition.
+
+ field : the field in the vcard to search with
+ { "name" (default) | "number" | "sound" }
+ value : the string value to search for
+
+
+ Possible filters: Order, Offset and MaxCount
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Forbidden
+ org.bluez.obex.Error.Failed
+
+ uint16 GetSize()
+
+ Return the number of entries in the selected phonebook
+ object that are actually used (i.e. indexes that
+ correspond to non-NULL entries).
+
+ Possible errors: org.bluez.obex.Error.Forbidden
+ org.bluez.obex.Error.Failed
+
+ array{string} ListFilterFields()
+
+ Return All Available fields that can be used in Fields
+ filter.
+
+ Possible errors: None
+
+Filter: string Format:
+
+ Items vcard format
+
+ Possible values: "vcard21" (default) or "vcard30"
+
+ string Order:
+
+ Items order
+
+ Possible values: "indexed" (default), "alphanumeric" or
+ "phonetic"
+
+ uint16 Offset:
+
+ Offset of the first item, default is 0
+
+ uint16 MaxCount:
+
+ Maximum number of items, default is unlimited (65535)
+
+ array{string} Fields:
+
+ Item vcard fields, default is all values.
+
+ Possible values can be query with ListFilterFields.
+
+
+Synchronization hierarchy
+=========================
+
+Service org.bluez.obex
+Interface org.bluez.obex.Synchronization1
+Object path [Session object path]
+
+Methods void SetLocation(string location)
+
+ Set the phonebook object store location for other
+ operations. Should be called before all the other
+ operations.
+
+ location: Where the phonebook is stored, possible
+ values:
+ "int" ( "internal" which is default )
+ "sim1"
+ "sim2"
+ ......
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+
+ object, dict GetPhonebook(string targetfile)
+
+ Retrieve an entire Phonebook Object store from remote
+ device, and stores it in a local file.
+
+ If an empty target file is given, a name will be
+ automatically calculated for the temporary file.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ object, dict PutPhonebook(string sourcefile)
+
+ Send an entire Phonebook Object store to remote device.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+
+Message Access hierarchy
+=========================
+
+Service org.bluez.obex
+Interface org.bluez.obex.MessageAccess1
+Object path [Session object path]
+
+Methods void SetFolder(string name)
+
+ Set working directory for current session, *name* may
+ be the directory name or '..[/dir]'.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ array{dict} ListFolders(dict filter)
+
+ Returns a dictionary containing information about
+ the current folder content.
+
+ The following keys are defined:
+
+ string Name : Folder name
+
+ Possible filters: Offset and MaxCount
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ array{string} ListFilterFields()
+
+ Return all available fields that can be used in Fields
+ filter.
+
+ Possible errors: None
+
+ array{object, dict} ListMessages(string folder, dict filter)
+
+ Returns an array containing the messages found in the
+ given subfolder of the current folder, or in the
+ current folder if folder is empty.
+
+ Possible Filters: Offset, MaxCount, SubjectLength, Fields,
+ Type, PeriodStart, PeriodEnd, Status, Recipient, Sender,
+ Priority
+
+ Each message is represented by an object path followed
+ by a dictionary of the properties.
+
+ Properties:
+
+ string Subject:
+
+ Message subject
+
+ string Timestamp:
+
+ Message timestamp
+
+ string Sender:
+
+ Message sender name
+
+ string SenderAddress:
+
+ Message sender address
+
+ string ReplyTo:
+
+ Message Reply-To address
+
+ string Recipient:
+
+ Message recipient name
+
+ string RecipientAddress:
+
+ Message recipient address
+
+ string Type:
+
+ Message type
+
+ Possible values: "email", "sms-gsm",
+ "sms-cdma" and "mms"
+
+ uint64 Size:
+
+ Message size in bytes
+
+ boolean Text:
+
+ Message text flag
+
+ Specifies whether message has textual
+ content or is binary only
+
+ string Status:
+
+ Message status
+
+ Possible values for received messages:
+ "complete", "fractioned", "notification"
+
+ Possible values for sent messages:
+ "delivery-success", "sending-success",
+ "delivery-failure", "sending-failure"
+
+ uint64 AttachmentSize:
+
+ Message overall attachment size in bytes
+
+ boolean Priority:
+
+ Message priority flag
+
+ boolean Read:
+
+ Message read flag
+
+ boolean Sent:
+
+ Message sent flag
+
+ boolean Protected:
+
+ Message protected flag
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+ void UpdateInbox(void)
+
+ Request remote to update its inbox.
+
+ Possible errors: org.bluez.obex.Error.Failed
+
+ object, dict
+ PushMessage(string sourcefile, string folder, dict args)
+
+ Transfer a message (in bMessage format) to the
+ remote device.
+
+ The message is transferred either to the given
+ subfolder of the current folder, or to the current
+ folder if folder is empty.
+
+ Possible args: Transparent, Retry, Charset
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetAll.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+
+Filter: uint16 Offset:
+
+ Offset of the first item, default is 0
+
+ uint16 MaxCount:
+
+ Maximum number of items, default is 1024
+
+ byte SubjectLength:
+
+ Maximum length of the Subject property in the
+ message, default is 256
+
+ array{string} Fields:
+
+ Message fields, default is all values.
+
+ Possible values can be query with ListFilterFields.
+
+ array{string} Types:
+
+ Filter messages by type.
+
+ Possible values: "sms", "email", "mms".
+
+ string PeriodBegin:
+
+ Filter messages by starting period.
+
+ Possible values: Date in "YYYYMMDDTHHMMSS" format.
+
+ string PeriodEnd:
+
+ Filter messages by ending period.
+
+ Possible values: Date in "YYYYMMDDTHHMMSS" format.
+
+ boolean Read:
+
+ Filter messages by read flag.
+
+ Possible values: True for read or False for unread
+
+ string Recipient:
+
+ Filter messages by recipient address.
+
+ string Sender:
+
+ Filter messages by sender address.
+
+ boolean Priority:
+
+ Filter messages by priority flag.
+
+ Possible values: True for high priority or False for
+ non-high priority
+
+Message hierarchy
+=================
+
+Service org.bluez.obex
+Interface org.bluez.obex.Message1
+Object path [Session object path]/{message0,...}
+
+Methods object, dict Get(string targetfile, boolean attachment)
+
+ Download message and store it in the target file.
+
+ If an empty target file is given, a temporary file
+ will be automatically generated.
+
+ The returned path represents the newly created transfer,
+ which should be used to find out if the content has been
+ successfully transferred or if the operation fails.
+
+ The properties of this transfer are also returned along
+ with the object path, to avoid a call to GetProperties.
+
+ Possible errors: org.bluez.obex.Error.InvalidArguments
+ org.bluez.obex.Error.Failed
+
+Properties string Folder [readonly]
+
+ Folder which the message belongs to
+
+ string Subject [readonly]
+
+ Message subject
+
+ string Timestamp [readonly]
+
+ Message timestamp
+
+ string Sender [readonly]
+
+ Message sender name
+
+ string SenderAddress [readonly]
+
+ Message sender address
+
+ string ReplyTo [readonly]
+
+ Message Reply-To address
+
+ string Recipient [readonly]
+
+ Message recipient name
+
+ string RecipientAddress [readonly]
+
+ Message recipient address
+
+ string Type [readonly]
+
+ Message type
+
+ Possible values: "email", "sms-gsm",
+ "sms-cdma" and "mms"
+
+ uint64 Size [readonly]
+
+ Message size in bytes
+
+ string Status [readonly]
+
+ Message reception status
+
+ Possible values: "complete",
+ "fractioned" and "notification"
+
+ boolean Priority [readonly]
+
+ Message priority flag
+
+ boolean Read [read/write]
+
+ Message read flag
+
+ boolean Deleted [writeonly]
+
+ Message deleted flag
+
+ boolean Sent [readonly]
+
+ Message sent flag
+
+ boolean Protected [readonly]
+
+ Message protected flag
diff --git a/contrib/bluez-api-5.20-fixed/obex_agent.xml b/contrib/bluez-api-5.20-fixed/obex_agent.xml
new file mode 100644
index 0000000..1d55843
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/obex_agent.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<node name="/org/blueztools/obex">
+ <interface name="org.bluez.obex.Agent1">
+ <method name="Release">
+ </method>
+ <method name="AuthorizePush">
+ <arg name="transfer" direction="in" type="o"/>
+ <arg name="filepath" direction="out" type="s"/>
+ </method>
+ <method name="Cancel">
+ </method>
+ </interface>
+</node>
diff --git a/contrib/bluez-api-5.20-fixed/profile-api.txt b/contrib/bluez-api-5.20-fixed/profile-api.txt
new file mode 100644
index 0000000..4917e2e
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/profile-api.txt
@@ -0,0 +1,147 @@
+BlueZ D-Bus Profile API description
+***********************************
+
+
+Profile Manager hierarchy
+=========================
+
+Service org.bluez
+Interface org.bluez.ProfileManager1
+Object path /org/bluez
+
+Methods void RegisterProfile(object profile, string uuid, dict options)
+
+ This registers a profile implementation.
+
+ If an application disconnects from the bus all
+ its registered profiles will be removed.
+
+ HFP HS UUID: 0000111e-0000-1000-8000-00805f9b34fb
+
+ Default RFCOMM channel is 6. And this requires
+ authentication.
+
+ Available options:
+
+ string Name
+
+ Human readable name for the profile
+
+ string Service
+
+ The primary service class UUID
+ (if different from the actual
+ profile UUID)
+
+ string Role
+
+ For asymmetric profiles that do not
+ have UUIDs available to uniquely
+ identify each side this
+ parameter allows specifying the
+ precise local role.
+
+ Possible values: "client", "server"
+
+ uint16 Channel
+
+ RFCOMM channel number that is used
+ for client and server UUIDs.
+
+ If applicable it will be used in the
+ SDP record as well.
+
+ uint16 PSM
+
+ PSM number that is used for client
+ and server UUIDs.
+
+ If applicable it will be used in the
+ SDP record as well.
+
+ boolean RequireAuthentication
+
+ Pairing is required before connections
+ will be established. No devices will
+ be connected if not paired.
+
+ boolean RequireAuthorization
+
+ Request authorization before any
+ connection will be established.
+
+ boolean AutoConnect
+
+ In case of a client UUID this will
+ force connection of the RFCOMM or
+ L2CAP channels when a remote device
+ is connected.
+
+ string ServiceRecord
+
+ Provide a manual SDP record.
+
+ uint16 Version
+
+ Profile version (for SDP record)
+
+ uint16 Features
+
+ Profile features (for SDP record)
+
+ Possible errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.AlreadyExists
+
+ void UnregisterProfile(object profile)
+
+ This unregisters the profile that has been previously
+ registered. The object path parameter must match the
+ same value that has been used on registration.
+
+ Possible errors: org.bluez.Error.DoesNotExist
+
+
+Profile hierarchy
+=================
+
+Service unique name
+Interface org.bluez.Profile1
+Object path freely definable
+
+Methods void Release() [noreply]
+
+ This method gets called when the service daemon
+ unregisters the profile. A profile can use it to do
+ cleanup tasks. There is no need to unregister the
+ profile, because when this method gets called it has
+ already been unregistered.
+
+ void NewConnection(object device, fd fd, dict fd_properties)
+
+ This method gets called when a new service level
+ connection has been made and authorized.
+
+ Common fd_properties:
+
+ uint16 Version Profile version (optional)
+ uint16 Features Profile features (optional)
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
+
+ void RequestDisconnection(object device)
+
+ This method gets called when a profile gets
+ disconnected.
+
+ The file descriptor is no longer owned by the service
+ daemon and the profile implementation needs to take
+ care of cleaning up all connections.
+
+ If multiple file descriptors are indicated via
+ NewConnection, it is expected that all of them
+ are disconnected before returning from this
+ method call.
+
+ Possible errors: org.bluez.Error.Rejected
+ org.bluez.Error.Canceled
diff --git a/contrib/bluez-api-5.20-fixed/proximity-api.txt b/contrib/bluez-api-5.20-fixed/proximity-api.txt
new file mode 100644
index 0000000..5322544
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/proximity-api.txt
@@ -0,0 +1,56 @@
+BlueZ D-Bus Proximity API description
+***********************************
+
+
+Proximity Monitor hierarchy
+===========================
+
+Service org.bluez
+Interface org.bluez.ProximityMonitor1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Properties string SignalLevel [readonly]
+
+ Alert indicating that a threshold has been reached.
+ Possible values: "unknown", "good", "regular", "weak"
+
+ string LinkLossAlertLevel [readwrite]
+
+ Persistent property. Sets the alert level in the
+ proximity reporter for link loss scenario. Values:
+ "none", "mild", "high".
+
+ string ImmediateAlertLevel [readwrite]
+
+ Alert level to be written in the Immediate Alert Level.
+ Property shared between Path Loss and Find Me.
+ Values: "none", "mild", "high". Default value is
+ "none". Applications can disable the alert setting
+ the value to "none". If the "Target" is not found,
+ "none" will be emitted after the configured timeout.
+ When changing the level, signal is the confirmation
+ that the value was written in the remote.
+
+Proximity Reporter hierarchy
+===========================
+
+Shared service used by Proximity Path Loss and Find Me. Allows per device
+alert level handling.
+
+Service org.bluez
+Interface org.bluez.ProximityReporter1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+Properties string ImmediateAlertLevel [readonly]
+
+ This property indicates that Immediate Alert Level
+ characteristic in the local Immediate Alert Service
+ was changed by the remote device. Property shared
+ between Path Loss and Find Me. Values: "none", "mild",
+ "high".
+
+ string LinkLossAlertLevel [readonly]
+
+ This property indicates that Alert Level characteristic
+ in the local Link Loss Service was changed by the
+ remote device. Values: "none", "mild", "high".
diff --git a/contrib/bluez-api-5.20-fixed/sap-api.txt b/contrib/bluez-api-5.20-fixed/sap-api.txt
new file mode 100644
index 0000000..b28c4e3
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/sap-api.txt
@@ -0,0 +1,20 @@
+BlueZ D-Bus Sim Access API description
+**************************************
+
+
+Sim Access Profile hierarchy
+============================
+
+Service org.bluez
+Interface org.bluez.SimAccess1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods void Disconnect()
+
+ Disconnects SAP client from the server.
+
+ Possible errors: org.bluez.Error.Failed
+
+Properties boolean Connected [readonly]
+
+ Indicates if SAP client is connected to the server.
diff --git a/contrib/bluez-api-5.20-fixed/settings-storage.txt b/contrib/bluez-api-5.20-fixed/settings-storage.txt
new file mode 100644
index 0000000..7cdecd5
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/settings-storage.txt
@@ -0,0 +1,228 @@
+BlueZ settings storage
+**********************
+
+Purpose
+=======
+
+The purpose of this document is to describe the directory structure of
+BlueZ settings storage. In effect, this document will serve as the primary,
+up to date source of BlueZ storage information.
+
+It is intended as reference for developers. Direct access to the storage
+outside from bluetoothd is highly discouraged.
+
+Adapter and remote device info are read form the storage during object
+initialization. Write to storage is performed immediately on every value
+change.
+
+Default storage directory is /var/lib/bluetooth. This can be adjusted
+by the --localstatedir configure switch. Default is --localstatedir=/var.
+
+All files are in ini-file format.
+
+
+Storage directory structure
+===========================
+
+There is one directory per adapter, named by its Bluetooth address, which
+contains:
+ - a settings file for the local adapter
+ - an attributes file containing attributes of supported LE services
+ - a cache directory containing:
+ - one file per device, named by remote device address, which contains
+ device name
+ - one directory per remote device, named by remote device address, which
+ contains:
+ - an info file
+ - an attributes file containing attributes of remote LE services
+ - a ccc file containing persistent Client Characteristic Configuration
+ (CCC) descriptor information for GATT characteristics
+
+So the directory structure is:
+ /var/lib/bluetooth/<adapter address>/
+ ./settings
+ ./attributes
+ ./cache/
+ ./<remote device address>
+ ./<remote device address>
+ ...
+ ./<remote device address>/
+ ./info
+ ./attributes
+ ./ccc
+ ./<remote device address>/
+ ./info
+ ./attributes
+ ...
+
+
+Settings file format
+====================
+
+Settings file contains one [General] group with adapter info like:
+
+ Alias String Friendly user provided name advertised
+ for this adapter
+
+ This value overwrites the system
+ name (pretty hostname)
+
+ Discoverable Boolean Discoverability of the adapter
+
+ PairableTimeout Integer How long to stay in pairable mode
+ before going back to non-pairable.
+ The value is in seconds.
+ 0 = disable timer, i.e. stay
+ pairable forever
+
+ DiscoverableTimeout Integer How long to stay in discoverable mode
+ before going back to non-discoverable.
+ The value is in seconds.
+ 0 = disable timer, i.e. stay
+ discoverable forever
+
+Sample:
+ [General]
+ Name=My PC
+ Discoverable=false
+ Pairable=true
+ DiscoverableTimeout=0
+
+
+Attributes file format
+======================
+
+The attributes file lists all attributes supported by the local adapter or
+remote device.
+
+Attributes are stored using their handle as group name (decimal format).
+
+Each group contains:
+
+ UUID String 128-bit UUID of the attribute
+
+ Value String Value of the attribute as hexadecimal encoded
+ string
+
+ EndGroupHandle Integer End group handle in decimal format
+
+Sample:
+ [1]
+ UUID=00002800-0000-1000-8000-00805f9b34fb
+ Value=0018
+
+ [4]
+ UUID=00002803-0000-1000-8000-00805f9b34fb
+ Value=020600002A
+
+ [6]
+ UUID=00002a00-0000-1000-8000-00805f9b34fb
+ Value=4578616D706C6520446576696365
+
+
+CCC file format
+======================
+
+The ccc file stores the current CCC descriptor values for GATT characteristics
+which have notification/indication enabled by the remote device.
+
+Information is stored using CCC attribute handle as group name (in decimal
+format).
+
+Each group contains:
+
+ Value String CCC descriptor value encoded in
+ hexadecimal
+
+
+Cache directory file format
+============================
+
+Each file, named by remote device address, may includes multiple groups
+(General and ServiceRecords).
+
+In ServiceRecords, SDP records are stored using their handle as key
+(hexadecimal format).
+
+[General] group contains:
+
+ Name String Remote device friendly name
+
+ ShortName String Remote device shortened name
+
+[ServiceRecords] group contains
+
+ <0x...> String SDP record as hexadecimal encoded
+ string
+
+
+Info file format
+================
+
+Info file may includes multiple groups (General, Device ID, Link key and
+Long term key) related to a remote device.
+
+[General] group contains:
+
+ Name String Remote device friendly name
+
+ Alias String Alias name
+
+ Class String Device class in hexadecimal,
+ i.e. 0x000000
+
+ Appearance String Device appearance in hexadecimal,
+ i.e. 0x0000
+
+ SupportedTechnologies List of List of technologies supported by
+ strings device, separated by ";"
+ Technologies can be BR/EDR or LE
+
+ AddressType String An address can be "static" or "public"
+
+ Trusted Boolean True if the remote device is trusted
+
+ Blocked Boolean True if the remote device is blocked
+
+ Services List of List of service UUIDs advertised by
+ strings remote in 128-bits UUID format,
+ separated by ";"
+
+
+[DeviceID] group contains:
+
+ Source Integer Assigner of Device ID
+
+ Vendor Integer Device vendor
+
+ Product Integer Device product
+
+ Version Integer Device version
+
+
+[LinkKey] group contains:
+
+ Key String Key in hexadecimal format
+
+ Type Integer Type of link key
+
+ PINLength Integer Length of PIN
+
+
+[LongTermKey] group contains:
+
+ Key String Long term key in hexadecimal format
+
+ Authenticated Boolean True if remote device has been
+ authenticated
+
+ EncSize Integer Encrypted size
+
+ EDiv Integer Encrypted diversifier
+
+ Rand Integer Randomizer
+
+
+[SlaveLongTermKey] group contains:
+
+ Same as the [LongTermKey] group, except for slave keys.
diff --git a/contrib/bluez-api-5.20-fixed/supported-features.txt b/contrib/bluez-api-5.20-fixed/supported-features.txt
new file mode 100644
index 0000000..b337f78
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/supported-features.txt
@@ -0,0 +1,52 @@
+Supported features in BlueZ
+===========================
+
+Note that some profiles/roles will depend on external components such as
+oFono or ConnMan.
+
+Profile/protocol Version Role(s)
+---------------------------------------------------------------------------
+
+GAP 4.0 (LE) Central, Observer, Broadcaster
+L2CAP 4.0 Server, Client
+SDP 4.0 Server, Client
+GATT 4.0 Server, Client
+SDAP 1.1 Server, Client
+RFCOMM 1.1 Server, Client
+SPP 1.1 Server, Client
+
+PXP 1.0 Reporter, Monitor
+HOGP 1.0 Host
+HTP 1.0
+TIP 1.0
+CSCP 1.0 Collector
+
+SAP 1.1 Server
+DUN 1.1 Server, Client
+
+DID 1.3 Server, Client
+
+HFP 1.5 AG, HF
+HSP 1.2 AG, HS
+GAVDTP 1.2 Source, Sink
+AVDTP 1.3 Source, Sink
+A2DP 1.3 Source, Sink
+AVCTP 1.3 CT, TG
+AVRCP 1.5 CT, TG
+
+GOEP 2.0 Client, Server
+FTP 1.2 Client, Server
+OPP 1.2 Client, Server
+SYNCH 1.1 Client
+PBAP 1.1 Client, Server
+MAP 1.0 Client, Server
+
+HID 1.1 Host
+
+BNEP 1.0
+PAN 1.0 PANU, NAP, GN
+
+HCRP 1.2
+
+MCAP 1.0
+HDP 1.0
diff --git a/contrib/bluez-api-5.20-fixed/test-coverage.txt b/contrib/bluez-api-5.20-fixed/test-coverage.txt
new file mode 100644
index 0000000..f70a8d5
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/test-coverage.txt
@@ -0,0 +1,69 @@
+BlueZ test coverage
+*******************
+
+
+Automated unit testing
+======================
+
+Application Count Description
+-------------------------------------------
+test-crc 9 Link Layer CRC-24 checksum
+test-eir 14 EIR and AD parsing
+test-lib 14 SDP library functions
+test-sdp 133 SDP qualification test cases
+test-uuid 30 UUID conversion handling
+test-mgmt 2 Management interface handling
+test-crypto 4 Cryptographic toolbox helpers
+test-textfile 4 Old textfile storage format
+test-ringbuf 3 Ring buffer functionality
+test-queue 1 Queue handling functionality
+test-uhid 6 Userspace HID functionality
+test-hfp 14 HFP Audio Gateway functionality
+test-avdtp 60 AVDTP qualification test cases
+test-avctp 9 AVCTP qualification test cases
+test-avrcp 92 AVRCP qualification test cases
+test-gobex 31 Generic OBEX functionality
+test-gobex-packet 9 OBEX packet handling
+test-gobex-header 28 OBEX header handling
+test-gobex-apparam 18 OBEX apparam handling
+test-gobex-transfer 36 OBEX transfer handling
+test-gdbus-client 12 D-Bus client handling
+ -----
+ 519
+
+
+Automated end-to-end testing
+============================
+
+Application Count Description
+-------------------------------------------
+mgmt-tester 189 Kernel management interface testing
+l2cap-tester 26 Kernel L2CAP implementation testing
+rfcomm-tester 9 Kernel RFCOMM implementation testing
+smp-tester 5 Kernel SMP implementation testing
+sco-tester 8 Kernel SCO implementation testing
+gap-tester 1 Daemon D-Bus API testing
+hci-tester 14 Controller hardware testing
+ -----
+ 252
+
+
+Android end-to-end testing
+==========================
+
+Application Count Description
+-------------------------------------------
+android-tester 86 Android HAL interface testing
+ipc-tester 94 Android IPC resistance testing
+ -----
+ 180
+
+
+Android automated unit testing
+==============================
+
+Application Count Description
+-------------------------------------------
+test-ipc 14 Android IPC library functions
+ -----
+ 14
diff --git a/contrib/bluez-api-5.20-fixed/thermometer-api.txt b/contrib/bluez-api-5.20-fixed/thermometer-api.txt
new file mode 100644
index 0000000..c7c8a5d
--- /dev/null
+++ b/contrib/bluez-api-5.20-fixed/thermometer-api.txt
@@ -0,0 +1,134 @@
+BlueZ D-Bus Thermometer API description
+***************************************
+
+ Santiago Carot-Nemesio <sancane@gmail.com>
+
+Health Thermometer Manager hierarchy
+====================================
+
+Service org.bluez
+Interface org.bluez.ThermometerManager1
+Object path [variable prefix]/{hci0,hci1,...}
+
+Methods RegisterWatcher(object agent)
+
+ Registers a watcher to monitor scanned measurements.
+ This agent will be notified about final temperature
+ measurements.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ UnregisterWatcher(object agent)
+
+ Unregisters a watcher.
+
+ EnableIntermediateMeasurement(object agent)
+
+ Enables intermediate measurement notifications
+ for this agent. Intermediate measurements will
+ be enabled only for thermometers which support it.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+
+ DisableIntermediateMeasurement(object agent)
+
+ Disables intermediate measurement notifications
+ for this agent. It will disable notifications in
+ thermometers when the last agent removes the
+ watcher for intermediate measurements.
+
+ Possible Errors: org.bluez.Error.InvalidArguments
+ org.bluez.Error.NotFound
+
+Health Thermometer Profile hierarchy
+====================================
+
+Service org.bluez
+Interface org.bluez.Thermometer1
+Object path [variable prefix]/{hci0,hci1,...}/dev_XX_XX_XX_XX_XX_XX
+
+
+Properties boolean Intermediate [readonly]
+
+ True if the thermometer supports intermediate
+ measurement notifications.
+
+ uint16 Interval (optional) [readwrite]
+
+ The Measurement Interval defines the time (in
+ seconds) between measurements. This interval is
+ not related to the intermediate measurements and
+ must be defined into a valid range. Setting it
+ to zero means that no periodic measurements will
+ be taken.
+
+ uint16 Maximum (optional) [readonly]
+
+ Defines the maximum value allowed for the interval
+ between periodic measurements.
+
+ uint16 Minimum (optional) [readonly]
+
+ Defines the minimum value allowed for the interval
+ between periodic measurements.
+
+
+Health Thermometer Watcher hierarchy
+====================================
+
+Service unique name
+Interface org.bluez.ThermometerWatcher1
+Object path freely definable
+
+Methods void MeasurementReceived(dict measurement)
+
+ This callback gets called when a measurement has been
+ scanned in the thermometer.
+
+ Measurement:
+
+ int16 Exponent:
+ int32 Mantissa:
+
+ Exponent and Mantissa values as
+ extracted from float value defined by
+ IEEE-11073-20601.
+
+ Measurement value is calculated as
+ (Mantissa) * (10^Exponent)
+
+ For special cases Exponent is
+ set to 0 and Mantissa is set to
+ one of following values:
+
+ +(2^23 - 1) NaN (invalid or
+ missing data)
+ -(2^23) NRes
+ +(2^23 - 2) +Infinity
+ -(2^23 - 2) -Infinity
+
+ string Unit:
+
+ Possible values: "celsius" or
+ "fahrenheit"
+
+ uint64 Time (optional):
+
+ Time of measurement, if
+ supported by device.
+ Expressed in seconds since epoch.
+
+ string Type (optional):
+
+ Only present if measurement type
+ is known.
+
+ Possible values: "armpit", "body",
+ "ear", "finger", "intestines",
+ "mouth", "rectum", "toe",
+ "tympanum"
+
+ string Measurement:
+
+ Possible values: "final" or
+ "intermediate"