Coder Social home page Coder Social logo

blink's Introduction

blink

An small Hello World Rust application for the AVR.

The program itself toggles a LED on PORTB periodically.

Designed for the ATmega328p.

How to set up a cross compiler

Prerequisites

  • A recent version of he nightly Rust compiler. Anything including or greater than rustc 1.47.0-nightly (0820e54a8 2020-07-23) can be used.
  • The rust-src rustup component - $ rustup component add rust-src
  • AVR-GCC on the system for linking
  • AVR-Libc on the system for support libraries

Usage

Now to build, run:

cargo override set nightly

# Compile the crate to an ELF executable.
cargo build -Z build-std=core --target avr-atmega328p.json --release

There should now be an ELF file at target/avr-atmega328p/release/blink.elf. It can be flashed directly to an AVR microcontroller or ran inside a simulator.

Resources

blink's People

Contributors

dylanmckay avatar fabientregan avatar mb64 avatar pusherofbrooms avatar shepmaster avatar wez avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.