pythoncoder's uasyncio fork
Posted: Sat Jul 07, 2018 11:21 am
I have updated my uasyncio repo. These are the main changes, prompted by the recent addition of io.IOBase.
The ability to write I/O device drivers in Python is a major improvement and eliminates the need for the ad hoc API changes in aysncio_priority. It also provides more efficient polling by means of the select mechanism. Finally stream I/O can be applied to devices not normally considered to be streaming devices: I have included examples.
- Tutorial now includes details of how to use io.IOBase to write device drivers.
- Added an "under the hood" doc which attempts to explain how uasyncio works.
- Added a fast_io version of uasyncio containing some pending changes plus extra comments to aid understanding of uasyncio.
- Fixes a bug whereby bidirectional stream devices (such as UARTS) can fail.
- Throws an exception rather than silently failing if (e.g.) CreateTask is called incorrectly (a common error).
- Provides an optional facility to schedule I/O at high priority.
The ability to write I/O device drivers in Python is a major improvement and eliminates the need for the ad hoc API changes in aysncio_priority. It also provides more efficient polling by means of the select mechanism. Finally stream I/O can be applied to devices not normally considered to be streaming devices: I have included examples.