esp-hal 1.0.0 beta announcement · Espressif Developer Portal #408
Replies: 1 comment 1 reply
-
And so you took out one of the better Rust features out of your hal. How often do you need to store pins in an array? It doesn't sound like maintainable code.
Then your opinion goes against the majority of the community. If you don't like looking at long types you can use type aliases.
This quote is from your developer guidelines. I don't understand how someone can be working on a hal and don't see value in strongly typed pins. It's not just used for configuration, it provides strong guarantees about pins for the rest of the code. There is a reason the rust-embedded book recommends that. If my task needs two inputs and one pulled-up output I don't want to have to remember about that - the information can be encoded in the type system and then it won't compile if it's misconfigured.
The solution to that is type erasure for release builds. You get strong typing for development and small binaries when you go to flash the device. I'm not really sure why you went with Rust if you don't see value in strong typing. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
esp-hal 1.0.0 beta announcement · Espressif Developer Portal
The developer resources in just one place!
https://developer.espressif.com/blog/2025/02/rust-esp-hal-beta/
Beta Was this translation helpful? Give feedback.
All reactions