View Source IS31FL3733.I2CBehavior behaviour (is31fl3733 v0.1.2)

Explicit contract behavior used for I2C communication.

Link to this section Summary

Link to this section Types

Link to this section Callbacks

@callback close(bus()) :: :ok
@callback open(binary() | charlist()) :: {:ok, bus()} | {:error, term()}
Link to this callback

write(bus, address, iodata)

View Source
@callback write(bus(), address(), iodata()) :: :ok | {:error, term()}
Link to this callback

write(bus, address, iodata, list)

View Source
@callback write(bus(), address(), iodata(), [opt()]) :: :ok | {:error, term()}
Link to this callback

write_read(bus, address, iodata, pos_integer)

View Source
@callback write_read(bus(), address(), iodata(), pos_integer()) ::
  {:ok, binary()} | {:error, term()}
Link to this callback

write_read(bus, address, iodata, pos_integer, list)

View Source
@callback write_read(bus(), address(), iodata(), pos_integer(), [opt()]) ::
  {:ok, binary()} | {:error, term()}