atsams-rs / atsamx7x-rust

Rust HAL, PACs, and examples for the Microship SAM E70/S70/V70/V71
Apache License 2.0
25 stars 11 forks source link

Move heavylifting to the user, relief us from updating over 40k files #23

Closed michalfita closed 1 year ago

michalfita commented 2 years ago

As suggested by @tmplt in #21, this is about harnessing power of build.rs to manage PAC crates.

michalfita commented 2 years ago

@tmplt I have good news: I've hacked my way to get PAC crate where build.rs handles generation via svd2rust. Some long standing unresolved problems in Rust itself stand in opposition to do it in a clean way, but in overall this works with some tradeoffs:

I'll work on this more and PR some draft, but for now I need to move back to issues that require closing ASAP.

michalfita commented 1 year ago

It took some time, but most things seem to be in place. I've published some alpha releases, if anyone is willing to test using them from crates.io. FYI @tmplt

BTW. I've noticed atsam-rs now publish PACs for SAME70 with -pac suffix. I wonder if that competition makes any sense.

tmplt commented 1 year ago

On 02/20/2023 22:33, Michał Fita wrote:

It took some time, but most things seem to be in place. I've published some alpha releases https://crates.io/crates/atsame70n19b/0.28.0-alpha0, if anyone is willing to test using them from crates.io. FYI @tmplt https://github.com/tmplt

I'll take a look once a PR is ready.

BTW. I've noticed |atsam-rs| now publish PACs for SAME70 with |-pac| suffix. I wonder if that competition makes any sense.

Looks like a side-effect of other PAC generation.

michalfita commented 1 year ago

Looks like a side-effect of other PAC generation.

They responded to my request.

I'll take a look once a PR is ready.

That's going to be separate repository (actually is, but not publicized yet).

michalfita commented 1 year ago

This is addressed in atsamx7x-pac repository and issue #56 / PR #61.