←back to thread

205 points michidk | 2 comments | | HN request time: 0.673s | source
Show context
marmaduke ◴[] No.41835214[source]
I’m doing some C on esp32 currently, and wondered about switching to rust, and I understand that simple cases with Rust are solid. I’m definitely interested in trying it out.

However we need to work with a lot of the hardware apis like twai, ble, lte, ota, etc. It seems like support is spotty or it’s DIY.

It’s also worth keeping mind the remark about developer availability. I can generally answer questions about the C to someone who’s not experienced in C, while Rust might be another story.

replies(1): >>41835548 #
1. j-krieger ◴[] No.41835548[source]
> It seems like support is spotty or it’s DIY

I can somewhat attest to this! I have a pretty extensive prototype of using Rust on ESP32 in production. I wrote a reference implementation for ESP32 platforms deployed via BRSKI, a secure remote key bootstrapping protocol which builds upon attestation keys and public key infrastructure.

I'm largely using `esp-idf-svc` for most things, which is a Rust-native wrapper around ESP-IDF code. For anything closer to the hardware, I'm using `esp-idf-sys` which is just a thin wrapper around the the `ESP-IDF` SDK.

You can see the project here: https://github.com/hm-seclab/open-brski

Hope this helps! I'm by no means an expert but I sometimes help contribute to the Rust ESP32 ecosystem, so ask away if you want :)

replies(1): >>41837835 #
2. marmaduke ◴[] No.41837835[source]
Hi! Thanks for your reply. First time hearing about Brski, I’ll have a look

I guess your takeaway is that despite spotty support, the benefits of rust are net positive? I guess learning to call C from Rust is gonna be part of it too right ?