sipeed / bl602-hal

Hardware Abstract Layer for BL602 RISC-V WiFi + BLE SoC in embedded Rust
Other
74 stars 14 forks source link

Additionally implement HAL 0.2.5 I2C traits, add examples, some improvements #25

Closed bjoernQ closed 3 years ago

bjoernQ commented 3 years ago

This PR contains the following changes / additions

In future I'd like to add more of the 0.2.x traits and examples but this is already a lot to review.

luojia65 commented 3 years ago

Great!

mkroman commented 3 years ago

Awesome!

Regarding the examples - would they maybe be better to put in the sipeed/bl602-rust-guide project?

Also, what are the files in bin/* for?

bjoernQ commented 3 years ago

Thanks for the kind feedback.

My idea regarding the examples is to have it like https://github.com/stm32-rs/stm32f1xx-hal within the hal-repo since it is nice to have the samples always in sync with the code and in future make it easier to provide a working sample together with new functionality. That way a reviewer gets something to test and tinker with - without the need to write own code or checkout an additional example. Also, during development it's easier to check that nothing else broke by introducing changes by just running the samples.

But certainly, a separate standalone guide is very valuable anyway.

Regarding the bin folder:

bjoernQ commented 3 years ago

Thanks a lot! I really like the idea to rename the assembly file and the blobs. I guess there won't be anything besides the trap handler every so I renamed it to trap.S and prefixed the blobs with trap_