update readme
This commit is contained in:
@@ -55,15 +55,15 @@ enum bt_mesh_feat_state {
|
||||
#define BT_MESH_NODE_IDENTITY_RUNNING BT_MESH_FEATURE_ENABLED
|
||||
#define BT_MESH_NODE_IDENTITY_NOT_SUPPORTED BT_MESH_FEATURE_NOT_SUPPORTED
|
||||
|
||||
/** @brief Enable or disable sending of the Secure NetworkLock Beacon.
|
||||
/** @brief Enable or disable sending of the Secure Network Beacon.
|
||||
*
|
||||
* @param beacon New Secure NetworkLock Beacon state.
|
||||
* @param beacon New Secure Network Beacon state.
|
||||
*/
|
||||
void bt_mesh_beacon_set(bool beacon);
|
||||
|
||||
/** @brief Get the current Secure NetworkLock Beacon state.
|
||||
/** @brief Get the current Secure Network Beacon state.
|
||||
*
|
||||
* @returns Whether the Secure NetworkLock Beacon feature is enabled.
|
||||
* @returns Whether the Secure Network Beacon feature is enabled.
|
||||
*/
|
||||
bool bt_mesh_beacon_enabled(void);
|
||||
|
||||
@@ -87,24 +87,24 @@ int bt_mesh_default_ttl_set(uint8_t default_ttl);
|
||||
*/
|
||||
uint8_t bt_mesh_default_ttl_get(void);
|
||||
|
||||
/** @brief Set the NetworkLock Transmit parameters.
|
||||
/** @brief Set the Network Transmit parameters.
|
||||
*
|
||||
* The NetworkLock Transmit parameters determine the parameters local messages are
|
||||
* The Network Transmit parameters determine the parameters local messages are
|
||||
* transmitted with.
|
||||
*
|
||||
* @see BT_MESH_TRANSMIT
|
||||
*
|
||||
* @param xmit New NetworkLock Transmit parameters. Use @ref BT_MESH_TRANSMIT for
|
||||
* @param xmit New Network Transmit parameters. Use @ref BT_MESH_TRANSMIT for
|
||||
* encoding.
|
||||
*/
|
||||
void bt_mesh_net_transmit_set(uint8_t xmit);
|
||||
|
||||
/** @brief Get the current NetworkLock Transmit parameters.
|
||||
/** @brief Get the current Network Transmit parameters.
|
||||
*
|
||||
* The @ref BT_MESH_TRANSMIT_COUNT and @ref BT_MESH_TRANSMIT_INT macros can be
|
||||
* used to decode the NetworkLock Transmit parameters.
|
||||
* used to decode the Network Transmit parameters.
|
||||
*
|
||||
* @return The current NetworkLock Transmit parameters.
|
||||
* @return The current Network Transmit parameters.
|
||||
*/
|
||||
uint8_t bt_mesh_net_transmit_get(void);
|
||||
|
||||
@@ -210,10 +210,10 @@ enum bt_mesh_feat_state bt_mesh_friend_get(void);
|
||||
*
|
||||
* Adds a subnet with the given network index and network key to the list of
|
||||
* known Subnets. All messages sent on the given Subnet will be processed by
|
||||
* this node, and the node may send and receive NetworkLock Beacons on the given
|
||||
* this node, and the node may send and receive Network Beacons on the given
|
||||
* Subnet.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param key Root network key of the Subnet. All other keys are derived
|
||||
* from this.
|
||||
*
|
||||
@@ -233,7 +233,7 @@ uint8_t bt_mesh_subnet_add(uint16_t net_idx, const uint8_t key[16]);
|
||||
* keys for the entire network, effectively removing access for all nodes that
|
||||
* aren't given the new keys.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param key New root network key of the Subnet.
|
||||
*
|
||||
* @retval STATUS_SUCCESS The Subnet was updated with a second key.
|
||||
@@ -247,12 +247,12 @@ uint8_t bt_mesh_subnet_update(uint16_t net_idx, const uint8_t key[16]);
|
||||
/** @brief Delete a Subnet.
|
||||
*
|
||||
* Removes the Subnet with the given network index from the node. The node will
|
||||
* stop sending NetworkLock Beacons with the given Subnet, and can no longer
|
||||
* stop sending Network Beacons with the given Subnet, and can no longer
|
||||
* process messages on this Subnet.
|
||||
*
|
||||
* All Applications bound to this Subnet are also deleted.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
*
|
||||
* @retval STATUS_SUCCESS The Subnet was deleted.
|
||||
* @retval STATUS_INVALID_NETKEY The NetIdx is unknown.
|
||||
@@ -261,7 +261,7 @@ uint8_t bt_mesh_subnet_del(uint16_t net_idx);
|
||||
|
||||
/** @brief Check whether a Subnet is known.
|
||||
*
|
||||
* @param net_idx NetworkLock index
|
||||
* @param net_idx Network index
|
||||
*
|
||||
* @return true if a Subnet with the given index exists, false otherwise.
|
||||
*/
|
||||
@@ -277,7 +277,7 @@ bool bt_mesh_subnet_exists(uint16_t net_idx);
|
||||
* removes the old keys from the node, and returns the Subnet back to normal
|
||||
* single-key operation with the new key set.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param phase Pointer to the new Key Refresh phase. Will return the actual
|
||||
* Key Refresh phase after updating.
|
||||
*
|
||||
@@ -290,7 +290,7 @@ uint8_t bt_mesh_subnet_kr_phase_set(uint16_t net_idx, uint8_t *phase);
|
||||
|
||||
/** @brief Get the Subnet's Key Refresh phase.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param phase Pointer to the Key Refresh variable to fill.
|
||||
*
|
||||
* @retval STATUS_SUCCESS Successfully populated the @c phase variable.
|
||||
@@ -311,7 +311,7 @@ uint8_t bt_mesh_subnet_kr_phase_get(uint16_t net_idx, uint8_t *phase);
|
||||
* GATT Proxy support must be enabled through
|
||||
* @option{CONFIG_BT_MESH_GATT_PROXY}.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param node_id New Node Identity state, must be either @ref
|
||||
* BT_MESH_FEATURE_ENABLED or @ref BT_MESH_FEATURE_DISABLED.
|
||||
*
|
||||
@@ -326,7 +326,7 @@ uint8_t bt_mesh_subnet_node_id_set(uint16_t net_idx,
|
||||
|
||||
/** @brief Get the Node Identity state of the Subnet.
|
||||
*
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
* @param node_id Node Identity variable to fill.
|
||||
*
|
||||
* @retval STATUS_SUCCESS Successfully populated the @c node_id variable.
|
||||
@@ -378,7 +378,7 @@ ssize_t bt_mesh_subnets_get(uint16_t net_idxs[], size_t max, off_t skip);
|
||||
* Subnet the Application is bound to before it can add the Application.
|
||||
*
|
||||
* @param app_idx Application index.
|
||||
* @param net_idx NetworkLock index the Application is bound to.
|
||||
* @param net_idx Network index the Application is bound to.
|
||||
* @param key Application key value.
|
||||
*
|
||||
* @retval STATUS_SUCCESS The Application was successfully added.
|
||||
@@ -406,7 +406,7 @@ uint8_t bt_mesh_app_key_add(uint16_t app_idx, uint16_t net_idx,
|
||||
* Refresh phase 1.
|
||||
*
|
||||
* @param app_idx Application index.
|
||||
* @param net_idx NetworkLock index the Application is bound to, or
|
||||
* @param net_idx Network index the Application is bound to, or
|
||||
* @ref BT_MESH_KEY_ANY to skip the binding check.
|
||||
* @param key New key value.
|
||||
*
|
||||
@@ -427,7 +427,7 @@ uint8_t bt_mesh_app_key_update(uint16_t app_idx, uint16_t net_idx,
|
||||
* All models publishing with this application will stop publishing.
|
||||
*
|
||||
* @param app_idx Application index.
|
||||
* @param net_idx NetworkLock index.
|
||||
* @param net_idx Network index.
|
||||
*
|
||||
* @retval STATUS_SUCCESS The Application key was successfully deleted.
|
||||
* @retval STATUS_INVALID_NETKEY The NetIdx is unknown.
|
||||
@@ -457,7 +457,7 @@ bool bt_mesh_app_key_exists(uint16_t app_idx);
|
||||
* Note that any changes to the Application key list between calls to this
|
||||
* function could change the order and number of entries in the list.
|
||||
*
|
||||
* @param net_idx NetworkLock Index to get the Applications of, or @ref
|
||||
* @param net_idx Network Index to get the Applications of, or @ref
|
||||
* BT_MESH_KEY_ANY to get all Applications.
|
||||
* @param app_idxs Array to fill.
|
||||
* @param max Max number of indexes to return.
|
||||
|
||||
@@ -36,7 +36,7 @@ struct bt_mesh_hb_pub {
|
||||
* @ref BT_MESH_FEAT_LOW_POWER.
|
||||
*/
|
||||
uint16_t feat;
|
||||
/** NetworkLock index used for publishing. */
|
||||
/** Network index used for publishing. */
|
||||
uint16_t net_idx;
|
||||
/** Publication period in seconds. */
|
||||
uint32_t period;
|
||||
|
||||
@@ -382,7 +382,7 @@ int bt_mesh_prov_disable(bt_mesh_prov_bearer_t bearers);
|
||||
* @{
|
||||
*/
|
||||
|
||||
/* Primary NetworkLock Key index */
|
||||
/* Primary Network Key index */
|
||||
#define BT_MESH_NET_PRIMARY 0x000
|
||||
|
||||
/* Features */
|
||||
@@ -450,8 +450,8 @@ int bt_mesh_resume(void);
|
||||
* only exception is for testing purposes where manual provisioning is
|
||||
* desired without an actual external provisioner.
|
||||
*
|
||||
* @param net_key NetworkLock Key
|
||||
* @param net_idx NetworkLock Key Index
|
||||
* @param net_key Network Key
|
||||
* @param net_idx Network Key Index
|
||||
* @param flags Provisioning Flags
|
||||
* @param iv_index IV Index
|
||||
* @param addr Primary element address
|
||||
@@ -466,7 +466,7 @@ int bt_mesh_provision(const uint8_t net_key[16], uint16_t net_idx,
|
||||
/** @brief Provision a Mesh Node using PB-ADV
|
||||
*
|
||||
* @param uuid UUID
|
||||
* @param net_idx NetworkLock Key Index
|
||||
* @param net_idx Network Key Index
|
||||
* @param addr Address to assign to remote device. If addr is 0, the lowest
|
||||
* available address will be chosen.
|
||||
* @param attention_duration The attention duration to be send to remote device
|
||||
|
||||
@@ -69,7 +69,7 @@ void bt_mesh_beacon_create(struct bt_mesh_subnet *sub,
|
||||
|
||||
net_buf_simple_add_u8(buf, flags);
|
||||
|
||||
/* NetworkLock ID */
|
||||
/* Network ID */
|
||||
net_buf_simple_add_mem(buf, keys->net_id, 8);
|
||||
|
||||
/* IV Index */
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
#include "../include/mesh/glue.h"
|
||||
#include "../include/mesh/slist.h"
|
||||
|
||||
/* Minimum valid Mesh NetworkLock PDU length. The NetworkLock headers
|
||||
/* Minimum valid Mesh Network PDU length. The Network headers
|
||||
* themselves take up 9 bytes. After that there is a minumum of 1 byte
|
||||
* payload for both CTL=1 and CTL=0 PDUs (smallest OpCode is 1 byte). CTL=1
|
||||
* PDUs must use a 64-bit (8 byte) NetMIC, whereas CTL=0 PDUs have at least
|
||||
@@ -575,7 +575,7 @@ static bool net_decrypt(struct bt_mesh_net_rx *rx, struct os_mbuf *in,
|
||||
}
|
||||
|
||||
if (rx->net_if == BT_MESH_NET_IF_ADV && msg_cache_match(out)) {
|
||||
BT_DBG("Duplicate found in NetworkLock Message Cache");
|
||||
BT_DBG("Duplicate found in Network Message Cache");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -624,7 +624,7 @@ static void bt_mesh_net_relay(struct os_mbuf *sbuf,
|
||||
|
||||
/* The Relay Retransmit state is only applied to adv-adv relaying.
|
||||
* Anything else (like GATT to adv, or locally originated packets)
|
||||
* use the NetworkLock Transmit state.
|
||||
* use the Network Transmit state.
|
||||
*/
|
||||
if (rx->net_if == BT_MESH_NET_IF_ADV && !rx->friend_cred) {
|
||||
transmit = bt_mesh_relay_retransmit_get();
|
||||
@@ -668,7 +668,7 @@ static void bt_mesh_net_relay(struct os_mbuf *sbuf,
|
||||
|
||||
/* When the Friend node relays message for lpn, the message will be
|
||||
* retransmitted using the managed master security credentials and
|
||||
* the NetworkLock PDU shall be retransmitted to all network interfaces.
|
||||
* the Network PDU shall be retransmitted to all network interfaces.
|
||||
*/
|
||||
if (IS_ENABLED(CONFIG_BT_MESH_GATT_PROXY) &&
|
||||
(rx->friend_cred ||
|
||||
@@ -796,7 +796,7 @@ void bt_mesh_net_recv(struct os_mbuf *data, int8_t rssi,
|
||||
* it again in the future.
|
||||
*/
|
||||
if (bt_mesh_trans_recv(buf, &rx) == -EAGAIN) {
|
||||
BT_WARN("Removing rejected message from NetworkLock Message Cache");
|
||||
BT_WARN("Removing rejected message from NetworkMessage Cache");
|
||||
msg_cache[rx.msg_cache_idx].src = BT_MESH_ADDR_UNASSIGNED;
|
||||
/* Rewind the next index now that we're not using this entry */
|
||||
msg_cache_next = rx.msg_cache_idx;
|
||||
|
||||
@@ -165,7 +165,7 @@ struct bt_mesh_lpn {
|
||||
/* bt_mesh_net.flags */
|
||||
enum {
|
||||
BT_MESH_VALID, /* We have been provisioned */
|
||||
BT_MESH_SUSPENDED, /* NetworkLock is temporarily suspended */
|
||||
BT_MESH_SUSPENDED, /* Network is temporarily suspended */
|
||||
BT_MESH_IVU_IN_PROGRESS, /* IV Update in Progress */
|
||||
BT_MESH_IVU_INITIATOR, /* IV Update initiated by us */
|
||||
BT_MESH_IVU_TEST, /* IV Update test mode */
|
||||
@@ -224,7 +224,7 @@ struct bt_mesh_net {
|
||||
uint8_t dev_key[16];
|
||||
};
|
||||
|
||||
/* NetworkLock interface */
|
||||
/* Network interface */
|
||||
enum bt_mesh_net_if {
|
||||
BT_MESH_NET_IF_ADV,
|
||||
BT_MESH_NET_IF_LOCAL,
|
||||
@@ -232,7 +232,7 @@ enum bt_mesh_net_if {
|
||||
BT_MESH_NET_IF_PROXY_CFG,
|
||||
};
|
||||
|
||||
/* Decoding context for NetworkLock/Transport data */
|
||||
/* Decoding context for Network/Transport data */
|
||||
struct bt_mesh_net_rx {
|
||||
struct bt_mesh_subnet *sub;
|
||||
struct bt_mesh_msg_ctx ctx;
|
||||
@@ -240,14 +240,14 @@ struct bt_mesh_net_rx {
|
||||
uint8_t old_iv:1, /* iv_index - 1 was used */
|
||||
new_key:1, /* Data was encrypted with updated key */
|
||||
friend_cred:1, /* Data was encrypted with friend cred */
|
||||
ctl:1, /* NetworkLock Control */
|
||||
net_if:2, /* NetworkLock interface */
|
||||
ctl:1, /* Network Control */
|
||||
net_if:2, /* Network interface */
|
||||
local_match:1, /* Matched a local element */
|
||||
friend_match:1; /* Matched an LPN we're friends for */
|
||||
uint16_t msg_cache_idx; /* Index of entry in message cache */
|
||||
};
|
||||
|
||||
/* Encoding context for NetworkLock/Transport data */
|
||||
/* Encoding context for Network/Transport data */
|
||||
struct bt_mesh_net_tx {
|
||||
struct bt_mesh_subnet *sub;
|
||||
struct bt_mesh_msg_ctx *ctx;
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
#include "mesh/glue.h"
|
||||
#include "mesh/testing.h"
|
||||
|
||||
/* Private includes for raw NetworkLock & Transport layer access */
|
||||
/* Private includes for raw Network & Transport layer access */
|
||||
#include "net.h"
|
||||
#include "rpl.h"
|
||||
#include "access.h"
|
||||
@@ -2863,7 +2863,7 @@ static int cmd_cdb_show(int argc, char *argv[])
|
||||
return 0;
|
||||
}
|
||||
|
||||
printk("Mesh NetworkLock Information");
|
||||
printk("Mesh Network Information");
|
||||
printk("========================");
|
||||
|
||||
cdb_print_nodes();
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
struct bt_mesh_net_rx;
|
||||
enum bt_mesh_key_evt;
|
||||
|
||||
/** NetworkLock message encryption credentials */
|
||||
/** Network message encryption credentials */
|
||||
struct bt_mesh_net_cred {
|
||||
uint8_t nid; /* NID */
|
||||
uint8_t enc[16]; /* EncKey */
|
||||
@@ -56,7 +56,7 @@ struct bt_mesh_subnet {
|
||||
bool valid;
|
||||
uint8_t net[16]; /* NetKey */
|
||||
struct bt_mesh_net_cred msg;
|
||||
uint8_t net_id[8]; /* NetworkLock ID */
|
||||
uint8_t net_id[8]; /* Network ID */
|
||||
#if defined(CONFIG_BT_MESH_GATT_PROXY)
|
||||
uint8_t identity[16]; /* IdentityKey */
|
||||
#endif
|
||||
@@ -78,7 +78,7 @@ struct bt_mesh_subnet_cb {
|
||||
enum bt_mesh_key_evt evt);
|
||||
};
|
||||
|
||||
/** @brief Reset all NetworkLock keys. */
|
||||
/** @brief Reset all Network keys. */
|
||||
void bt_mesh_net_keys_reset(void);
|
||||
|
||||
/** @brief Call cb on every valid Subnet until it returns a non-zero value.
|
||||
@@ -113,7 +113,7 @@ struct bt_mesh_subnet *bt_mesh_subnet_next(struct bt_mesh_subnet *sub);
|
||||
|
||||
/** @brief Get a pointer to the Subnet with the given index.
|
||||
*
|
||||
* @param net_idx NetworkLock index to look for.
|
||||
* @param net_idx Network index to look for.
|
||||
*
|
||||
* @returns Subnet with index @c net_idx, or NULL if no such Subnet is known.
|
||||
*/
|
||||
@@ -121,7 +121,7 @@ struct bt_mesh_subnet *bt_mesh_subnet_get(uint16_t net_idx);
|
||||
|
||||
/** @brief Initialize a new Subnet.
|
||||
*
|
||||
* @param net_idx NetworkLock index of the Subnet.
|
||||
* @param net_idx Network index of the Subnet.
|
||||
* @param kr_phase Key refresh phase the Subnet should be in.
|
||||
* @param key The current network key for the Subnet.
|
||||
* @param new_key New network key, if available.
|
||||
@@ -138,7 +138,7 @@ int bt_mesh_subnet_set(uint16_t net_idx, uint8_t kr_phase,
|
||||
* @param frnd_addr Address of the Friend node in the friendship.
|
||||
* @param lpn_counter The LPN's counter parameter.
|
||||
* @param frnd_counter The Friend node's counter parameter.
|
||||
* @param key NetworkLock key to create the Friendship credentials for.
|
||||
* @param key Network key to create the Friendship credentials for.
|
||||
*
|
||||
* @returns 0 on success, or (negative) error code on failure.
|
||||
*/
|
||||
@@ -149,7 +149,7 @@ int bt_mesh_friend_cred_create(struct bt_mesh_net_cred *cred,
|
||||
|
||||
/** @brief Iterate through all valid network credentials to decrypt a message.
|
||||
*
|
||||
* @param rx NetworkLock RX parameters, passed to the callback.
|
||||
* @param rx Network RX parameters, passed to the callback.
|
||||
* @param in Input message buffer, passed to the callback.
|
||||
* @param out Output message buffer, passed to the callback.
|
||||
* @param cb Callback to call for each known network credential. Iteration
|
||||
|
||||
Reference in New Issue
Block a user