Flex/ input no pull test done

This commit is contained in:
amugniere@gmail.com 2022-07-08 22:02:49 +02:00
parent f911ad25c3
commit 555f18aa95

View File

@ -122,13 +122,15 @@ async fn main(_spawner: Spawner, p: Peripherals) {
assert!(b.is_high()); assert!(b.is_high());
} }
} }
/*
// Test input no pull // Test input no pull
{ {
let b = Input::new(&mut b, Pull::None); let mut b = Flex::new(&mut b);
// no pull, the status is undefined b.set_as_input(Pull::None); // no pull, the status is undefined
let mut a = Output::new(&mut a, Level::Low, Speed::Low); let mut a = Flex::new(&mut a);
a.set_low();
a.set_as_output(Speed::Low);
delay(); delay();
assert!(b.is_low()); assert!(b.is_low());
a.set_high(); a.set_high();
@ -136,6 +138,7 @@ async fn main(_spawner: Spawner, p: Peripherals) {
assert!(b.is_high()); assert!(b.is_high());
} }
/*
// Test input pulldown // Test input pulldown
{ {
let b = Input::new(&mut b, Pull::Down); let b = Input::new(&mut b, Pull::Down);