overlay/pi-sensors: explicitly disable pullup

This commit is contained in:
Astro 2022-06-30 22:13:26 +02:00
parent 9dfe960b97
commit cfe91aa4ae
1 changed files with 2 additions and 1 deletions

View File

@ -1,5 +1,5 @@
use embedded_hal::digital::v2::{InputPin, OutputPin};
use rppal::gpio::{IoPin, Mode};
use rppal::gpio::{IoPin, Mode, PullUpDown};
use void;
/**
@ -13,6 +13,7 @@ pub struct OpenPin {
impl OpenPin {
pub fn new(mut pin: IoPin) -> OpenPin {
pin.set_mode(Mode::Input);
pin.set_pullupdown(PullUpDown::Off);
OpenPin {
iopin: pin,
mode: Mode::Input,