Exported Functions

group Mesh_Beacon_Exported_Functions

Functions

void beacon_uri_hash_gen(uint8_t uri_data[], uint16_t len)

Generate URI hash for beacons.

Computes and stores a hash of the URI data provided for use in beacon communications.

Parameters:
  • uri_data[in] Pointer to URI data.

  • len[in] Length of URI data.

void beacon_uri_hash_calc(uint8_t uri_data[], uint16_t len, uint8_t uri_hash[4])

Calculate URI hash for mesh operations.

Processes the provided URI to generate a fixed-length hash used in beacon identifiers.

Parameters:
  • uri_data[in] Pointer to URI data.

  • len[in] Length of URI data.

  • uri_hash[out] Calculated URI hash value.

void beacon_snb_send_via_proxy(uint8_t net_key_index)

Send Secure Network Beacon via proxy.

Transmits a Secure Network Beacon message using the specified network key index via the proxy.

Parameters:

net_key_index[in] Network key index for the beacon.

void beacon_send(void)

Send beacon message.

Initiates the transmission of a beacon message with current configurations.

void beacon_start(void)

Start beacon operations.

Enables and begins beacon messaging using current settings.

void beacon_stop(void)

Stop beacon operations.

Disables beacon messaging and halts all associated activities.

void beacon_send_via_proxy(uint8_t net_key_index)

Send beacon over GATT bearer.

Transmits either a Secure Network Beacon or Private Beacon using the specified network key index.

Parameters:

net_key_index[in] Network key index for beacon transmission.

void beacon_receive(uint8_t bt_addr[6], uint8_t bt_addr_type, int8_t rssi, uint8_t *pbuffer, uint8_t len)

Receive beacon message.

Processes an incoming beacon message based on Bluetooth attributes and signal strength.

Parameters:
  • bt_addr[in] Address of the Bluetooth device sending the beacon.

  • bt_addr_type[in] Type of Bluetooth address.

  • rssi[in] Signal strength indicator.

  • pbuffer[in] Pointer to the buffer containing the beacon message.

  • len[in] Length of the beacon message.

bool beacon_cfg(beacon_cfg_type_t type, uint8_t *param, uint16_t param_len)

Configure the mesh service advertisement.

Adjusts configurations and parameters related to mesh beacon advertising based on type and given parameters.

Parameters:
  • type[in] Configuration type, see beacon_cfg_type_t for options.

  • param[in] Pointer to the parameter data.

  • param_len[in] Length of the parameter data.

Return values:
  • true – Configuration successful.

  • false – Configuration failed due to validation errors or unsupported parameter types.

Returns:

Operation result.