mirror of
https://github.com/espressif/esp-idf
synced 2025-03-31 03:41:07 -04:00
ble_mesh: example: Fix fast provisioning compile error
This commit is contained in:
parent
7f1a0e1552
commit
5fd4d53922
@ -33,8 +33,10 @@
|
|||||||
static struct k_delayed_work get_all_node_addr_timer;
|
static struct k_delayed_work get_all_node_addr_timer;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !defined(CONFIG_BLE_MESH_FAST_PROV)
|
||||||
/* Unicast address of the Primary Provisioner */
|
/* Unicast address of the Primary Provisioner */
|
||||||
static uint16_t prim_prov_addr;
|
static uint16_t prim_prov_addr;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Note: these variables are used by ble_mesh_fast_prov_server demo */
|
/* Note: these variables are used by ble_mesh_fast_prov_server demo */
|
||||||
|
|
||||||
@ -370,6 +372,7 @@ esp_err_t example_fast_prov_client_recv_status(esp_ble_mesh_model_t *model,
|
|||||||
}
|
}
|
||||||
case ESP_BLE_MESH_VND_MODEL_OP_FAST_PROV_NODE_ADDR_STATUS: {
|
case ESP_BLE_MESH_VND_MODEL_OP_FAST_PROV_NODE_ADDR_STATUS: {
|
||||||
ESP_LOG_BUFFER_HEX("Node address", data, len);
|
ESP_LOG_BUFFER_HEX("Node address", data, len);
|
||||||
|
#if CONFIG_BLE_MESH_GENERIC_ONOFF_CLI
|
||||||
esp_ble_mesh_model_t *cli_model = NULL;
|
esp_ble_mesh_model_t *cli_model = NULL;
|
||||||
example_node_info_t *node = NULL;
|
example_node_info_t *node = NULL;
|
||||||
esp_err_t err;
|
esp_err_t err;
|
||||||
@ -396,6 +399,7 @@ esp_err_t example_fast_prov_client_recv_status(esp_ble_mesh_model_t *model,
|
|||||||
ESP_LOGE(TAG, "%s: Failed to send Generic OnOff Set Unack message", __func__);
|
ESP_LOGE(TAG, "%s: Failed to send Generic OnOff Set Unack message", __func__);
|
||||||
return ESP_FAIL;
|
return ESP_FAIL;
|
||||||
}
|
}
|
||||||
|
#endif /* CONFIG_BLE_MESH_GENERIC_ONOFF_CLI */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
|
@ -387,6 +387,7 @@ esp_err_t example_send_generic_onoff_get(esp_ble_mesh_model_t *model,
|
|||||||
return esp_ble_mesh_generic_client_get_state(&common, &get);
|
return esp_ble_mesh_generic_client_get_state(&common, &get);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if CONFIG_BLE_MESH_GENERIC_ONOFF_CLI
|
||||||
esp_err_t example_send_generic_onoff_set(esp_ble_mesh_model_t *model,
|
esp_err_t example_send_generic_onoff_set(esp_ble_mesh_model_t *model,
|
||||||
example_msg_common_info_t *info,
|
example_msg_common_info_t *info,
|
||||||
uint8_t onoff, uint8_t tid, bool need_ack)
|
uint8_t onoff, uint8_t tid, bool need_ack)
|
||||||
@ -418,6 +419,7 @@ esp_err_t example_send_generic_onoff_set(esp_ble_mesh_model_t *model,
|
|||||||
|
|
||||||
return esp_ble_mesh_generic_client_set_state(&common, &set);
|
return esp_ble_mesh_generic_client_set_state(&common, &set);
|
||||||
}
|
}
|
||||||
|
#endif /* CONFIG_BLE_MESH_GENERIC_ONOFF_CLI */
|
||||||
|
|
||||||
esp_err_t example_send_fast_prov_info_set(esp_ble_mesh_model_t *model,
|
esp_err_t example_send_fast_prov_info_set(esp_ble_mesh_model_t *model,
|
||||||
example_msg_common_info_t *info,
|
example_msg_common_info_t *info,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user