top | item 42542590

(no title)

gregoryw3 | 1 year ago

Just wondering why you decided to use Embassy and RTIC? Was there any specific reasons? I’m doing an Embassy project on an esp right now so wondering if you have any issues or insights worth mentioning?

From my understanding Embassy and RTIC are two different models of concurrency so I’m not sure of any benefit of using both at the same time.

discuss

order

Arch-TK|1 year ago

So, on the STM32 (which is the only place I am using RTIC), I don't use the Embassy executor. I just use the embassy-stm32 hal crate for all my peripherals and embassy-futures for some of the executor-agnostic no_std and non-alloc futures utilities.

A lot of embassy (except quite unsurprisingly, the executor) is executor agnostic. In fact, I think it might be _all_ of embassy that is executor agnostic. There's some information here: https://rtic.rs/dev/book/en/rtic_and_embassy.html

While my code is not public yet, here is an example (written by someone else) of STM32 code using the embassy-stm32 I2C peripheral wrapper with RTIC:

https://github.com/andresv/rtic_arbiter_demo/blob/master/src...

gregoryw3|1 year ago

Interesting! Thanks for sharing, Rust always seems to have something new to learn.