Skip to content

MicroPython driver for the MAX31865 thermocouple amplifier

License

Notifications You must be signed in to change notification settings

aalbersJulia/temperature-reader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation


Logo

Temperature Reader

Raspberry Pi Pico MicroPython interface for the MAX31865 thermocouple amplifier

Getting Started

To get started with the MAX31865 driver on a MicroPython system, follow these simple steps.

Installation

  1. Download the max31865.py file from the repository.
  2. Copy the max31865.py file to your MicroPython device. You can use tools like ampy or a file transfer method suitable for your device.

Usage

  1. Connect the MAX31865 thermocouple amplifier to your Raspberry Pi Pico or any other MicroPython-supported board.
  2. Include the max31865.py module in your MicroPython script together with the machine module for configuring the SPI bus and chip select pin:
import machine
from max31865 import MAX31865
  1. Configure the SPI bus and chip select pin:
# Define SPI bus and chip select pin
spi = machine.SPI(0, baudrate=5000000, phase=1, sck=machine.Pin(2), mosi=machine.Pin(3), miso=machine.Pin(4))
cs = machine.Pin(machine.Pin.board.GP5)
  1. Create an instance of the MAX31865 class:
sensor = MAX31865(spi, cs)
  1. The current temperature can by retrieved by accessing the temperature attribute of the sensor instance:
temperature = sensor.temperature
print(f"Current Temperature: {temperature} °C")

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

About

MicroPython driver for the MAX31865 thermocouple amplifier

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages