Skip to content

Commit e133912

Browse files
fix(wifi): Added oui check for ESPNOW
Add new api to set/get user oui for ESPNOW Closes espressif#9577
1 parent b0f8342 commit e133912

File tree

2 files changed

+23
-2
lines changed

2 files changed

+23
-2
lines changed

components/esp_wifi/include/esp_now.h

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* SPDX-FileCopyrightText: 2019-2024 Espressif Systems (Shanghai) CO LTD
2+
* SPDX-FileCopyrightText: 2019-2025 Espressif Systems (Shanghai) CO LTD
33
*
44
* SPDX-License-Identifier: Apache-2.0
55
*/
@@ -368,6 +368,27 @@ esp_err_t esp_now_set_pmk(const uint8_t *pmk);
368368
*/
369369
esp_err_t esp_now_set_wake_window(uint16_t window);
370370

371+
/**
372+
* @brief Set the OUI (Organization Identifier) in the vendor-specific element for ESPNOW.
373+
*
374+
* @param oui The oui should occupy 3 bytes. If the oui is NULL, then use the default value (0x18fe34).
375+
*
376+
* @return
377+
* - ESP_OK : succeed
378+
*/
379+
esp_err_t esp_now_set_user_oui(uint8_t *oui);
380+
381+
/**
382+
* @brief Get the OUI (Organization Identifier) in the vendor-specific element for ESPNOW.
383+
*
384+
* @param oui user configured OUI.
385+
*
386+
* @return
387+
* - ESP_OK : succeed
388+
* - ESP_ERR_ESPNOW_ARG : invalid argument
389+
*/
390+
esp_err_t esp_now_get_user_oui(uint8_t *oui);
391+
371392
/**
372393
* @}
373394
*/

0 commit comments

Comments
 (0)