File tree Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -182,18 +182,19 @@ defmodule Circuits.I2C do
182
182
end
183
183
184
184
@ doc """
185
- close the I2C bus
185
+ Close the I2C bus
186
186
"""
187
187
@ spec close ( Bus . t ( ) ) :: :ok
188
188
def close ( bus ) do
189
189
Bus . close ( bus )
190
190
end
191
191
192
192
@ doc """
193
- Return a list of available I2C bus names. If nothing is returned, it's
194
- possible that the kernel driver for that I2C bus is not enabled or the
195
- kernel's device tree is not configured. On Raspbian, run `raspi-config` and
196
- look in the advanced options.
193
+ Return a list of available I2C bus names
194
+
195
+ If nothing is returned, it's possible that the kernel driver for that I2C bus
196
+ is not enabled or the kernel's device tree is not configured. On Raspbian,
197
+ run `raspi-config` and look in the advanced options.
197
198
198
199
```elixir
199
200
iex> Circuits.I2C.bus_names()
@@ -207,8 +208,10 @@ defmodule Circuits.I2C do
207
208
end
208
209
209
210
@ doc """
210
- Scan the I2C bus for devices by performing a read at each device address and
211
- returning a list of device addresses that respond.
211
+ Scan the I2C bus for devices
212
+
213
+ Since there's no official way of enumerating I2C devices, this attempts to
214
+ figure out what's on the bus by seeing what devices respond.
212
215
213
216
```elixir
214
217
iex> Circuits.I2C.detect_devices("i2c-1")
You can’t perform that action at this time.
0 commit comments