-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Fix uart regressions & bugs. Using `uart.on()` with a search character was broken in that it did not invoke the callback on a full UART buffer as documented. Logic reworked to match docs again. Fixed memory leak on `task_post()` failure (eep!). Improved logic to attempt to coalesce input bytes to reduce the number of `task_post()` slots used up by the platform uart. Finally, added a semaphore to prevent the platform uart from overrunning the `task_post()` slots all the time on high baud rates (e.g. 1mbit). With the semaphore in there, the LVM RTOS task gets a chance to actually process the received data and free up a `task_post()` slot or two. The above mentioned read coalescing then allows the platform uart to immediately catch up. Also added an error log message if the `task_post()` actually does fail. * Don't cache the uart delims. Doing so makes reconfiguring those settings from within the callback not take effect until the currently buffered bytes have been processed.
- Loading branch information
Johny Mattsson
authored
Oct 12, 2019
1 parent
a4fa6c5
commit b0558d5
Showing
1 changed file
with
43 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters