examples: modify other examples and tests to use esp_netif instead of tcpip_adapter

This commit is contained in:
David Cermak
2019-09-01 18:25:23 +02:00
parent 0eec84bc4f
commit b834c99148
24 changed files with 85 additions and 54 deletions

View File

@@ -17,7 +17,7 @@
#include "test_utils.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "tcpip_adapter.h"
#include "esp_netif.h"
#include "lwip/sockets.h"
const esp_partition_t *get_test_data_partition(void)
@@ -32,7 +32,7 @@ const esp_partition_t *get_test_data_partition(void)
void test_case_uses_tcpip(void)
{
// Can be called more than once, does nothing on subsequent calls
tcpip_adapter_init();
esp_netif_init();
// Allocate all sockets then free them
// (First time each socket is allocated some one-time allocations happen.)
@@ -49,7 +49,7 @@ void test_case_uses_tcpip(void)
// Allow LWIP tasks to finish initialising themselves
vTaskDelay(25 / portTICK_RATE_MS);
printf("Note: tcpip_adapter_init() has been called. Until next reset, TCP/IP task will periodicially allocate memory and consume CPU time.\n");
printf("Note: esp_netif_init() has been called. Until next reset, TCP/IP task will periodicially allocate memory and consume CPU time.\n");
// Reset the leak checker as LWIP allocates a lot of memory on first run
unity_reset_leak_checks();