almindor / mipidsi

MIPI Display Serial Interface unified driver
MIT License
117 stars 46 forks source link

Feat/maybe async support #71

Closed xgroleau closed 1 year ago

xgroleau commented 1 year ago

Here is how it would look if we used maybe-async-cfg to handle sync and async code, see the doc for macro here.

Mainly we just compile and change the identifier for the async ones and we end up with a async and sync variant of each trait and struct. Ex: The lib would have an DisplayAsync and Display struct.

I havent completed all the impl for all the displays since I wanted your feedback beforehand and didn't want to overload the PR with noise. Currently, only the GC9A01 is implemented but it would be pretty much the same for all models.

Note that I've updated embedded-hal and I'm currently using the git version of display-interface since the release with async support was not created yet.

xgroleau commented 1 year ago

Closed as discussed in #63