eclipse / mraa

Linux Library for low speed IO Communication in C with bindings for C++, Python, Node.js & Java. Supports generic io platforms, as well as Intel Edison, Intel Joule, Raspberry Pi and many more.
http://mraa.io
MIT License
1.36k stars 613 forks source link

Semantic of mraa_uart_set_timeout with zero read timeout unclear #1072

Open jan-kiszka opened 2 years ago

jan-kiszka commented 2 years ago

The documentation states "<= 0 will disable that timeout" (for all timeout values but. as we know, only read is implemented so far). Now, does disabling mean non-blocking or infinite blocking? Implemented is the former, @johnson325 once wrote a change (https://github.com/siemens/mraa/commit/a1bee1d7bd044a7658e54d894b5ffbfb33f58360#diff-e8bb0dd62dcd38efa1cafbb258e5b0a4a46624f361b3ec05329a4e10d08bccf0L675) for our patch queue that assumed the latter. Trying to sort this out right now.