Skip to main content

pamoja_gpio_line_read

Function pamoja_gpio_line_read 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn pamoja_gpio_line_read( line: *mut PamojaGpioLine, out_level: *mut PamojaPinLevel, ) -> PamojaStatus
Expand description

Reads the level on a line now.

§Arguments

  • line - the line.
  • out_level - receives the level.

§Returns

PamojaStatus::Ok with the level in out_level; PamojaStatus::InvalidArgument for a null argument; or PamojaStatus::Io when the kernel refuses the read.

§Safety

line must be a live handle from one of the open functions, or null, and out_level a writable pointer or null.