-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Latest version draws too much energy - seems that WiFi is enabled by default #72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
the stack is not started, just the radio. You should not power the esp from FTDI though. Get a proper LDO to 3.3V |
I added a 3.3V buck converter, but radio was not started automagically in previous version, was it? |
The difference from the previous version is in RF calibration process. Now it takes slightly longer and needs more current. |
The latest version is also running at 240mhz vs 160mhz previously which means it draws more power overall too, I know that will be configurable in the future. My Espressif dev board draws 160ma now from 120ma previously. Do you have plans/is it possible to have the RF calibration and all radio functions not start up until they are called/initialized by the Arduino IDE? maybe this is already possible from the IDF directly? |
There seems to be a regression in the ESP-IDF that wifi initialization only works correctly when it is called pretty early on. Someone (myself or one of my colleagues) will look into this next week. Once we fix this, WiFi initialization can be moved to a later stage, when e.g. WiFi.begin is called. @me-no-dev has already done all the work on Arduino side, we just need to figure out what goes wrong with WiFi init. Once WiFi init is moved from startup code, we can postpone RF init as well. Edit: ESP-IDF does have an option not to initialize RF in startup code. |
The force has been restored! |
Now the dev board only draws 80ma at 240mhz when previously it was 150ma with WiFi always on :) |
Oh this is really good! I can tell I need to optimize pinMode pulls to drop it under 1us :) |
I'm guessing something changed in the pinMode function since earlier Nov as my previous test shows it 0.526 us even at the lower clock speed.. I was having trouble getting the STM32Duino core working with some STM32 dev boards so cant include those yet.. But I did just add a comparison to the Teensy 3.6 board with NXP K66 Cortex M4 that someone else ran these same tests on. The ESP32 compares pretty well against that chip, some areas are a little slower, some faster. I bet there is room for improvement with some optimization too ;) |
yes pinMode has changed because some pins have pull up/down settings elsewhere. I'll try to improve speed there, but some pins will always pinMode slower than others. If you pinMode pins 16 or 17 you will see a difference (closer to what you had before). I can probably run this against STM32F1 board |
Thank you for solving this issue. |
I live in Bulgaria. You coming by? :D |
@clowrey here are my measurements with the latest commits (note I pinMode pin 16 which is not RTC pin) Added a couple STMs |
Great! Can you share the google docs file so I can copy some of the results into my spreadsheet for comparison? It might be neat to create a record of improvements from current to future versions of the Arduino ESP32 core |
it's not a google doc :) https://www.icloud.com/numbers/0wwqzBkq_vjYwtaYOmhyF8FqA#Untitled |
Hello , is there a way to keep WIFI switched off for EPS8266? I did not find any kind of documentation so far. I want to start WIFI in the Arduino sketch later on once needed. Thanks, |
ESP8266? |
Sorry yes, typo. |
Why ask here :) this is the ESP32 repository. ESP8266 Arduino is here |
Minor detail @me-no-dev In regards to your Numbers spreadsheet, I believe the NRF52832 is 64Mhz. (Not sure if your original clock speed was in reference to something else though...) http://infocenter.nordicsemi.com/pdf/nRF52832_PS_v1.3.pdf |
@pctj101 It was mostly already made spreadsheet. I added some of the boards, but not the NRF :) do not have one |
I am having similar bug. This time I lost wifi connection and the router rebooted and got on track. My esp32 displayed correctly and also updated me through the serial monitor that I am connected, however, my esp itself just got stock without actually doing anything. Below is the message print_out: Connecting to MQTT... [D][WiFiGeneric.cpp:336] _eventCallback(): Event: 5 - STA_DISCONNECTED |
This is a highly requested item in message boards. Is there a blocker to enabling it?
…DME (espressif#72) * Install pip3 which is required for adafruit-nrfutil * Update travis example in README
I updated today and now the esp32 fails to boot. It seems that the FTDI adapter can not provide enough energy.
I already had that problem before (with previous versions of this plugin) as I tried to run a sketch that uses WIFI without additional power source.
So I guess that the latest commits enable WiFi by default. In that case I think that WiFi should explicit be enabled by user code.
The text was updated successfully, but these errors were encountered: