Skip to content

Commit

Permalink
Merge pull request #38 from adafruit/stemma_i2c
Browse files Browse the repository at this point in the history
Added commented out board.STEMMA_I2C with explanation
  • Loading branch information
kattni authored Nov 18, 2022
2 parents f3a5c65 + fcaea82 commit a547f6a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion examples/vl53l0x_multiple_sensors.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
from adafruit_vl53l0x import VL53L0X

# declare the singleton variable for the default I2C bus
i2c = board.I2C()
i2c = board.I2C() # uses board.SCL and board.SDA
# i2c = board.STEMMA_I2C() # For using the built-in STEMMA QT connector on a microcontroller

# declare the digital output pins connected to the "SHDN" pin on each VL53L0X sensor
xshut = [
Expand Down
5 changes: 3 additions & 2 deletions examples/vl53l0x_multiple_sensors_continuous.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
from adafruit_vl53l0x import VL53L0X

# declare the singleton variable for the default I2C bus
i2c = board.I2C()
i2c = board.I2C() # uses board.SCL and board.SDA
# i2c = board.STEMMA_I2C() # For using the built-in STEMMA QT connector on a microcontroller

# declare the digital output pins connected to the "SHDN" pin on each VL53L0X sensor
xshut = [
Expand Down Expand Up @@ -71,7 +72,7 @@
# In the python REPR, you can scan for all I2C devices that are attached and detirmine
# their addresses using:
# >>> import board
# >>> i2c = board.I2C()
# >>> i2c = board.I2C() # uses board.SCL and board.SDA
# >>> if i2c.try_lock():
# >>> [hex(x) for x in i2c.scan()]
# >>> i2c.unlock()
Expand Down

0 comments on commit a547f6a

Please sign in to comment.