diff --git a/ESP32-IDF_ESPNOW-Receiver/build/.ninja_lock b/ESP32-IDF_ESPNOW-Receiver/build/.ninja_lock new file mode 100644 index 000000000..e69de29bb diff --git a/ESP32-IDF_ESPNOW-Receiver/main/receiver.c b/ESP32-IDF_ESPNOW-Receiver/main/receiver.c index aa2811fcf..321832a7b 100644 --- a/ESP32-IDF_ESPNOW-Receiver/main/receiver.c +++ b/ESP32-IDF_ESPNOW-Receiver/main/receiver.c @@ -25,4 +25,15 @@ void wifi_init() #if CONFIG_ESPNOW_ENABLE_LONG_RANGE ESP_ERROR_CHECK( esp_wifi_set_protocol(ESPNOW_WIFI_IF, WIFI_PROTOCOL_11B|WIFI_PROTOCOL_11G|WIFI_PROTOCOL_11N|WIFI_PROTOCOL_LR) ); #endif +} + +void transmission_init() { + + esp_err_t espnow_ret = esp_now_init(); + if (espnow_ret != ESP_OK) { + ESP_LOGE(TAG, "esp_now_init() failed: %s", esp_err_to_name(espnow_ret)); + return; + } + ESP_LOGI(TAG, "ESPNOW initialized successfully"); + } \ No newline at end of file