zephyr/samples/bluetooth/mesh_provisioner
Kumar Gala a1b77fd589 zephyr: replace zephyr integer types with C99 types
git grep -l 'u\(8\|16\|32\|64\)_t' | \
		xargs sed -i "s/u\(8\|16\|32\|64\)_t/uint\1_t/g"
	git grep -l 's\(8\|16\|32\|64\)_t' | \
		xargs sed -i "s/s\(8\|16\|32\|64\)_t/int\1_t/g"

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2020-06-08 08:23:57 -05:00
..
src zephyr: replace zephyr integer types with C99 types 2020-06-08 08:23:57 -05:00
CMakeLists.txt samples: make find_package(Zephyr...) REQUIRED 2020-05-29 10:47:25 +02:00
prj.conf Bluetooth: samples: Add mesh_provisioner sample 2020-02-05 18:47:41 +02:00
README.rst Bluetooth: samples: Add mesh_provisioner sample 2020-02-05 18:47:41 +02:00
sample.yaml Bluetooth: samples: Add mesh_provisioner sample 2020-02-05 18:47:41 +02:00

.. _ble_mesh_provisioner:

Bluetooth: Mesh Provisioner
###########################

Overview
********

This sample demonstrates how to use the Bluetooth Mesh APIs related to
provisioning and using the Configuration Database (CDB). It is intended to be
tested together with a device that support the Health Server model. For
example, one could use the sample in :zephyr_file:`tests/bluetooth/mesh_shell`.

The application provisions itself and loads the CDB with an application key.
It then waits to receive an Unprovisioned Beacon from a device which will
trigger provisioning using PB-ADV. Once provisioning is done, the node will
be present in the CDB but not yet marked as configured. The application will
notice the unconfigured node and start configuring it. If no errors are
encountered, the node is marked as configured.

The configuration of a node involves adding an application key, binding the
Health Server model to that application key and then configuring the model to
publish Health Status every 10 seconds.

Please note that this sample uses the CDB API which is currently marked as
EXPERIMENTAL and is likely to change.

Requirements
************

* A board with Bluetooth LE support, or
* QEMU with BlueZ running on the host

Building and Running
********************

This sample can be found under :zephyr_file:`samples/bluetooth/mesh_provisioner`
in the Zephyr tree.

See :ref:`bluetooth samples section <bluetooth-samples>` for details on how
to run the sample inside QEMU.

For other boards, build and flash the application as follows:

.. zephyr-app-commands::
   :zephyr-app: samples/bluetooth/mesh_provisioner
   :board: <board>
   :goals: flash
   :compact:

Refer to your :ref:`board's documentation <boards>` for alternative
flash instructions if your board doesn't support the ``flash`` target.