nrf-hal
atsamd
Our great sponsors
nrf-hal | atsamd | |
---|---|---|
5 | 10 | |
469 | 531 | |
3.8% | 2.4% | |
6.8 | 6.9 | |
10 days ago | 10 days ago | |
Rust | Rust | |
Apache License 2.0 | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
nrf-hal
-
Rust newcomers are 70x less likely to create vulnerabilities than C++ newcomers [pdf]
You should try again. I think that code is verbose because of the borrowing and because you're trying to do a one-liner. I use the nrf-hal library with the nrf52840, and the code reads pretty nicely. Here's an example:
https://github.com/nrf-rs/nrf-hal/blob/master/examples/blink...
-
Any good examples of using embedded Rust with an existing embedded C codebase?
Reading nrf-hal source, unfortunately new does re-configure the UARTE, and there is not a new_unchecked. The solution I can think of is to duplicate the write code with nrf52833_hal::pac::UARTE0. The Uarte type does not contain any metadata, it exists purely to guard the init of UARTE.
- Rust on the MOS 6502: Beyond Fibonacci
-
First steps with Embedded Rust: Selecting a board
Really good. Check out the examples in the nrf-hal repo. Also, if you don't mind forking out for some extra components the Knurling sessions by Ferrous Systems are ace.
-
I rewrote my Rust keyboard firmware in Zig: consistency, mastery, and fun
The embedded HAL crates do this with extensive use of macros, for example: https://github.com/nrf-rs/nrf-hal/blob/aae17943efc24baffe30b...
This solution makes sense given the constraints of Rust, but there's quite a cost in terms of compiler time and cognitive overhead to understand what is going on.
(Aside: I didn't use the HAL in my Rust firmware, that's a higher layer of abstraction; I only used the PAC crates.)
atsamd
-
Rust in Automotive
It’s definitely used for “nonsafety” stuff like infotainment. The ATSAMD HAL/PACs are probably the most complete embedded microcontroller family as far as Rust support goes, and that’s a part with heavy intent toward automotive use.
-
Looking for a highly resource constrained target to run Rust on. Any ideas?
The Rust ATSAMD community has been very helpful getting me going. I've really become fond of RTIC as a way to get a little structure in my programs.
- Code Rust in Aurdino??
-
Are there any ways to use rust for the Arduino MKR WiFi 1010?
The atsamd-rs rust folks (https://github.com/atsamd-rs/atsamd) have made this way easier! Check out my top level comment!
-
Hello, Microcontroller! Intro to video codecs and the "hello, world" of microcontrollers implemented in ~100 lines of dependency-free Rust
I'm obviously biased, but as a starting point I would recommend getting an Arduino and following the process in the article. Once you have a blinking LED, try it again using a HAL like atsamd-rs/atsamd. Then try making it more complex: configure the clock and replace the delay implementation with something that takes a proper duration argument, add serial IO via the USB port so you can communicate with your program as it runs, connect some more LEDs or buttons and interact with them, or make some network requests.
-
Writing embedded firmware using Rust
The embedded-hal project supplies these for a wide variety of controllers, for SAMD specifically, https://github.com/atsamd-rs/atsamd .
-
First steps with Embedded Rust: Selecting a board
No love for Microchip nee Atmel? https://github.com/atsamd-rs/atsamd
-
Want to Learn Programming and Microcontrollers?
Am admittedly too inexperienced to properly weigh the pros and cons of various platforms, but I find the Rust support for certain embedded platforms to be particularly compelling.
https://github.com/atsamd-rs/atsamd
I have at least managed to get some literal blinkenlights doing what I want on various Adafruit boards with very little effort.
- I’d like to learn rust to make a USB device that enumerates as a mouse to the OS and shakes the pointer every once in a while. I’m a web developer by trade. How realistic is this project?
What are some alternatives?
embassy - Modern embedded framework, using Rust and async.
avr-hal - embedded-hal abstractions for AVR microcontrollers
ziglings - Learn the Zig programming language by fixing tiny broken programs.
SAMD21 - Library Helpers for the Atmel SAM21D
zig - General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
linux-embedded-hal - Implementation of the `embedded-hal` traits for Linux devices
zephyr - Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
riscv-rust-quickstart - A template for building Rust applications for HiFive1 boards
nrf-softdevice
uf2-samdx1 - USB Mass Storage bootloader (based on UF2) for SAMD21 and SAMD51
drogue-device - A distribution of tools and examples for building embedded IoT applications in Rust
OpenSK - OpenSK is an open-source implementation for security keys written in Rust that supports both FIDO U2F and FIDO2 standards.