mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-03-01 10:13:29 +00:00
mesh: set primary element address in lower transport
This commit is contained in:
parent
2e3a410f6f
commit
553e128c6f
@ -690,6 +690,10 @@ void mesh_lower_transport_init(){
|
||||
mesh_network_set_higher_layer_handler(&mesh_lower_transport_received_message);
|
||||
}
|
||||
|
||||
void mesh_lower_transport_set_primary_element_address(uint16_t unicast_address){
|
||||
primary_element_address = unicast_address;
|
||||
}
|
||||
|
||||
void mesh_lower_transport_set_higher_layer_handler(void (*pdu_handler)( mesh_pdu_t * pdu)){
|
||||
higher_layer_handler = pdu_handler;
|
||||
}
|
||||
|
@ -69,6 +69,7 @@ void mesh_transport_set_dest(mesh_transport_pdu_t * transport_pdu, uint16_t dest
|
||||
|
||||
|
||||
void mesh_lower_transport_init();
|
||||
void mesh_upper_transport_set_primary_element_address(uint16_t unicast_address);
|
||||
void mesh_lower_transport_set_higher_layer_handler(void (*pdu_handler)( mesh_pdu_t * pdu));
|
||||
|
||||
void mesh_lower_transport_set_seq(uint32_t seq);
|
||||
|
@ -50,7 +50,7 @@
|
||||
|
||||
// configuration
|
||||
#define MESH_NETWORK_CACHE_SIZE 2
|
||||
#define ENABLE_MESH_RELAY
|
||||
// #define ENABLE_MESH_RELAY
|
||||
|
||||
// debug config
|
||||
// #define LOG_NETWORK
|
||||
|
@ -103,6 +103,7 @@ static void mesh_setup_from_provisioning_data(const mesh_provisioning_data_t * p
|
||||
mesh_network_key_list_add_from_provisioning_data(provisioning_data);
|
||||
// set unicast address
|
||||
mesh_network_set_primary_element_address(provisioning_data->unicast_address);
|
||||
mesh_lower_transport_set_primary_element_address(provisioning_data->unicast_address);
|
||||
mesh_upper_transport_set_primary_element_address(provisioning_data->unicast_address);
|
||||
primary_element_address = provisioning_data->unicast_address;
|
||||
// set iv_index
|
||||
|
Loading…
x
Reference in New Issue
Block a user