Skip to content

Commit 45ad786

Browse files
sebromeroactions-user
authored andcommitted
Update documentation
1 parent 6df71f4 commit 45ad786

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

docs/api.md

+35
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,12 @@
1414
* [\_\_bool\_\_](#modulino.modulino.Modulino.__bool__)
1515
* [connected](#modulino.modulino.Modulino.connected)
1616
* [pin\_strap\_address](#modulino.modulino.Modulino.pin_strap_address)
17+
* [device\_type](#modulino.modulino.Modulino.device_type)
18+
* [change\_address](#modulino.modulino.Modulino.change_address)
1719
* [read](#modulino.modulino.Modulino.read)
1820
* [write](#modulino.modulino.Modulino.write)
1921
* [has\_default\_address](#modulino.modulino.Modulino.has_default_address)
22+
* [available\_devices](#modulino.modulino.Modulino.available_devices)
2023
* [reset\_bus](#modulino.modulino.Modulino.reset_bus)
2124
* [pixels](#modulino.pixels)
2225
* [ModulinoColor](#modulino.pixels.ModulinoColor)
@@ -157,6 +160,27 @@ is needed to determine the type of the modulino at boot time, so it know what to
157160
At boot it checks the internal flash in case its address has been overridden by the user
158161
which would take precedence.
159162

163+
<a id="modulino.modulino.Modulino.device_type"></a>
164+
165+
### `device_type`
166+
167+
```python
168+
@property
169+
def device_type()
170+
```
171+
172+
Returns the type of the modulino based on the pinstrap address.
173+
174+
<a id="modulino.modulino.Modulino.change_address"></a>
175+
176+
### `change_address`
177+
178+
```python
179+
def change_address(new_address)
180+
```
181+
182+
Sets the address of the i2c device to the given value.
183+
160184
<a id="modulino.modulino.Modulino.read"></a>
161185

162186
### `read`
@@ -190,6 +214,17 @@ def has_default_address()
190214
Determines if the given modulino has a default address
191215
or if a custom one was set.
192216

217+
<a id="modulino.modulino.Modulino.available_devices"></a>
218+
219+
### `available_devices`
220+
221+
```python
222+
@staticmethod
223+
def available_devices()
224+
```
225+
226+
Finds all devices on the i2c bus and returns a list of Modulino objects.
227+
193228
<a id="modulino.modulino.Modulino.reset_bus"></a>
194229

195230
### `reset_bus`

0 commit comments

Comments
 (0)