Remove cmd_ull_reset command, as this would put the host out
of sync. Also, this command is seldom used/required.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Added a feature that allows an application to request
automatic discovery of the CCCD handle when subscriping
to a characteristic. In order to preserver RAM, the application
is expected to provide the discovery parameters, and it's up
to the application whether or not it wants to reuse the
discovery parameters or use one for each characteristic.
Signed-off-by: Emil Gydesen <emil_gydesen@bose.com>
Add advertising option for undirected one-time advertising, and
directed advertising using identity, and peer direct is RPA option.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
The hci-cmd currently accepts only a 1 byte parameter. This
disables use of commands that requires more than 1 byte,
for ex. the feature exchange that requires a 16 bit parameter.
This commit allows a datafield parameter up to 65 bytes long.
65 bytes comes from the nr. of parameters for the
HCI_LE_Generate_DHKey command
Signed-off-by: Andries Kruithof <Andries.Kruithof@nordicsemi.no>
Updated the shell commands related to Advertising Extensions
to call the LE Set Extended Advertising Data command
functional interface for testing purposes.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
After removal of legacy controller ll_adv_aux.h does not exist anymore.
This is fixed in this PR by including ull_adv_aux.h instead.
The error only shows up when Advertisement Extensions are enabled
in the LL (CONFIG_BT_CTLR_ADV_EXT=y)
Signed-off-by: Andries Kruithof <Andries.Kruithof@nordicsemi.no>
Add control over the use name option to advertise shell parameters as
an optional argument.
The argument count for extended advertise parameters had not been
updated for the maximum directed advertise parameter count.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Remove the BT_LE_CONN_OPT_2M option and update documentation.
This was a misunderstand about the init PHY HCI parameter.
The init PHY in the extended connection create command does not
determine which PHYs are accepted as the initial PHY of the
connection. This is instead determined by the secondary PHY of the
extended advertiser.
The init PHY parameter only specifies which conn parameters are
provided, and since we only provide one conn parameter this option
has no effect.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
After #22013, bt_le_adv_param got additional fields which were passed to
the bluetooth API uninitialized in the BT Mesh module. This
zero-initializes the entire structure in all usages to avoid passing
uninitialized data now and in the future.
Signed-off-by: Trond Einar Snekvik <Trond.Einar.Snekvik@nordicsemi.no>
Add support for multiple advertising set. Move the advertising state
flags to be per advertising set and loop over advertising sets instead
of looking up legacy advertiser set or handle 0.
Since it is not certain that the advertising set terminated event can
arrive directly after the connection complete event there is currently
a limitation that there can only be one local identity used by
connectable advertisers at a time. This guarantees that we know
the local identity being used in the connection complete event.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Give NULL pointer when ad_len or sd_len is zero, this stops the host
from setting a zero length advertise data or scan response.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Fix the advertise command not setting the peer address parameter to
NULL, this could turn it into a directed advertiser.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add shell options to configure an extended advertiser for directed
advertising.
Add shell options to provide arbitrary advertising data as well as
giving scan response data.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
This patch introduces two major changes to the directed advertising
feature of the bluetooth host.
Deprecating the bt_conn_create_slave_le, and removing
bt_conn_le_create_slave which has never been released. This behaviour
has now been moved by to providing the peer direct address into the
advertising parameters.
Introducing directed advertising support for nonconnectable
directed extended advertising, both scannable and non-scannable.
A bug was also fixed in the the directed-adv command in the shell
when the argument "low" was given. The advertiseng parameter pointer
declared with BT_LE_ADV_CONN_DIR_LOW_DUTY was declared in a scope that
was no longer valid when it was used to start the advertiser.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add shell advertise set info get command to print advertiser set local
identity and TX power selected by the controller.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add shell command to retrieve advertising set OOB information for the
selected advertising set.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add error code to API for starting directed advertiser. Also rename the
API in order to follow the established naming pattern.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add advertising sent connected and scanned callback and print the
information available.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add shell arguments to control scanning phys for scanner and initiator.
This allows to scan on coded or create connections on coded.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add scan recv callback and print extended scan information available.
Add scan timeout callback to print when scanner has stopped.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Print the error codes in hex so that it is easier to lookup, error
codes are usually given as hex.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Use the scan types defined in bluetooth.h instead of the hci defined
ones. Although they have the same value it is best to avoid using the
hci.h header in applications.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Rename filter_dup parameters used for scanning filter options to the
more generic name options, and make scan filter options follow same
naming patters as advertising and initiator scan options.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Deprecate bt_create_conn_le and rename it to in order to add return
code, new arguments and to follow the established naming convention.
Add API for the application to control the scan parameters of the
initiator role. This allows the application more scheduling control
of the initiator in multi-role scenarios. Also provides options to
configure the initiator for LE Coded PHY for long range support.
We deprecate the old way of creating connection to make the name more
consistent with the rest of the API.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add command to input the legacy pairing OOB TK during the pairing
procedure.
Fixed shell build with CONFIG_BT_SMP_OOB_LEGACY_PAIR_ONLY defined.
Print error code when passkey input failed.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
When building the tests/bluetooth/shell application without
the BT_CENTRAL feature, compilation fails:
subsys/bluetooth/shell/bt.c:1642: undefined reference to
`bt_conn_create_auto_le'
Signed-off-by: Vinayak Kariappa Chettimada <vinayak.kariappa@gmail.com>
Update help text of `bt init` command which says address could be
provided. This feature was removed by:
d22b7c9f2d
As a replacement the `bt id-create` command can be used instead.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Add pairing support callback to print remote pairing features when this
option is enabled.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
Fixes some selects with unsatisfied dependencies. FLASH_SHELL depends on
FLASH_PAGE_LAYOUT, but only FLASH_SHELL is selected. The select was
introduced in commit 3aa2a1c6db ("flash: make flash shell generic").
Spoke to Johan Hedberg. The BT_SHELL code does not depend on
FLASH_SHELL. He didn't think people would assume that BT_SHELL by itself
enables the FLASH_SHELL commands either.
Just remove the select.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Add shell command for advertise with identity option to have the
possibility to temporarily disable privacy feature in the advertise from
the shell.
Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>