Commit Graph

8293 Commits

Author SHA1 Message Date
Dmitriy Paliy
2da716f340 Add 'Protocol not supported' error in a2dp_add_sep
'Protocol not supported' error code is added to the registration of A2DP
end-points. Error response org.bluez.Error.NotSupported instead of
org.bluez.Error.InvalidArguments is used when SEP registration fails due
to disabled corresponding interface in audio.conf.
2011-03-17 14:35:55 +02:00
Johan Hedberg
4f8d6ba353 Fix missing check for dev->up before calling init_adapter
With some kernels and the right timing it is possible to get into the
state where we get the local name but haven't yet gotten a DEVUP event.
In such a case it is *not* ok to call init_adapter.
2011-03-17 14:33:02 +02:00
Marcel Holtmann
67fc00db39 Release 4.90 2011-03-15 20:25:23 -07:00
Marcel Holtmann
43bfa36567 Update library version 2011-03-15 19:54:49 -07:00
Johan Hedberg
52e333ff28 Add attrib server refactoring task to TODO 2011-03-15 22:40:00 +02:00
Johan Hedberg
3c0786fea5 Fix minor coding style issues in attrib server code 2011-03-15 22:36:50 +02:00
Johan Hedberg
c620d295f7 Remove redundant return statements from interactive gatttool 2011-03-15 22:27:00 +02:00
Johan Hedberg
b98c30a065 Fix minor coding style issues in SAP server code 2011-03-15 22:22:52 +02:00
Johan Hedberg
6b6b100783 Add LE whitelist support to the TODO 2011-03-15 21:10:45 +02:00
Johan Hedberg
803db5d475 mgmt: support for local_name_changed event 2011-03-15 20:51:46 +02:00
Johan Hedberg
7abf8c6e4d mgmt: Fix debug log strings 2011-03-15 20:34:08 +02:00
Waldemar Rymarkiewicz
caa8299225 Add Sim Access Profile Server
Add a Sim Access Server to the SAP plugin and a framework for the dummy
sap driver as well.

	* add the server register and unregister rutines
	* add server listening socket setup
	* add SAP DBus API
	* add prototypes for SAP protocol implementation
	* add skeleton of dummy SIM driver
2011-03-15 19:51:01 +02:00
Waldemar Rymarkiewicz
d4542f4268 Adjust sap/server.c license text to the rest of the code 2011-03-15 19:41:11 +02:00
Elvis Pfützenreuter
69f57a7d56 Add "unit test" for new UUID functions 2011-03-15 19:37:40 +02:00
Elvis Pfützenreuter
a278db781a Use new UUID functions in GATT
This patch puts the new UUID functions into use for GATT-related
code, and adds some convenience functions to ATT API (att.h).
Example GATT server is also changed.
2011-03-15 19:36:48 +02:00
Dmitriy Paliy
da620b5e91 Remove unused code due to dial and re-dial change
last_dialed_number and callerid are not used after changing CreateWith
to Create and CreateFromLast csd method calls, and therefore can be
removed.
2011-03-15 19:35:42 +02:00
Dmitriy Paliy
fcd1ac9c72 Change dial and re-dial in maemo6 telephony
Dial and re-dial to last number functions are changed in maemo6
telephony driver accordingly to updated API in csd back-end. CreateWith
method call is replaced by Create and CreateFromLast.

After such modification callerid and last dialed number are not used
and hence removed in sucessive patch.
2011-03-15 19:35:40 +02:00
Dmitriy Paliy
cef5610236 Move telephony_last_dialed_number_req
telephony_last_dialed_number_req function moved to be after
send_method_call. It is used in successive commit.
2011-03-15 19:35:37 +02:00
Johan Hedberg
3011a312a7 mgmt: Implement adapter name control
This patch adds a new set_local_name command as well as a
local_name_changed event to the management interface. Instead of 248
bytes (like in the HCI spec) 249 bytes are always reserved for the name
in the messages so that there's a guarantee of it being nul-terminated
(this is not guaranteed on the HCI level).
2011-03-15 19:32:09 +02:00
Johan Hedberg
1c16543345 mgmt: Add adapter name to read_info response 2011-03-15 19:30:11 +02:00
Szymon Janc
2854ecff1f Make strtoba use str2ba for string conversion 2011-03-15 15:13:52 +02:00
Szymon Janc
1c58c18eaa Fix str2ba behaviour on malformed bt address
str2ba could create bogus bt address from malformed string. Return
all zeros bt address on malformed string.
2011-03-15 15:13:44 +02:00
Szymon Janc
9f14800ff3 Simplify ba2str function 2011-03-15 15:10:36 +02:00
Szymon Janc
e935b65783 Simplify ba2oui function 2011-03-15 15:08:51 +02:00
Vinicius Costa Gomes
020ef16431 Update the test-attrib test script
Now it is more similar to the other test-* scripts. And allows to
exercise more of the API.
2011-03-15 10:53:12 +02:00
Vinicius Costa Gomes
9dd2fb619e Add DiscoverCharacteristics method to the Attribute API 2011-03-15 10:53:07 +02:00
Vinicius Costa Gomes
6cb460ab9c Fix not returning an error when DiscoverCharacteristics() fails
When the connection fails an error should be returned to inform
the user.

This adds a field to store the DBusMessage that caused the error,
so we can send the correct reply.
2011-03-15 10:52:56 +02:00
Vinicius Costa Gomes
17c03b0de4 Fix the behaviour of the DiscoverCharacteristics method
The previous behaviour could lead to some problems, as it returned
as soon as possible. To avoid problems we return just after as the
characteristics are discovered, and to save a few round trips we
return the path of all characteristics that belong to this service.

After this method return it will try to read the characteristics
values.
2011-03-15 10:52:37 +02:00
Vinicius Costa Gomes
2663ca4207 Rename the Discover method to DiscoverCharacteristics 2011-03-15 10:52:23 +02:00
Elvis Pfützenreuter
bb096e674c Add more functions for new UUID handling
This patch adds more functions that are necessary to handle the new
bt_uuid_t type, and moves basic things like byte-swapping functions and
uint128_t type to bluetooth.h.
2011-03-15 10:42:50 +02:00
Claudio Takahasi
3ed993262f Add new UUID utility functions
New UUID functions will store the UUIDs values on host order. Added
functions to create, compare and convert UUIDs.
2011-03-15 10:35:40 +02:00
Lukasz Rymanowski
a709b2119b network: Fix for TP_BNEP_CTRL_BV_01_C qualification test
With this fix network plugin will correctly respond on unknown
BNEP control command.
2011-03-14 17:10:38 +02:00
Johan Hedberg
ea8db48924 Add media-api.txt to EXTRA_DIST 2011-03-14 13:41:16 +02:00
Sheldon Demario
cc2d6b4db8 Add indication/notification support to interactive gatttool 2011-03-11 12:55:54 +02:00
Szymon Janc
c77263675b Fix unloading of adapter drivers
Call driver remove callback only if corresponding probe succeed.
2011-03-10 22:02:56 +02:00
Elvis Pfützenreuter
f22c60eab6 Implement ATT handle indications
This patch takes advantage of g_attrib_send() implicit guarantee of
queueing i.e. indication is only sent if the previous one has been
confirmed, so we don't need to maintain an explicit queue.
2011-03-10 16:30:23 +02:00
Waldemar Rymarkiewicz
e3c94accd0 Add Sim Access Profile Manager
Add a SAP plugin main file and the plugin manager. Also include the SAP
plugin in the Makefile.
2011-03-10 16:03:50 +02:00
Waldemar Rymarkiewicz
2534fbd05a Add Sim Access Profile API
New API for Sim Access Profile.
2011-03-10 16:03:40 +02:00
Claudio Takahasi
a37a95fe6d gatttool: Add Write Without Response option
Sub-procedure used to write a Characteristic Value to a server when
the client knows the Characteristic Value Handle and the client does
not need acknowledgement.
2011-03-10 11:20:33 +02:00
Claudio Takahasi
4fce91f1cf Extend Characteristic Write to support Write Without Response
If callback is not informed, Write Command will be used to execute
a Write Without Response sub-procedure. Error is not returned by the
server no matter the result of the operation.
2011-03-10 11:20:08 +02:00
Marco Sinigaglia
39454251ef Adjust LE command timeout and API
The timeout value has been hardcoded on hci_send_req call and, instead,
it should be passed from above (for ex from hci_le_set_scan_enable).
This patch removes the hardcoded value from hci_send_req and it
increases the timeout to 1000ms.
2011-03-10 11:11:17 +02:00
Bruna Moreira
1f6f8f2c13 Fix MTU value used on MTU exchange response
ATT_MTU_RESP shall send the original MTU value prior to the exchange. If
client sends an invalid value, the server shall use the ATT_DEFAULT_LE_MTU
value. This operation is not supported in BR/EDR, so if any client sends
this request it will be ignored by server and it will reply with
"Request not supported".

For BR/EDR, the MTU is limited to ATT_MAX_MTU (currently 256). This
avoids allocating a big buffer when most ATT PDUs are small.

Note: the kernel currently limits the minimum MTU to 48, regardless of
transport type. This limit is valid only for BR/EDR, for LE the minimum
is 23. This bug will be fixed, but it does not affect the outgoing MTU
for new created LE sockets, which are correctly set to 23.
2011-03-10 11:08:06 +02:00
Bruna Moreira
4a559985cb Use CID to infer transport type
Instead of comparing GIOChannel pointers, use the CID returned by
bt_io_get() to infer the transport type. LE uses the fixed CID for GATT.
2011-03-10 11:07:27 +02:00
Daniel Orstadius
8c0b3c9c8e Increase AVDTP request timeout
At least one headset with both A2DP and PBAP sends delayed responses
to AVDTP requests when it is doing PBAP queries (typically at the
beginning of the connection).

Increasing the timer by two seconds to give the headset more time to
reply, to avoid aborting the AVDTP connection.
2011-03-10 11:06:16 +02:00
Lukasz Rymanowski
b903344d92 pand: Fix for TP_BNEP_CTRL_BV_01_C qualification test
With this fix pand will correctly respond on unknown BNEP control
command.
2011-03-10 11:00:37 +02:00
Grant Erickson
af4519a50c gdbus: Unconditionally remove D-Bus timeouts
Address an issue in which the daemon incorrectly handles D-Bus main
loop timeouts by only removing timeouts that are not enabled when
D-Bus requests a timeout removal.
2011-03-09 13:34:03 -08:00
Claudio Takahasi
dc920afdf5 hcitool: add "whitelist" option to create LE connections
If "whitelist" option is given, the peer address and type will be
ignored and the white list will be used to determine which advertiser
to connect to.
2011-03-04 16:45:50 -03:00
Claudio Takahasi
81a57bd00d hcitool: add random address type to LE Add to White List 2011-03-04 16:45:28 -03:00
Claudio Takahasi
3f6465163d hcitool: use defined constants for address type 2011-03-04 16:45:11 -03:00
Johan Hedberg
328a4501c7 Fix support for shells that do not have "+=" 2011-03-04 16:41:43 -03:00