I'm building a library to be used on a no_std platform which allows you to do some common network-related IO, such as making HTTP requests or reading from/writing to Websockets.
Now, I would like this library to be a well-behaved citizen so that it can be easily included in other no_std applications. I hence want to package the library by implementing reasonable traits etc. The library would allow me to not have to use alloc, so supporting non-alloc no_std would be ideal.
These are the options I have looked at:
embedded_hal and nb: These crates are really low level (no generic traits like Read and Write or anything higher level) and the async model doesn't seem to be compatible with async/awaitgenio/core_io/...: These don't support async IO at all.embrio: Seems interesting but it seems like using it would tie me to one specific environment, making the library less portable.tokio v0.2.x: I would love to use it but there is no no_std support at all.futures::io v0.3.x: Again, would love to use it but there is no no_std support.Which async IO abstraction should I use in a no_std environment? If there is no good option right now, which one should I bet on/help out with for the future?
Take a look a look at embassy-rs. There is a very active community. Currently, embassy-rs supports;
All built on rust async. There are also some really nice macros to generate static buffers for tasks, so you don't need alloc.