Editing
esp
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===ESP-specific APIs=== APIs related to deep sleep and watchdog timer are available in the ESP object, only available in Alpha version.<br> :ESP.deepSleep(microseconds, mode) will put the chip into deep sleep. mode is one of WAKE_RF_DEFAULT, WAKE_RFCAL, WAKE_NO_RFCAL, WAKE_RF_DISABLED. (GPIO16 needs to be tied to RST to wake from deepSleep.)<br> :ESP.restart() restarts the CPU. :ESP.getFreeHeap() returns the free heap size. :ESP.getChipId() returns the ESP8266 chip ID as a 32-bit integer. <br> :Several APIs may be used to get flash chip info: :ESP.getFlashChipId() returns the flash chip ID as a 32-bit integer. :ESP.getFlashChipSize() returns the flash chip size, in bytes, as seen by the SDK (may be less than actual size). :ESP.getFlashChipSpeed(void) returns the flash chip frequency, in Hz. :ESP.getCycleCount() returns the cpu instruction cycle count since start as an unsigned 32-bit. This is useful for accurate timing of very short actions like bit banging. :ESP.getVcc() may be used to measure supply voltage. ESP needs to reconfigure the ADC at startup in order for this feature to be available. Add the following line to the top of your sketch to use getVcc: ADC_MODE(ADC_VCC); ::TOUT pin has to be disconnected in this mode. ::Note that by default ADC is configured to read from TOUT pin using analogRead(A0), and ESP.getVCC() is not available. {{template:top}}
Summary:
Please note that all contributions to Notebook may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Notebook:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Home Page
C++ Reference
ESP Hardware
ESPHome
Home Assistant
Network Stuff
Tools
What links here
Related changes
Special pages
Page information