mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-01 03:34:32 +02:00
wifi_provisioning: fix build warnings due to incorrect event handler argument type
This commit is contained in:
@@ -268,7 +268,7 @@ static cJSON* wifi_prov_get_info_json(void)
|
|||||||
|
|
||||||
/* Declare the internal event handler */
|
/* Declare the internal event handler */
|
||||||
static void wifi_prov_mgr_event_handler_internal(void* arg, esp_event_base_t event_base,
|
static void wifi_prov_mgr_event_handler_internal(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data);
|
int32_t event_id, void* event_data);
|
||||||
|
|
||||||
static esp_err_t wifi_prov_mgr_start_service(const char *service_name, const char *service_key)
|
static esp_err_t wifi_prov_mgr_start_service(const char *service_name, const char *service_key)
|
||||||
{
|
{
|
||||||
@@ -801,7 +801,7 @@ esp_err_t wifi_prov_mgr_event_handler(void *ctx, system_event_t *event)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void wifi_prov_mgr_event_handler_internal(
|
static void wifi_prov_mgr_event_handler_internal(
|
||||||
void* arg, esp_event_base_t event_base, int event_id, void* event_data)
|
void* arg, esp_event_base_t event_base, int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
if (!prov_ctx_lock) {
|
if (!prov_ctx_lock) {
|
||||||
ESP_LOGE(TAG, "Provisioning manager not initialized");
|
ESP_LOGE(TAG, "Provisioning manager not initialized");
|
||||||
|
@@ -28,7 +28,7 @@ static const char *TAG = "app";
|
|||||||
static void start_ble_provisioning(void);
|
static void start_ble_provisioning(void);
|
||||||
|
|
||||||
static void event_handler(void* arg, esp_event_base_t event_base,
|
static void event_handler(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
static int s_retry_num_ap_not_found = 0;
|
static int s_retry_num_ap_not_found = 0;
|
||||||
static int s_retry_num_ap_auth_fail = 0;
|
static int s_retry_num_ap_auth_fail = 0;
|
||||||
|
@@ -15,6 +15,7 @@
|
|||||||
#include <nvs.h>
|
#include <nvs.h>
|
||||||
#include <esp_bt.h>
|
#include <esp_bt.h>
|
||||||
#include <esp_event.h>
|
#include <esp_event.h>
|
||||||
|
#include <esp_timer.h>
|
||||||
|
|
||||||
#ifdef CONFIG_BT_NIMBLE_ENABLED
|
#ifdef CONFIG_BT_NIMBLE_ENABLED
|
||||||
#include "esp_nimble_hci.h"
|
#include "esp_nimble_hci.h"
|
||||||
@@ -35,7 +36,7 @@ static const char *TAG = "app_prov";
|
|||||||
static const char *ssid_prefix = "PROV_";
|
static const char *ssid_prefix = "PROV_";
|
||||||
|
|
||||||
/* Handler for catching WiFi events */
|
/* Handler for catching WiFi events */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int id, void* data);
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int32_t id, void* data);
|
||||||
|
|
||||||
/* Handlers for wifi_config provisioning endpoint */
|
/* Handlers for wifi_config provisioning endpoint */
|
||||||
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
||||||
@@ -198,7 +199,7 @@ static void _stop_prov_cb(void * arg)
|
|||||||
|
|
||||||
/* Event handler for starting/stopping provisioning */
|
/* Event handler for starting/stopping provisioning */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
/* If pointer to provisioning application data is NULL
|
/* If pointer to provisioning application data is NULL
|
||||||
* then provisioning is not running */
|
* then provisioning is not running */
|
||||||
|
@@ -26,7 +26,7 @@
|
|||||||
static const char *TAG = "app";
|
static const char *TAG = "app";
|
||||||
|
|
||||||
static void event_handler(void* arg, esp_event_base_t event_base,
|
static void event_handler(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
static int s_retry_num = 0;
|
static int s_retry_num = 0;
|
||||||
|
|
||||||
|
@@ -14,6 +14,7 @@
|
|||||||
#include <nvs_flash.h>
|
#include <nvs_flash.h>
|
||||||
#include <nvs.h>
|
#include <nvs.h>
|
||||||
#include <esp_event.h>
|
#include <esp_event.h>
|
||||||
|
#include <esp_timer.h>
|
||||||
|
|
||||||
#include <protocomm.h>
|
#include <protocomm.h>
|
||||||
#include <protocomm_console.h>
|
#include <protocomm_console.h>
|
||||||
@@ -26,7 +27,7 @@
|
|||||||
static const char *TAG = "app_prov";
|
static const char *TAG = "app_prov";
|
||||||
|
|
||||||
/* Handler for catching WiFi events */
|
/* Handler for catching WiFi events */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int id, void* data);
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int32_t id, void* data);
|
||||||
|
|
||||||
/* Handlers for wifi_config provisioning endpoint */
|
/* Handlers for wifi_config provisioning endpoint */
|
||||||
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
||||||
@@ -136,7 +137,7 @@ static void _stop_prov_cb(void * arg)
|
|||||||
|
|
||||||
/* Event handler for starting/stopping provisioning */
|
/* Event handler for starting/stopping provisioning */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
/* If pointer to provisioning application data is NULL
|
/* If pointer to provisioning application data is NULL
|
||||||
* then provisioning is not running */
|
* then provisioning is not running */
|
||||||
|
@@ -26,7 +26,7 @@
|
|||||||
static const char *TAG = "app";
|
static const char *TAG = "app";
|
||||||
|
|
||||||
static void event_handler(void* arg, esp_event_base_t event_base,
|
static void event_handler(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
static int s_retry_num = 0;
|
static int s_retry_num = 0;
|
||||||
|
|
||||||
|
@@ -14,6 +14,7 @@
|
|||||||
#include <nvs_flash.h>
|
#include <nvs_flash.h>
|
||||||
#include <nvs.h>
|
#include <nvs.h>
|
||||||
#include <esp_event.h>
|
#include <esp_event.h>
|
||||||
|
#include <esp_timer.h>
|
||||||
|
|
||||||
#include <protocomm.h>
|
#include <protocomm.h>
|
||||||
#include <protocomm_httpd.h>
|
#include <protocomm_httpd.h>
|
||||||
@@ -27,7 +28,7 @@
|
|||||||
static const char *TAG = "app_prov";
|
static const char *TAG = "app_prov";
|
||||||
|
|
||||||
/* Handler for catching WiFi events */
|
/* Handler for catching WiFi events */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int id, void* data);
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int32_t id, void* data);
|
||||||
|
|
||||||
/* Handlers for provisioning endpoints */
|
/* Handlers for provisioning endpoints */
|
||||||
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
||||||
@@ -152,7 +153,7 @@ static void _stop_prov_cb(void * arg)
|
|||||||
|
|
||||||
/* Event handler for starting/stopping provisioning */
|
/* Event handler for starting/stopping provisioning */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
/* If pointer to provisioning application data is NULL
|
/* If pointer to provisioning application data is NULL
|
||||||
* then provisioning is not running */
|
* then provisioning is not running */
|
||||||
|
@@ -26,7 +26,7 @@
|
|||||||
static const char *TAG = "app";
|
static const char *TAG = "app";
|
||||||
|
|
||||||
static void event_handler(void* arg, esp_event_base_t event_base,
|
static void event_handler(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
static int s_retry_num = 0;
|
static int s_retry_num = 0;
|
||||||
|
|
||||||
|
@@ -14,6 +14,7 @@
|
|||||||
#include <nvs_flash.h>
|
#include <nvs_flash.h>
|
||||||
#include <nvs.h>
|
#include <nvs.h>
|
||||||
#include <esp_event.h>
|
#include <esp_event.h>
|
||||||
|
#include <esp_timer.h>
|
||||||
|
|
||||||
#include <protocomm.h>
|
#include <protocomm.h>
|
||||||
#include <protocomm_httpd.h>
|
#include <protocomm_httpd.h>
|
||||||
@@ -26,7 +27,7 @@
|
|||||||
static const char *TAG = "app_prov";
|
static const char *TAG = "app_prov";
|
||||||
|
|
||||||
/* Handler for catching WiFi events */
|
/* Handler for catching WiFi events */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int id, void* data);
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t base, int32_t id, void* data);
|
||||||
|
|
||||||
/* Handlers for wifi_config provisioning endpoint */
|
/* Handlers for wifi_config provisioning endpoint */
|
||||||
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
extern wifi_prov_config_handlers_t wifi_prov_handlers;
|
||||||
@@ -138,7 +139,7 @@ static void _stop_prov_cb(void * arg)
|
|||||||
|
|
||||||
/* Event handler for starting/stopping provisioning */
|
/* Event handler for starting/stopping provisioning */
|
||||||
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
static void app_prov_event_handler(void* handler_arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
/* If pointer to provisioning application data is NULL
|
/* If pointer to provisioning application data is NULL
|
||||||
* then provisioning is not running */
|
* then provisioning is not running */
|
||||||
|
@@ -37,7 +37,7 @@ static EventGroupHandle_t wifi_event_group;
|
|||||||
|
|
||||||
/* Event handler for catching system events */
|
/* Event handler for catching system events */
|
||||||
static void event_handler(void* arg, esp_event_base_t event_base,
|
static void event_handler(void* arg, esp_event_base_t event_base,
|
||||||
int event_id, void* event_data)
|
int32_t event_id, void* event_data)
|
||||||
{
|
{
|
||||||
if (event_base == WIFI_PROV_EVENT) {
|
if (event_base == WIFI_PROV_EVENT) {
|
||||||
switch (event_id) {
|
switch (event_id) {
|
||||||
|
Reference in New Issue
Block a user