Compare commits

..

No commits in common. "e6eea599b4f3d5adcc3d710cb5c920c40a5846dc" and "5b2648440fd2fdf08e25e9a5912f15bd4d8e400a" have entirely different histories.

2 changed files with 10 additions and 12 deletions

View File

@ -4,8 +4,7 @@ version = "0.1.0"
edition = "2021"
[dependencies]
arduino-hal = { git = "https://github.com/rahix/avr-hal", features = ["arduino-uno"] }
panic-halt = "0.2.0"
ruduino = { git = "https://github.com/avr-rust/ruduino", branch = "master" }
[profile.release]
lto = true

View File

@ -1,19 +1,18 @@
#![no_std]
#![no_main]
use arduino_hal::delay_ms;
use panic_halt as _;
use ruduino::cores::current::port::B5 as led;
use ruduino::delay::delay_ms;
use ruduino::Pin;
#[arduino_hal::entry]
fn main() -> ! {
let peripherals = arduino_hal::Peripherals::take().unwrap();
let pins = arduino_hal::pins!(peripherals);
let mut led = pins.d13.into_output();
led.set_high();
#[no_mangle]
pub extern "C" fn main() -> ! {
led::set_output();
loop {
led.toggle();
led::set_high();
delay_ms(1000);
led::set_low();
delay_ms(1000);
}
}