Merge pull request #197 from ferrous-systems/minor_fixes

Minor_fixes
This commit is contained in:
Tanks Transfeld 2023-02-21 16:46:36 +01:00 committed by GitHub
commit 25cd0faf70
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 12 additions and 21 deletions

View file

@ -8,7 +8,7 @@ version = "0.0.0"
[dependencies]
cortex-m = {version = "0.7.6", features = ["critical-section-single-core"]}
cortex-m-rt = "0.7.2"
dk_template = { path = "../dk_bsc" }
dk_bsc = { path = "../dk_bsc" }
heapless = "0.7.16"
panic-probe = { version = "0.3.0", features = ["print-defmt"] }
defmt = "0.3.2"

View file

@ -4,7 +4,7 @@
use cortex_m::asm;
use cortex_m_rt::entry;
use core::fmt::Write;
// this imports `beginner/apps/lib.rs` to retrieve our global logger + panicking-behavior
// this imports `down-the-stack/apps/lib.rs` to retrieve our global logger + panicking-behavior
use apps as _;
#[entry]
@ -26,7 +26,4 @@ fn main() -> ! {
}
// this program does not `exit`; use Ctrl+C to terminate it
loop {
asm::nop();
}
}

View file

@ -4,7 +4,7 @@
use cortex_m::asm;
use cortex_m_rt::entry;
use core::fmt::Write;
// this imports `beginner/apps/lib.rs` to retrieve our global logger + panicking-behavior
// this imports `down-the-stack/apps/lib.rs` to retrieve our global logger + panicking-behavior
use apps as _;
#[entry]
@ -20,7 +20,7 @@ fn main() -> ! {
let tx_buffer = "Hello\n";
// this program does not `exit`; use Ctrl+C to terminate it
loop {
if button_1.is_pushed() {
uarte.write_str(tx_buffer).unwrap();

View file

@ -2,14 +2,14 @@
authors = ["Jorge Aparicio <jorge.aparicio@ferrous-systems.com>", "Tanks Transfeld <tanks.transfeld@ferrous-systems.com"]
edition = "2018"
license = "MIT OR Apache-2.0"
name = "dk_template"
name = "dk_bsc"
version = "0.0.0"
[dependencies]
cortex-m = {version = "0.7.6", features = ["critical-section-single-core"]}
cortex-m-rt = "0.7.2"
embedded-hal = "0.2.7"
hal = { package = "nrf52840-hal", version = "0.14.0" }
nrf52840-hal = "0.14.0"
panic-probe = { version = "0.3.0", features = ["print-defmt"] }
defmt = "0.3.2"
defmt-rtt = "0.3.2"
@ -22,11 +22,3 @@ default = [
"other-feature"
]
other-feature = []
# do NOT modify these features
defmt-default = []
defmt-trace = []
defmt-debug = []
defmt-info = []
defmt-warn = []
defmt-error = []

View file

@ -1,7 +1,6 @@
//! Hardware Abstraction Layer (HAL) for the nRF52840 Development Kit
//! Board Support Crate (BSC) for the nRF52840 Development Kit
#![deny(missing_docs)]
#![deny(warnings)]
#![no_std]
use core::{
@ -13,6 +12,7 @@ use core::{
use cortex_m::asm;
use embedded_hal::digital::v2::{OutputPin as _, StatefulOutputPin};
use nrf52840_hal as hal;
use hal::{
gpio::{p0, Level, Output, Pin, Port, PushPull},
timer::OneShot,

View file

@ -1,7 +1,6 @@
//! Hardware Abstraction Layer (HAL) for the nRF52840 Development Kit
//! Board Support Crate (BSC) for the nRF52840 Development Kit
#![deny(missing_docs)]
#![deny(warnings)]
#![no_std]
use core::{
@ -13,9 +12,12 @@ use core::{
use cortex_m::asm;
use embedded_hal::digital::v2::{OutputPin as _, StatefulOutputPin};
use nrf52840_hal as hal;
pub use hal::pac::{
UARTE1, uarte0::{
baudrate::BAUDRATE_A as Baudrate, config::PARITY_A as Parity}};
use hal::{
gpio::{p0, Level, Output, Input, PullUp, Pin, Port, PushPull},
timer::OneShot, prelude::InputPin,