Skip to content

Commit 243027f

Browse files
committed
RBExt
1 parent d1a8367 commit 243027f

File tree

9 files changed

+1032
-783
lines changed

9 files changed

+1032
-783
lines changed

Cargo.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,9 @@ document-features = "0.2"
6666
micromath = { version = "2.1.0", optional = true }
6767

6868
[dependencies.stm32f4]
69-
package = "stm32f4-staging"
70-
version = "0.18.0"
69+
#package = "stm32f4-staging"
70+
path = "/home/burrbull/stm32-rs/stm32f4"
71+
#version = "0.18.0"
7172
features = ["atomics"]
7273

7374
[dependencies.time]

src/fmpi2c.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ impl<I2C: Instance> I2c<I2C> {
206206
if isr.nackf().bit_is_set() {
207207
self.i2c
208208
.icr()
209-
.write(|w| w.stopcf().set_bit().nackcf().set_bit());
209+
.write(|w| w.stopcf().clear_bit_by_one().nackcf().clear_bit_by_one());
210210
return Err(Error::NoAcknowledge(NoAcknowledgeSource::Unknown));
211211
}
212212

src/gpio.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ pub enum Pull {
127127
Down = 2,
128128
}
129129

130-
impl From<Pull> for pac::gpioa::pupdr::PUPDR0 {
130+
impl From<Pull> for pac::gpioa::pupdr::PULL {
131131
fn from(value: Pull) -> Self {
132132
match value {
133133
Pull::Down => Self::PullDown,
@@ -206,7 +206,7 @@ pub enum Speed {
206206
VeryHigh = 3,
207207
}
208208

209-
impl From<Speed> for pac::gpioa::ospeedr::OSPEEDR0 {
209+
impl From<Speed> for pac::gpioa::ospeedr::OUTPUT_SPEED {
210210
fn from(value: Speed) -> Self {
211211
match value {
212212
Speed::Low => Self::LowSpeed,

src/gpio/convert.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use super::*;
2-
use crate::pac::gpioa::{moder::MODER0 as Mode, otyper::OT0 as OutputType};
2+
use crate::pac::gpioa::{moder::MODE as Mode, otyper::OUTPUT_TYPE as OutputType};
33

44
impl Input {
55
pub fn new<const P: char, const N: u8, MODE: PinMode>(

src/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,8 +132,6 @@ pub mod spi;
132132
pub mod syscfg;
133133
pub mod time;
134134
pub mod timer;
135-
#[cfg(feature = "uart4")]
136-
pub mod uart;
137135
pub mod watchdog;
138136

139137
mod sealed {

0 commit comments

Comments
 (0)