Skip to content

Commit 52b0a1f

Browse files
authored
Merge pull request #2 from dglaude/patch-1
Update README.rst
2 parents cda8882 + 5d8bb78 commit 52b0a1f

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,11 +63,23 @@ Usage Example
6363
.. code-block:: python
6464
6565
import time
66+
import analogio
67+
import digitalio
68+
import board
6669
from pimoroni_mics6814 import Pimoroni_MICS6814
6770
71+
PIN_NH3 = analogio.AnalogIn(board.A0)
72+
PIN_RED = analogio.AnalogIn(board.A1)
73+
PIN_OX = analogio.AnalogIn(board.A2)
74+
PIN_ENABLE = digitalio.DigitalInOut(board.A4)
75+
76+
MICS6814 = Pimoroni_MICS6814(PIN_OX, PIN_RED, PIN_NH3, PIN_ENABLE)
77+
6878
while True:
79+
print(MICS6814.read_all())
6980
time.sleep(1.0)
7081
82+
7183
Contributing
7284
============
7385

0 commit comments

Comments
 (0)