diff --git a/components/esp_wifi_remote/.cz.yaml b/components/esp_wifi_remote/.cz.yaml index 6c82c3a..4452001 100644 --- a/components/esp_wifi_remote/.cz.yaml +++ b/components/esp_wifi_remote/.cz.yaml @@ -3,6 +3,6 @@ commitizen: bump_message: 'bump(wifi_remote): $current_version -> $new_version' pre_bump_hooks: python ../../ci/changelog.py esp_wifi_remote tag_format: wifi_remote-v$version - version: 1.1.1 + version: 1.1.2 version_files: - idf_component.yml diff --git a/components/esp_wifi_remote/idf_v6.0/Kconfig.wifi.in b/components/esp_wifi_remote/idf_v6.0/Kconfig.wifi.in index 0ea9853..accebe9 100644 --- a/components/esp_wifi_remote/idf_v6.0/Kconfig.wifi.in +++ b/components/esp_wifi_remote/idf_v6.0/Kconfig.wifi.in @@ -792,6 +792,14 @@ menu "WPS Configuration Options" be shared to other devices, making it in readable format increases that risk, also passphrase requires pbkdf2 to convert in psk. + config WIFI_RMT_WPS_RECONNECT_ON_FAIL + bool "Reconnect to previous SSID if WPS failed" + default n + help + Select this option to enable reconnection to previous SSID if WPS fails. + This option will only work if station was connected to a network + when WPS was started. + endmenu # "WPS Configuration Options" @@ -1266,6 +1274,12 @@ if WIFI_RMT_WPS_PASSPHRASE default WIFI_RMT_WPS_PASSPHRASE endif +if WIFI_RMT_WPS_RECONNECT_ON_FAIL + config ESP_WIFI_WPS_RECONNECT_ON_FAIL # ignore: multiple-definition + bool + default WIFI_RMT_WPS_RECONNECT_ON_FAIL +endif + if WIFI_RMT_DEBUG_PRINT config ESP_WIFI_DEBUG_PRINT # ignore: multiple-definition bool diff --git a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_now.h b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_now.h index 164e19b..81e5423 100644 --- a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_now.h +++ b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_now.h @@ -102,6 +102,31 @@ typedef wifi_tx_info_t esp_now_send_info_t; */ typedef wifi_tx_rate_config_t esp_now_rate_config_t; +/** + * @brief ESPNOW switch channel information + */ +typedef struct { + wifi_action_tx_t type; /**< ACTION TX operation type */ + uint8_t channel; /**< Channel on which to perform ESPNOW TX Operation */ + wifi_second_chan_t sec_channel; /**< Secondary channel */ + uint32_t wait_time_ms; /**< Duration to wait for on target channel */ + uint8_t op_id; /**< Unique Identifier for operation provided by wifi driver */ + uint8_t dest_mac[6]; /**< Destination MAC address */ + uint16_t data_len; /**< Length of the appended Data */ + uint8_t data[0]; /**< Appended Data payload */ +} esp_now_switch_channel_t; + +/** + * @brief ESPNOW remain on channel information + */ +typedef struct { + wifi_roc_t type; /**< ROC operation type */ + uint8_t channel; /**< Channel on which to perform ESPNOW ROC Operation */ + wifi_second_chan_t sec_channel; /**< Secondary channel */ + uint32_t wait_time_ms; /**< Duration to wait for on target channel */ + uint8_t op_id; /**< ID of this specific ROC operation provided by wifi driver */ +} esp_now_remain_on_channel_t; + /** * @brief Callback function of receiving ESPNOW data * @param esp_now_info received ESPNOW packet information @@ -394,6 +419,32 @@ esp_err_t esp_now_set_user_oui(uint8_t *oui); */ esp_err_t esp_now_get_user_oui(uint8_t *oui); +/** + * @brief ESPNOW switch to a specific channel for a required duration, and send one ESPNOW data. + * + * @param config ESPNOW switch channel relevant information + * + * @return + * - ESP_OK : succeed + * - ESP_ERR_NO_MEM: failed to allocate memory + * - ESP_ERR_INVALID_ARG: the pair is invalid + * - ESP_FAIL: failed to send frame + */ +esp_err_t esp_now_switch_channel_tx(esp_now_switch_channel_t *config); + +/** + * @brief ESPNOW remain on the target channel for required duration. + * + * @param config ESPNOW remain on channel relevant information + * + * @return + * - ESP_OK : succeed + * - ESP_ERR_NO_MEM: failed to allocate memory + * - ESP_ERR_INVALID_ARG: the pair is invalid + * - ESP_FAIL: failed to perform roc operation + */ +esp_err_t esp_now_remain_on_channel(esp_now_remain_on_channel_t *config); + /** * @} */ diff --git a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi.h b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi.h index a51c1fc..eb423de 100644 --- a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi.h +++ b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi.h @@ -1829,6 +1829,7 @@ esp_err_t esp_wifi_get_bandwidths(wifi_interface_t ifx, wifi_bandwidths_t *bw); * @return * - ESP_OK: succeed * - ESP_ERR_NO_MEM: failed to allocate memory + * - ESP_ERR_INVALID_ARG: the pair is invalid * - ESP_FAIL: failed to send frame */ esp_err_t esp_wifi_action_tx_req(wifi_action_tx_req_t *req); @@ -1841,6 +1842,7 @@ esp_err_t esp_wifi_action_tx_req(wifi_action_tx_req_t *req); * @return * - ESP_OK: succeed * - ESP_ERR_NO_MEM: failed to allocate memory + * - ESP_ERR_INVALID_ARG: the pair is invalid * - ESP_FAIL: failed to perform roc operation */ esp_err_t esp_wifi_remain_on_channel(wifi_roc_req_t * req); diff --git a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi_types_generic.h b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi_types_generic.h index a00ae51..0cb38eb 100644 --- a/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi_types_generic.h +++ b/components/esp_wifi_remote/idf_v6.0/include/injected/esp_wifi_types_generic.h @@ -794,6 +794,7 @@ typedef struct { uint8_t dest_mac[6]; /**< Destination MAC address */ wifi_action_tx_t type; /**< ACTION TX operation type */ uint8_t channel; /**< Channel on which to perform ACTION TX Operation */ + wifi_second_chan_t sec_channel; /**< Secondary channel */ uint32_t wait_time_ms; /**< Duration to wait for on target channel */ bool no_ack; /**< Indicates no ack required */ wifi_action_rx_cb_t rx_cb; /**< Rx Callback to receive action frames */