Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By Robin2
#68099 I'm new here but I have been participating in the Arduino Forum for a while.

As I understand it the normal usage of an ESP2866 requires the "WiFi side" to be called at regular intervals. That could interfere with precise timing of other things. If I did not need the WiFi capability could I compile an ESP2866 program without any of the WiFi capability so that I could use it as a cheap simple 80MHz microprocessor?

Thanks

...R
User avatar
By rudy
#68126 Even if you compile without wifi included it may still be active due to retained previous settings. So make sure you turn wifi off in the code rather than just excluding it.

I think you need to include the following.

#include <ESP8266WiFi.h>

add the following lines at the beginning of your setup()

WiFi.disconnect();
WiFi.mode(WIFI_OFF);
User avatar
By QuickFix
#68138 You can also turn off WiFi RF completely, but then the watchdog will kick in after a few ms, so you'll have to reset it every once in a while in your code as well.

Turn off WiFi RF, eg. in setup():
Code: Select allWiFi.forceSleepBegin();

Then, in your loop, regularly reset the watchdog using:
Code: Select allwdt_reset();


Note, that you can also double-clock your ESP, so it will run on 160MHz instead of 80MHz.
In setup() do:
Code: Select allsystem_update_cpu_freq(160);