esp-rs / esp32-hal

A hardware abstraction layer for the esp32 written in Rust.
Apache License 2.0
192 stars 28 forks source link

Baremetal 1.0.0 #60

Closed KerryRJ closed 2 years ago

KerryRJ commented 2 years ago

I have updated the baremetal crate to 1.0.0. This requires changes to svd2rust, xtensa-lx, esp32 and esp32-hal as the InterruptNumber trait was removed from baremetal. I have successfully tested the changes with the quickstart.

I have added the trait to xtensa-lx

pub unsafe trait InterruptNumber: Copy {
    /// Return the interrupt number associated with this variant.
    ///
    /// See trait documentation for safety requirements.
    fn number(self) -> u16;
}

Is updating the baremetal crate acceptable? If it is, should this stay with the current fn nr(self) -> u16 or if fn number(self) -> u16 is acceptable?

@MabezDev

MabezDev commented 2 years ago

I think so - we will want to release a new xtensa-lx{-rt} etc release anyway. I welcome the PR on xtensa-lx.

KerryRJ commented 2 years ago

I just went to upstream the svd2rust changes and noticed xtensa-lx 0.3.0 xtensa-lx-rt 0.5.0 are configured. Should I PR svd2rust changes with updated version numbers for those crates and if I do what should their version numbers be, or should I be PR'ing the xtensa-lx/-rt updates before svd2rust? If I PR lx/-rt first we bumping the minor or release numbers, i.e. 0.3.1 and 0.5.1?

MabezDev commented 2 years ago

Yes, we'll want to work our way up from the bottom of the chain, so xtensa-lx & xtensa-lx-rt first. I can make a release once I merge https://github.com/esp-rs/xtensa-lx-rt/pull/23.

MabezDev commented 2 years ago

In my zombie like state I just published 0.6.0 of xtensa-lx-rt without your PR and without bumping bare metal :facepalm:. Would you mind sending your PR over so I can release 0.7.0

KerryRJ commented 2 years ago

Sent the PR.

MabezDev commented 2 years ago

Release in 0.3.0