Characteristic Locus
Inheritance object ObservableBase<Temperature> SamplingSensorBase<Temperature> Thermistor > SteinhartHartCalculatedThermistor
Implements IObservable<IChangeResult<Temperature>> ITemperatureSensor ISamplingSensor<Temperature> ISensor<Temperature>
Inherited Members Thermistor.AnalogInputPort Thermistor.NominalTemperature Thermistor.StartUpdating(TimeSpan?) Thermistor.StopUpdating() Thermistor.Temperature Thermistor.TemperatureUpdated SamplingSensorBase<Temperature>.samplingLock SamplingSensorBase<Temperature>.Updated SamplingSensorBase<Temperature>.SamplingTokenSource SamplingSensorBase<Temperature>.Conditions SamplingSensorBase<Temperature>.IsSampling SamplingSensorBase<Temperature>.UpdateInterval SamplingSensorBase<Temperature>.RaiseEventsAndNotify(IChangeResult<Temperature>) SamplingSensorBase<Temperature>.Read() ObservableBase<Temperature>.observers ObservableBase<Temperature>.NotifyObservers(IChangeResult<Temperature>) ObservableBase<Temperature>.Subscribe(IObserver<IChangeResult<Temperature>>) ObservableBase<Temperature>.CreateObserver(Action<IChangeResult<Temperature>>, Predicate<IChangeResult<Temperature>>) object.Equals(object) object.Equals(object, object) object.GetHashCode() object.GetType() object.MemberwiseClone() object.ReferenceEquals(object, object) object.ToString()
Namespace Meadow.Foundation.Sensors.Temperature
Assembly Thermistor.dll

Syntax

public class SteinhartHartCalculatedThermistor : Thermistor, IObservable<IChangeResult<Temperature>>, ITemperatureSensor, ISamplingSensor<Temperature>, ISensor<Temperature>

Constructors

SteinhartHartCalculatedThermistor(IAnalogInputPort, Resistance)

Creates a new SteinhartHartCalculatedThermistor object using the provided analog input and the thermistor's nominal resistance (i.e. 10kOhm)

Declaration
public SteinhartHartCalculatedThermistor(IAnalogInputPort analogInput, Resistance nominalResistance)

Parameters

Type Name Description
IAnalogInputPort analogInput

The analog input reading the thermistor voltage divider output

Resistance nominalResistance

The nominal resistance of the thermistor (e.g. 10kOhm for a 10k thermistor)

Remarks

The fixed resistor value will be assumed to match the thermistor's nominal resistance

SteinhartHartCalculatedThermistor(IAnalogInputPort, Resistance, Resistance)

Creates a new SteinhartHartCalculatedThermistor object using the provided analog input and the thermistor's nominal resistance (i.e. 10kOhm) and the fixed resistor value of the voltage divider circuit.

Declaration
public SteinhartHartCalculatedThermistor(IAnalogInputPort analogInput, Resistance nominalResistance, Resistance seriesResistance)

Parameters

Type Name Description
IAnalogInputPort analogInput

The analog input reading the thermistor voltage divider output

Resistance nominalResistance

The nominal resistance of the thermistor (e.g. 10kOhm for a 10k thermistor)

Resistance seriesResistance

The resistance of the fixed-value series resistor in your voltage divider circuit

SteinhartHartCalculatedThermistor(IAnalogInputPort, Resistance, Resistance, double)

Creates a new SteinhartHartCalculatedThermistor object using the provided analog input and the thermistor's nominal resistance (i.e. 10kOhm) and the fixed resistor value of the voltage divider circuit.

Declaration
public SteinhartHartCalculatedThermistor(IAnalogInputPort analogInput, Resistance nominalResistance, Resistance seriesResistance, double betaCoefficient)

Parameters

Type Name Description
IAnalogInputPort analogInput

The analog input reading the thermistor voltage divider output

Resistance nominalResistance

The nominal resistance of the thermistor (e.g. 10kOhm for a 10k thermistor)

Resistance seriesResistance

The resistance of the fixed-value series resistor in your voltage divider circuit

double betaCoefficient

The beta coefficient of the thermistor used in the Steinhart-Hart equation

SteinhartHartCalculatedThermistor(IAnalogInputPort, Resistance, double)

Creates a new SteinhartHartCalculatedThermistor object using the provided analog input and the thermistor's nominal resistance (i.e. 10kOhm) and the fixed resistor value of the voltage divider circuit.

Declaration
public SteinhartHartCalculatedThermistor(IAnalogInputPort analogInput, Resistance nominalResistance, double betaCoefficient)

Parameters

Type Name Description
IAnalogInputPort analogInput

The analog input reading the thermistor voltage divider output

Resistance nominalResistance

The nominal resistance of the thermistor (e.g. 10kOhm for a 10k thermistor)

double betaCoefficient

The beta coefficient of the thermistor used in the Steinhart-Hart equation

Remarks

The fixed resistor value will be assumed to match the thermistor's nominal resistance

Fields

DefaultBetaCoefficient

The common default beta coefficient (3950) for many thermistors

Declaration
public const double DefaultBetaCoefficient = 3950

Field Value

Type Description
double

Properties

BetaCoefficient

Gets the beta coefficient of the thermistor used in the Steinhart-Hart equation

Declaration
public double BetaCoefficient { get; }

Property Value

Type Description
double

NominalResistance

Gets the nominal resistance of the thermistor (e.g. 10kOhm for a 10k thermistor)

Declaration
public override Resistance NominalResistance { get; }

Property Value

Type Description
Resistance

Overrides

SeriesResistance

Gets the resistance of the fixed-value series resistor in your voltage divider circuit

Declaration
public Resistance SeriesResistance { get; }

Property Value

Type Description
Resistance

Methods

ReadSensor()

Update the Temperature property

Declaration
protected override Task<Temperature> ReadSensor()

Returns

Type Description
Task<Temperature>

Overrides