docs/library/esp.rst: Document the osdebug function.

pull/8281/head
Jos Verlinde 2022-02-07 18:34:57 +01:00 zatwierdzone przez Damien George
rodzic f99b679916
commit 58cd2a8b0a
1 zmienionych plików z 15 dodań i 0 usunięć

Wyświetl plik

@ -62,6 +62,21 @@ Functions
.. function:: flash_erase(sector_no)
.. function:: osdebug(level)
Turn esp os debugging messages on or off.
The *level* parameter sets the threshold for the log messages for all esp components.
The log levels are defined as constants:
* ``LOG_NONE`` -- No log output
* ``LOG_ERROR`` -- Critical errors, software module can not recover on its own
* ``LOG_WARN`` -- Error conditions from which recovery measures have been taken
* ``LOG_INFO`` -- Information messages which describe normal flow of events
* ``LOG_DEBUG`` -- Extra information which is not necessary for normal use (values, pointers, sizes, etc)
* ``LOG_VERBOSE`` -- Bigger chunks of debugging information, or frequent messages
which can potentially flood the output
.. function:: set_native_code_location(start, length)
**Note**: ESP8266 only