pub trait Gpio {
// Required methods
fn gpio_req(&self, port: GpioPort, pinmsk: XwSq) -> XwEr;
fn gpio_rls(&self, port: GpioPort, pinmsk: XwSq) -> XwEr;
fn gpio_cfg(&self, port: GpioPort, pinmsk: XwSq, cfg: *mut c_void) -> XwEr;
fn gpio_set(&self, port: GpioPort, pinmsk: XwSq) -> XwEr;
fn gpio_reset(&self, port: GpioPort, pinmsk: XwSq) -> XwEr;
fn gpio_toggle(&self, port: GpioPort, pinmsk: XwSq) -> XwEr;
fn gpio_output(&self, port: GpioPort, pinmsk: XwSq, out: XwSq) -> XwEr;
fn gpio_input(&self, port: GpioPort, pinmsk: XwSq) -> (XwEr, XwSq);
}
Expand description
SOC的特性:GPIO