No description
* Adds HardwareSerial::onReceiveTimeout()
* Fixed typo
* Changes requested
* Fix eventQueueReset
* Changed _onReceiveTimeout to _rxTimeout for consistency
* Uniform uart_set_rx_timeout condition
* test _uart not NULL in eventQueueReset()
check if _uart is not NULL before using it.
* revert last commit - no need for it
reverting last change made - it is not necessary.
* adds onReceive() parameter
In order to allow the user to choose if onReceive() call back will be called only when UART Rx timeout happens or also when UART FIFO gets 120 bytes,
a new parameter has been added to onReceive() with the default behavior based on timeout.
void onReceive(OnReceiveCb function, bool onlyOnTimeout = true);
onReceive will setup a callback that will be called whenever an UART interruption occurs (UART_INTR_RXFIFO_FULL or UART_INTR_RXFIFO_TOUT)
UART_INTR_RXFIFO_FULL interrupt triggers at UART_FULL_THRESH_DEFAULT bytes received (defined as 120 bytes by default in IDF)
UART_INTR_RXFIFO_TOUT interrupt triggers at UART_TOUT_THRESH_DEFAULT symbols passed without any reception (defined as 10 symbos by default in IDF)
onlyOnTimeout parameter will define how onReceive will behave:
Default: true -- The callback will only be called when RX Timeout happens.
Whole stream of bytes will be ready for being read on the callback function at once.
This option may lead to Rx Overflow depending on the Rx Buffer Size and number of bytes received in the streaming
false -- The callback will be called when FIFO reaches 120 bytes and also on RX Timeout.
The stream of incommig bytes will be "split" into blocks of 120 bytes on each callback.
This option avoid any sort of Rx Overflow, but leaves the UART packet reassembling work to the Application.
* Adds onReceive() parameter for timeout only
* Adds back setRxTimeout()
* Adds setRxTimeout()
* CI Syntax error - "," missing
Co-authored-by: Rodrigo Garcia <rodrigo.garcia@espressif.com>
|
||
|---|---|---|
| .github | ||
| cores/esp32 | ||
| docs | ||
| libraries | ||
| package | ||
| tests | ||
| tools | ||
| variants | ||
| .gitignore | ||
| .gitmodules | ||
| boards.txt | ||
| CMakeLists.txt | ||
| component.mk | ||
| CONTRIBUTING.rst | ||
| idf_component.yml | ||
| Kconfig.projbuild | ||
| LICENSE.md | ||
| Makefile.projbuild | ||
| package.json | ||
| platform.txt | ||
| programmers.txt | ||
| README.md | ||
Arduino core for the ESP32, ESP32-S2 and ESP32-C3
Need help or have a question? Join the chat at 
Contents
Development Status
Documentation
You can use Arduino-ESP32 Online Documentation to get all information about this project.
- Getting Started
- Installing (Windows, Linux and macOS)
- Libraries
- ESP-IDF as Component
- FAQ
- Troubleshooting
Supported Chips
Visit the supported chips documentation to see the list of current supported ESP32 SoCs.
Decoding exceptions
You can use EspExceptionDecoder to get meaningful call trace.
Issue/Bug report template
Before reporting an issue, make sure you've searched for similar one that was already created. Also make sure to go through all the issues labelled as Type: For reference.
Finally, if you are sure no one else had the issue, follow the Issue template or Feature request template while reporting any new Issue.
Contributing
We welcome contributions to the Arduino ESP32 project!
See contributing in the documentation for more information on how to contribute to the project.