summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
Commit message (Collapse)AuthorAgeFilesLines
* chromeos: Remove use of MessageLoopProxy and deprecated MessageLoop APIsskyostil2015-06-111-11/+11
| | | | | | | | | | This patch was mostly autogenerated with https://codereview.chromium.org/1010073002/. BUG=465354 Review URL: https://codereview.chromium.org/1173593002 Cr-Commit-Position: refs/heads/master@{#333996}
* chromeos/dbus: Update Bluetooth GATT API clients to upstream definitionarmansito2015-02-061-9/+18
| | | | | | | | | | | | This CL ports the GATT API bindings from the D-Bus API in our Chrome OS fork to the API definition in doc/gatt-api.txt in BlueZ upstream. TBR=keybuk@chromium.org BUG=440968 Review URL: https://codereview.chromium.org/788193004 Cr-Commit-Position: refs/heads/master@{#315095}
* Add unit testing for org.bluez.Error.* translationjamuraa2014-10-021-18/+123
| | | | | | | | | | | | | | | | | | Added checks for correct translation: * Error.Failed * Error.ReadNotPermitted * Error.WriteNotPermitted * Error.NotSupported Error.InProgress tested via new SetExtraProcessing Error.NotAuthorized tested via new SetAuthorized Error.NotPaired tested via new SetAuthenticated BUG=377232 Review URL: https://codereview.chromium.org/619973002 Cr-Commit-Position: refs/heads/master@{#297752}
* First part of errors coming up from the dbus APIjamuraa2014-10-011-2/+7
| | | | | | | | BUG=377232 Review URL: https://codereview.chromium.org/604023004 Cr-Commit-Position: refs/heads/master@{#297656}
* bluetoothLowEnergy: Send onServiceAdded after all characteristics are discoveredarmansito@chromium.org2014-07-231-0/+5
| | | | | | | | | | | | | | | | | | | | | | | This CL makes the following changes: - Add support for the new "Characteristics" and "Descriptors" properties exposed under org.bluez.GattService1 and org.bluez.GattCharacteristic1, respectively. - Add device::BluetoothGattService::Observer::GattDiscoveryCompleteForService event, which gets called after the first PropertiesChanged signal is received for the "Characteristics" property of a service. - Change BluetoothLowEnergyEventRouter, so that it sends the "onServiceAdded" event not in GattServiceAdded but in GattDiscoveryCompleteForService. BUG=394537 TEST=browser_tests:BluetoothLowEnergyApiTest, device_unittests:BluetoothGattChromeOSTest Review URL: https://codereview.chromium.org/402303002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284955 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Add device::BluetoothGattNotifySession.armansito@chromium.org2014-06-271-6/+62
| | | | | | | | | | | | | | | | | | | | | | This CL introduces device::BluetoothGattNotifySession, which represents a single instance of a request to a remote characteristic to start sending value updates if it supports notifications or indications. Instances are obtained by calling BluetoothGattCharacteristic::StartNotifySession and sessions are stopped by calling BluetoothGattNotifySession::Stop on the received instance, which is owned by the caller. The characteristic will keep sending value updates as long as there is at least one active session. This CL implements this functionality for Chrome OS by adding the necessary bindings for the new D-Bus API calls "StartNotify" and "StopNotify" on org.bluez.GattCharacteristic1. A reference count is kept for all created sessions inside BluetoothRemoteGattCharacteristicChromeOS. BUG=387989 TEST=device_unittests Review URL: https://codereview.chromium.org/352063002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@280433 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Update characteristic value D-Bus bindings.armansito@chromium.org2014-06-071-67/+62
| | | | | | | | | | | | | | | The original BlueZ GATT API doc spec used DBus.Properties interface for characteristic value access. Since we are modifying this API for Chrome OS, this CL updates the Chrome D-Bus bindings and modifies the device/bluetooth GATT code to use the new bindings for characteristic value reads, writes, and updates. BUG=378182 TEST=Tested against my custom bluetoothd build; device_unittests Review URL: https://codereview.chromium.org/301093003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275693 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Implement GATT characteristic properties on Chrome OS.armansito@chromium.org2014-06-071-12/+27
| | | | | | | | | | | | | This CL implements GATT characteristic properties for BluetoothRemoteGattCharacteristicChromeOS. Also, a typo in the "Writable Auxiliaries" property declaration has been fixed. BUG=362799 TEST=device_unittests, browser_tests Review URL: https://codereview.chromium.org/307453007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275599 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Add chromeos::BluetoothRemoteGattDescriptorChromeOS.armansito@chromium.org2014-04-111-1/+19
| | | | | | | | | | | | Added the chromeos::BluetoothRemoteGattDescriptorChromeOS class which implements a remote instance of device::BluetoothGattDescriptor for the Chrome OS platform. BUG=360266,340529 TEST=device_unittests Review URL: https://codereview.chromium.org/234443005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@263194 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Add chromeos::BluetoothRemoteGattCharacteristicChromeOS.armansito@chromium.org2014-04-101-3/+21
| | | | | | | | | | | | | Added the chromeos::BluetoothRemoteGattCharacteristicChromeOS class which implements a remote instance of device::BluetoothGattCharacteristic for the Chrome OS platform. BUG=360266,340529 TEST=device_unittests Review URL: https://codereview.chromium.org/228643004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262964 0039d316-1c4b-4281-b951-d872f2087c98
* device/bluetooth: Add chromeos::BluetoothRemoteGattServiceChromeOS.armansito@chromium.org2014-04-081-7/+7
| | | | | | | | | | | | | | | | Added the chromeos::BluetoothRemoteGattServiceChromeOS class which implements a remote instance of device::BluetoothGattService for the Chrome OS platform. This CL also introduces some minor changes to the GATT API, namely removing the characteristic and descriptor Observer interfaces. Addition, removal, and value changes of remote characteristics will instead be tracked via BluetoothGattService::Observer. BUG=360266,340529 TEST=device_unittests Review URL: https://codereview.chromium.org/224953003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262327 0039d316-1c4b-4281-b951-d872f2087c98
* chromeos/dbus: Add fake D-Bus clients for GATT client-mode.armansito@chromium.org2014-03-241-0/+342
Added fake implementations of GATT service, characteristic, and descriptor clients. A new "Low Energy" fake device is introduced, which uses the fake GATT clients to simulate the Heart Rate Service. BUG=351229 TEST=1. device_unittests, chromeos_unittests. 2. Build and run chrome for Linux with "chromeos=1". Run Bluetooth device discovery, connect to the device named "Bluetooth 4.0 Heart Rate Monitor". Watch the debug output (vmodule="*bluetooth_gatt*=2") for the GATT clients, which should create fake heart rate service and descriptors and update the measurement value at regular intervals. R=keybuk@chromium.org, stevenjb@chromium.org Review URL: https://codereview.chromium.org/206443009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@259022 0039d316-1c4b-4281-b951-d872f2087c98