/// Create a GPIO Input Pin from a Device Path (e.g. "/dev/gpio0")
Create a GPIO Input Pin from a Device Path
Create a GPIO Input Pin from a Device Path
pub fn new(path: &str) -> Result<Self, i32> {
        //  Open the NuttX Device Path (e.g. "/dev/gpio0") for read-write
        let fd = open(path, O_RDWR);
        if fd < 0 { return Err(fd) }
        //  Return the pin
        Ok(Self { fd })
    }
pub fn new ( path : & str ) -> Result < Self , i32 > { //  Open the NuttX Device Path (e.g. "/dev/gpio0") for read-write let fd = open ( path , O_RDWR ) ; if fd < 0 { return Err ( fd ) } //  Return the pin Ok ( Self { fd } ) }
Create a GPIO Input Pin from a Device Path (e.g.
Create a GPIO Input Pin from a Device Path ( e . g .
path
&str