Merge pull request 'Set of fixes' (#2) from smaller-fixes into main
All checks were successful
Rust/va108xx-rs/pipeline/head This commit looks good
All checks were successful
Rust/va108xx-rs/pipeline/head This commit looks good
Reviewed-on: #2
This commit is contained in:
commit
466db8b4e0
13
.github/workflows/ci.yml
vendored
13
.github/workflows/ci.yml
vendored
@ -10,8 +10,8 @@ jobs:
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
targets: "thumbv6m-none-eabi"
|
||||
- run: cargo check --release
|
||||
- run: cargo check --examples --release
|
||||
- run: cargo check --target thumbv6m-none-eabi --release
|
||||
- run: cargo check --target thumbv6m-none-eabi --examples --release
|
||||
|
||||
test:
|
||||
name: Run Tests
|
||||
@ -21,8 +21,9 @@ jobs:
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- name: Install nextest
|
||||
uses: taiki-e/install-action@nextest
|
||||
- run: cargo nextest run --all-features
|
||||
- run: cargo test --doc
|
||||
- run: cargo nextest run --all-features -p va108xx-hal
|
||||
# I think we can skip those on an embedded crate..
|
||||
# - run: cargo test --doc -p va108xx-hal
|
||||
|
||||
fmt:
|
||||
name: Check formatting
|
||||
@ -46,4 +47,6 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- run: cargo clippy -- -D warnings
|
||||
with:
|
||||
targets: "thumbv6m-none-eabi"
|
||||
- run: cargo clippy --target thumbv6m-none-eabi -- -D warnings
|
||||
|
@ -1,7 +1,7 @@
|
||||
Vorago VA108xx Rust Support
|
||||
=========
|
||||
|
||||
This crate collection provided support to write Rust applications for the VA108XX family
|
||||
This crate collection provides support to write Rust applications for the VA108XX family
|
||||
of devices.
|
||||
|
||||
## List of crates
|
||||
|
6
automation/Jenkinsfile
vendored
6
automation/Jenkinsfile
vendored
@ -14,7 +14,7 @@ pipeline {
|
||||
}
|
||||
stage('Clippy') {
|
||||
steps {
|
||||
sh 'cargo clippy'
|
||||
sh 'cargo clippy --target thumbv6m-none-eabi'
|
||||
}
|
||||
}
|
||||
stage('Rustfmt') {
|
||||
@ -24,7 +24,9 @@ pipeline {
|
||||
}
|
||||
stage('Docs') {
|
||||
steps {
|
||||
sh: cargo +nightly doc --all-features --config 'build.rustdocflags=["--cfg", "docs_rs"]'
|
||||
sh """
|
||||
cargo +nightly doc --all-features --config 'build.rustdocflags=["--cfg", "docs_rs"]'
|
||||
"""
|
||||
}
|
||||
}
|
||||
stage('Check') {
|
||||
|
@ -18,3 +18,4 @@ embedded-io = "0.6"
|
||||
version = "0.6"
|
||||
path = "../va108xx-hal"
|
||||
features = ["rt"]
|
||||
|
||||
|
@ -13,15 +13,15 @@
|
||||
#[rtic::app(device = pac, dispatchers = [OC4])]
|
||||
mod app {
|
||||
use embedded_io::Write;
|
||||
use panic_rtt_target as _;
|
||||
use rtic_monotonics::systick::Systick;
|
||||
use rtic_sync::make_channel;
|
||||
use panic_rtt_target as _;
|
||||
use rtt_target::{rprintln, rtt_init_print};
|
||||
use va108xx_hal::{
|
||||
time::Hertz,
|
||||
gpio::PinsB,
|
||||
pac,
|
||||
prelude::*,
|
||||
time::Hertz,
|
||||
uart::{self, IrqCfg, IrqResult, UartWithIrqBase},
|
||||
};
|
||||
|
||||
@ -52,7 +52,11 @@ mod app {
|
||||
|
||||
// Initialize the systick interrupt & obtain the token to prove that we did
|
||||
let systick_mono_token = rtic_monotonics::create_systick_token!();
|
||||
Systick::start(cx.core.SYST, Hertz::from(50.MHz()).raw(), systick_mono_token);
|
||||
Systick::start(
|
||||
cx.core.SYST,
|
||||
Hertz::from(50.MHz()).raw(),
|
||||
systick_mono_token,
|
||||
);
|
||||
|
||||
let mut dp = cx.device;
|
||||
let gpiob = PinsB::new(&mut dp.sysconfig, Some(dp.ioconfig), dp.portb);
|
||||
|
@ -43,3 +43,7 @@ default-features = false
|
||||
[features]
|
||||
default = ["rt"]
|
||||
rt = ["va108xx/rt"]
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
all-features = true
|
||||
rustdoc-args = ["--cfg", "docs_rs", "--generate-link-to-definition"]
|
||||
|
@ -1,4 +1,5 @@
|
||||
#![no_std]
|
||||
#![cfg_attr(docs_rs, feature(doc_auto_cfg))]
|
||||
|
||||
pub use va108xx;
|
||||
pub use va108xx as pac;
|
||||
|
@ -21,3 +21,7 @@ version = ">=0.6.15,<0.8"
|
||||
|
||||
[features]
|
||||
rt = ["cortex-m-rt/device"]
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
all-features = true
|
||||
rustdoc-args = ["--cfg", "docs_rs", "--generate-link-to-definition"]
|
||||
|
@ -3,6 +3,8 @@ svd2rust release can be generated by cloning the svd2rust [repository], checking
|
||||
#![allow(non_camel_case_types)]
|
||||
#![allow(non_snake_case)]
|
||||
#![no_std]
|
||||
// Manually inserted.
|
||||
#![cfg_attr(docs_rs, feature(doc_auto_cfg))]
|
||||
use core::marker::PhantomData;
|
||||
use core::ops::Deref;
|
||||
#[doc = r"Number available in the NVIC for configuring priority"]
|
||||
|
@ -1,3 +1,6 @@
|
||||
// Manually inserted.
|
||||
#![allow(clippy::identity_op)]
|
||||
|
||||
#[repr(C)]
|
||||
#[doc = "Register block"]
|
||||
pub struct RegisterBlock {
|
||||
|
@ -18,8 +18,6 @@ dummy-pin = "1"
|
||||
|
||||
[dependencies.max116xx-10bit]
|
||||
version = "0.3"
|
||||
git = "https://egit.irs.uni-stuttgart.de/rust/max116xx-10bit"
|
||||
branch = "bump-embedded-hal"
|
||||
|
||||
[dependencies.va108xx-hal]
|
||||
version = "0.6"
|
||||
@ -39,3 +37,7 @@ version = "0.5"
|
||||
|
||||
[dev-dependencies.panic-rtt-target]
|
||||
version = "0.1"
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
all-features = true
|
||||
rustdoc-args = ["--cfg", "docs_rs", "--generate-link-to-definition"]
|
||||
|
@ -1,4 +1,5 @@
|
||||
#![no_std]
|
||||
#![cfg_attr(docs_rs, feature(doc_auto_cfg))]
|
||||
|
||||
pub mod button;
|
||||
pub mod leds;
|
||||
|
Loading…
Reference in New Issue
Block a user