Skip to content

an example of a nix flake to provide a dev environment to cross compile a simple arduino program for the atmega2560.

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT
Notifications You must be signed in to change notification settings

arnemileswinter/rust-atmega2560-cross-compile-nix-blinking-led

Repository files navigation

Run nix develop --ignore-environment and cargo build to build the blinking-LED program for the atmega2560. You might need to enable nix experimental features flakes and nix commands.


avr-hal-template

cargo-generate template for jumpstarting projects on common AVR microcontroller boards. This template supports the following hardware at this time:

  • Arduino Leonardo
  • Arduino Mega 2560
  • Arduino Mega 1280
  • Arduino Nano
  • Arduino Nano New Bootloader (Manufactured after January 2018)
  • Arduino Uno
  • SparkFun ProMicro
  • Adafruit Trinket
  • Adafruit Trinket Pro

Usage

If you don't have them already, install cargo-generate and ravedude:

cargo install cargo-generate
cargo install ravedude

Then instanciate this template:

cargo generate --git https://github.com/Rahix/avr-hal-template.git

You will be prompted to select your board - do so and you're ready to roll! Everything is prepared so you should be able to just

cargo run

and see a blinky flashed to your board!

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

About

an example of a nix flake to provide a dev environment to cross compile a simple arduino program for the atmega2560.

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published