Circuits.GPIO.Chip.read_value

You're seeing just the function read_value, go back to Circuits.GPIO.Chip module for more information.

Specs

read_value(Circuits.GPIO.Chip.LineHandle.t()) ::
  {:ok, offset_value()} | {:error, atom()}

Read value from a line handle

This is useful when you have a line handle that contains only one GPIO offset.

If you want to read multiple GPIOs at once see Circuits.GPIO.Chip.read_values/1.

{:ok, line_handle} = Circuits.GPIO.Chip.request_line("gpiochip0", 17)
{:ok, 0} = Circuits.GPIO.Chip.read_value(line_handle)