rust-embedded/rust-raspberrypi-OS-tutorials

[Announce] tock-based registers

andre-richter opened this issue · 2 comments

Adding some people to whom it might be of interest. You are kindly invited to review, or just silently ignore ;)

@alevy @bradjc @niklasad1 @brghena @phil-opp @ryankurte @ppannuto

Hi all,

In tock/tock#930, I started my idea of having a common register interface for both CPU and MMIO registers based on the tock register interface. Thank you very much to the tock folks for carving out a crate for it!
Today, I finally have a first peek ready for one of my RaspberryPI 3 subprojects.
Check it out at https://github.com/andre-richter/rust-raspi3-tutorial/tree/registers/09_delays

There are some distributed components involved.

In the end, you can see, for example in https://github.com/andre-richter/rust-raspi3-tutorial/blob/registers/09_delays/src/delays.rs, that MMIO and CPU accesses are side by side, using the same tock-regs API. Very very neat!

alevy commented

@andre-richter this is pretty cool!

All is now merged on master and published on crates.io.