Simple test¶
Ensure your device works with this simple test.
examples/mcp9600_simpletest.py¶
1# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
2# SPDX-License-Identifier: MIT
3
4import time
5import board
6import busio
7import adafruit_mcp9600
8
9i2c = busio.I2C(board.SCL, board.SDA, frequency=100000)
10mcp = adafruit_mcp9600.MCP9600(i2c)
11
12while True:
13 print((mcp.ambient_temperature, mcp.temperature, mcp.delta_temperature))
14 time.sleep(1)