Split the Arduino registers into a new crate
This commit is contained in:
7
arduino/Cargo.toml
Normal file
7
arduino/Cargo.toml
Normal file
@@ -0,0 +1,7 @@
|
||||
[package]
|
||||
name = "arduino"
|
||||
version = "0.1.0"
|
||||
authors = ["Jake Goulding <jake.goulding@gmail.com>"]
|
||||
|
||||
[dependencies.core]
|
||||
path = "../libcore"
|
||||
@@ -1,5 +1,10 @@
|
||||
//! Definitions of register addresses and bits within those registers
|
||||
|
||||
#![feature(no_core)]
|
||||
#![no_core]
|
||||
|
||||
extern crate core;
|
||||
|
||||
macro_rules! bit {
|
||||
(-, $pos:expr) => {};
|
||||
($name:ident, $pos:expr) => {
|
||||
8
blink/Cargo.lock
generated
8
blink/Cargo.lock
generated
@@ -1,6 +1,14 @@
|
||||
[root]
|
||||
name = "blink"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"arduino 0.1.0",
|
||||
"core 0.1.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "arduino"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"core 0.1.0",
|
||||
]
|
||||
|
||||
@@ -5,3 +5,6 @@ authors = ["Jake Goulding <jake.goulding@gmail.com>"]
|
||||
|
||||
[dependencies.core]
|
||||
path = "../libcore"
|
||||
|
||||
[dependencies.arduino]
|
||||
path = "../arduino"
|
||||
|
||||
@@ -7,15 +7,15 @@
|
||||
#![no_main]
|
||||
|
||||
extern crate core as avr_core;
|
||||
extern crate arduino;
|
||||
|
||||
use avr_core::prelude::v1::*;
|
||||
use avr_core::intrinsics::{volatile_load, volatile_store};
|
||||
|
||||
pub mod prelude;
|
||||
pub mod avr;
|
||||
pub mod timer1;
|
||||
|
||||
use avr::*;
|
||||
use arduino::*;
|
||||
use prelude::*;
|
||||
|
||||
#[lang = "eh_personality"]
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
use avr_core::prelude::v1::*;
|
||||
use avr_core::intrinsics::volatile_store;
|
||||
|
||||
use ::avr::*;
|
||||
use arduino::*;
|
||||
|
||||
pub enum ClockSource {
|
||||
None,
|
||||
|
||||
Reference in New Issue
Block a user