rtic icon indicating copy to clipboard operation
rtic copied to clipboard

(partially) removing core peripherals from RTIC context

Open romancardenas opened this issue 2 years ago • 4 comments

As discussed in the previous meeting, now that RTIC v2 targets multiple architectures, some items seem too biased toward Cortex-M microcontrollers.

One of these elements is rtic::export::Peripherals. For instance, the RISC-V architecture does not have a common set of peripherals, and the current successful ports (#733 or greenlsi/rtic) end up re-exporting the device peripherals twice.

The main options we discussed to tackle this issue are:

  1. Leave rtic::export::Peripherals as () when not needed.
  2. Feature-gate the core peripherals of the context so it is only active when it makes sense.
  3. Completely remove core peripherals from RTIC.

It would be nice to have a discussion about this topic. Personally, I'm inclined to the third option, as we would keep a common interface for all the targets. However, it may break already working examples/projects.

romancardenas avatar Apr 27 '23 11:04 romancardenas

I think we can remove it. It's only a rename is cortex-m peripherals, and we can use it's full name instead.

korken89 avatar Jun 30 '23 06:06 korken89

Now with the awesome work in #733 merged, how should we go about this? Breaking change if we remove it altogether, but it would be cleaner :+1:

AfoHT avatar Oct 04 '23 19:10 AfoHT

I'm currently working on a PR for adding support to RISC-V targets over the SLIC. I hope to be done this week. Maybe I can add this change to the PR and discuss there.

romancardenas avatar Oct 04 '23 19:10 romancardenas

PR opened: #815

romancardenas avatar Oct 06 '23 13:10 romancardenas