Turn OFF WiFi on ESP32 with esp-idf

Die_32_
Posts: 58
Joined: Wed May 05, 2021 2:42 pm

Turn OFF WiFi on ESP32 with esp-idf

Postby Die_32_ » Wed Jan 12, 2022 4:29 pm

Hi,

is it possible to turn OFF the WiFi Radio on ESP32 and esp-idf ?

Cannot find the related API

User avatar
mzimmers
Posts: 643
Joined: Wed Mar 07, 2018 11:54 pm
Location: USA

Re: Turn OFF WiFi on ESP32 with esp-idf

Postby mzimmers » Wed Jan 12, 2022 6:36 pm

Applications start up without automatically starting WiFi. If you don't want it, just don't start it.

Die_32_
Posts: 58
Joined: Wed May 05, 2021 2:42 pm

Re: Turn OFF WiFi on ESP32 with esp-idf

Postby Die_32_ » Thu Jan 13, 2022 9:40 am

Sorry, I did not understand.

Is the a function to call in order to stop the WiFi ?

ESP_User1563
Posts: 5
Joined: Sat Feb 06, 2021 2:02 am

Re: Turn OFF WiFi on ESP32 with esp-idf

Postby ESP_User1563 » Fri Jan 14, 2022 4:21 am

Both of the following are used to start and stop the wifi in ESP examples. Look for the start in your code somewhere that is starting it and comment it out or use the stop command when you want to stop it.


esp_err_t results = esp_wifi_start();
esp_err_t results = esp_wifi_stop();

Die_32_
Posts: 58
Joined: Wed May 05, 2021 2:42 pm

Re: Turn OFF WiFi on ESP32 with esp-idf

Postby Die_32_ » Tue Jan 18, 2022 11:10 am

esp_err_t results = esp_wifi_stop();

This worked correctly, thanks!

Who is online

Users browsing this forum: No registered users and 465 guests