You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The networking and async I/O support in embedded rust is slowly getting better. For that support to be accessible in RTIC, I think it would make sense to allow the idle task to be async.
e.g.
#[idle]asyncfnidle(cx: idle::Context){
...}
The regular idle would still work of course, but when the function is prefixed with async, it's allowed to return (and would return an impl Future<Output = ()>).
Users can already run an executor in the idle task of course, but having an executor built into RTIC would let it do smart things by default, like wfi when the future isn't running.
Future Possibilities
This could eventually be extended to allow for all tasks to be async, but idle seems like a safe bet first.
The text was updated successfully, but these errors were encountered:
The networking and async I/O support in embedded rust is slowly getting better. For that support to be accessible in RTIC, I think it would make sense to allow the
idle
task to beasync
.e.g.
The regular
idle
would still work of course, but when the function is prefixed withasync
, it's allowed to return (and would return animpl Future<Output = ()>
).Users can already run an executor in the
idle
task of course, but having an executor built into RTIC would let it do smart things by default, likewfi
when the future isn't running.Future Possibilities
This could eventually be extended to allow for all tasks to be async, but
idle
seems like a safe bet first.The text was updated successfully, but these errors were encountered: