Class Max6675
Driver class for the MAX6675 thermocouple-to-digital converter. Provides temperature readings from K-type thermocouples with 12-bit resolution.
Assembly: Max6675.dll
View Source
public class Max6675 : ITemperatureSensor, ISensor<Temperature>, ISensor, ISpiPeripheral, IDisposable
Implements:
Meadow.Peripherals.Sensors.ITemperatureSensor, Meadow.Peripherals.Sensors.ISensor<Meadow.Units.Temperature>, Meadow.Peripherals.Sensors.ISensor, Meadow.Hardware.ISpiPeripheral, System.IDisposable
Properties
IsDisposed
Gets whether this object has been disposed.
View Source
public bool IsDisposed { get; }
DefaultSpiBusSpeed
Gets the default SPI bus speed for MAX6675 communication.
View Source
public Frequency DefaultSpiBusSpeed { get; }
DefaultSpiBusMode
Gets the default SPI bus mode (Mode 0) for MAX6675 communication.
View Source
public SpiClockConfiguration.Mode DefaultSpiBusMode { get; }
SpiBusMode
Gets or sets the SPI bus mode for communication.
View Source
public SpiClockConfiguration.Mode SpiBusMode { get; set; }
SpiBusSpeed
Gets or sets the SPI bus speed for communication.
View Source
public Frequency SpiBusSpeed { get; set; }
Methods
Read()
Reads the current temperature from the MAX6675 thermocouple converter.
View Source
public Task<Temperature> Read()
Returns
System.Threading.Tasks.Task<Meadow.Units.Temperature>: A task containing the temperature in Celsius.
Exceptions
System.Exception
Thrown when the thermocouple input is open (not connected).
Dispose(bool)
Releases unmanaged and - optionally - managed resources.
View Source
protected virtual void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
System.Boolean | disposing | true to release both managed and unmanaged resources; |
false to release only unmanaged resources. |
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
View Source
public void Dispose()
Implements
Meadow.Peripherals.Sensors.ITemperatureSensorMeadow.Peripherals.Sensors.ISensor<Meadow.Units.Temperature>Meadow.Peripherals.Sensors.ISensorMeadow.Hardware.ISpiPeripheralSystem.IDisposable