Bluetooth Mesh Runtime Configuration API.
More...
Bluetooth Mesh Runtime Configuration API.
◆ bt_mesh_feat_state
Bluetooth Mesh Feature states
Enumerator |
---|
BT_MESH_FEATURE_DISABLED | Feature is supported, but disabled.
|
BT_MESH_FEATURE_ENABLED | Feature is supported and enabled.
|
BT_MESH_FEATURE_NOT_SUPPORTED | Feature is not supported, and cannot be enabled.
|
◆ bt_mesh_beacon_enabled()
bool bt_mesh_beacon_enabled |
( |
void |
| ) |
|
Get the current Secure Network Beacon state.
- Returns
- Whether the Secure Network Beacon feature is enabled.
◆ bt_mesh_beacon_set()
void bt_mesh_beacon_set |
( |
bool |
beacon | ) |
|
Enable or disable sending of the Secure Network Beacon.
- Parameters
-
beacon | New Secure Network Beacon state. |
◆ bt_mesh_default_ttl_get()
uint8_t bt_mesh_default_ttl_get |
( |
void |
| ) |
|
Get the current default TTL value.
- Returns
- The current default TTL value.
◆ bt_mesh_default_ttl_set()
int bt_mesh_default_ttl_set |
( |
uint8_t |
default_ttl | ) |
|
Set the default TTL value.
The default TTL value is used when no explicit TTL value is set. Models will use the default TTL value when bt_mesh_msg_ctx::send_ttl is BT_MESH_TTL_DEFAULT.
- Parameters
-
default_ttl | The new default TTL value. Valid values are 0x00 and 0x02 to BT_MESH_TTL_MAX. |
- Return values
-
0 | Successfully set the default TTL value. |
-EINVAL | Invalid TTL value. |
◆ bt_mesh_friend_get()
Get the current Friend state.
- Returns
- The Friend feature state.
◆ bt_mesh_friend_set()
Enable or disable the Friend feature.
Any active friendships will be terminated immediately if the Friend feature is disabled.
Support for the Friend feature must be enabled through the CONFIG_BT_MESH_FRIEND
configuration option.
- Parameters
-
- Return values
-
0 | Successfully changed the Friend feature state. |
-ENOTSUP | The Friend feature is not supported. |
-EINVAL | Invalid parameter. |
-EALREADY | Already in the given state. |
◆ bt_mesh_gatt_proxy_get()
Get the current GATT Proxy state.
- Returns
- The GATT Proxy feature state.
◆ bt_mesh_gatt_proxy_set()
Enable or disable the GATT Proxy feature.
Support for the GATT Proxy feature must be enabled through the CONFIG_BT_MESH_GATT_PROXY
configuration option.
- Note
- The GATT Proxy feature only controls a Proxy node's ability to relay messages to the mesh network. A node that supports GATT Proxy will still advertise Connectable Proxy beacons, even if the feature is disabled. The Proxy feature can only be fully disabled through compile time configuration.
- Parameters
-
- Return values
-
0 | Successfully changed the GATT Proxy feature state. |
-ENOTSUP | The GATT Proxy feature is not supported. |
-EINVAL | Invalid parameter. |
-EALREADY | Already in the given state. |
◆ bt_mesh_net_transmit_get()
uint8_t bt_mesh_net_transmit_get |
( |
void |
| ) |
|
◆ bt_mesh_net_transmit_set()
void bt_mesh_net_transmit_set |
( |
uint8_t |
xmit | ) |
|
Set the Network Transmit parameters.
The Network Transmit parameters determine the parameters local messages are transmitted with.
- See also
- BT_MESH_TRANSMIT
- Parameters
-
◆ bt_mesh_relay_get()
Get the current Relay feature state.
- Returns
- The Relay feature state.
◆ bt_mesh_relay_retransmit_get()
uint8_t bt_mesh_relay_retransmit_get |
( |
void |
| ) |
|
Get the current Relay Retransmit parameters.
The BT_MESH_TRANSMIT_COUNT and BT_MESH_TRANSMIT_INT macros can be used to decode the Relay Retransmit parameters.
- Returns
- The current Relay Retransmit parameters, or 0 if relay is not supported.
◆ bt_mesh_relay_set()
Configure the Relay feature.
Enable or disable the Relay feature, and configure the parameters to transmit relayed messages with.
Support for the Relay feature must be enabled through the CONFIG_BT_MESH_RELAY
configuration option.
- See also
- BT_MESH_TRANSMIT
- Parameters
-
- Return values
-
0 | Successfully changed the Relay configuration. |
-ENOTSUP | The Relay feature is not supported. |
-EINVAL | Invalid parameter. |
-EALREADY | Already using the given parameters. |