Skip to content

Commit 15de340

Browse files
authored
Merge pull request #33 from adafruit/stemma_i2c
Added commented out board.STEMMA_I2C with explanation
2 parents 04f4d14 + bdd8370 commit 15de340

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

examples/sht31d_periodic_mode.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
import adafruit_sht31d
77

88
# Create sensor object, communicating over the board's default I2C bus
9-
i2c = board.I2C()
9+
i2c = board.I2C() # uses board.SCL and board.SDA
10+
# i2c = board.STEMMA_I2C() # For using the built-in STEMMA QT connector on a microcontroller
1011
sensor = adafruit_sht31d.SHT31D(i2c)
1112

1213
print("\033[1mSensor\033[0m = SHT31-D")

examples/sht31d_simple_mode.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
import adafruit_sht31d
66

77
# Create sensor object, communicating over the board's default I2C bus
8-
i2c = board.I2C()
8+
i2c = board.I2C() # uses board.SCL and board.SDA
9+
# i2c = board.STEMMA_I2C() # For using the built-in STEMMA QT connector on a microcontroller
910
sensor = adafruit_sht31d.SHT31D(i2c)
1011

1112
print("\033[1mSensor\033[0m = SHT31-D")

examples/sht31d_simpletest.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
import adafruit_sht31d
77

88
# Create sensor object, communicating over the board's default I2C bus
9-
i2c = board.I2C()
9+
i2c = board.I2C() # uses board.SCL and board.SDA
10+
# i2c = board.STEMMA_I2C() # For using the built-in STEMMA QT connector on a microcontroller
1011
sensor = adafruit_sht31d.SHT31D(i2c)
1112

1213
loopcount = 0

0 commit comments

Comments
 (0)