Skip to main content

Class SimulatedBarometricPressureSensor

A simulated barometric pressure sensor for testing and development purposes.

Assembly: Meadow.Foundation.dll​
View Source​
Declaration
public class SimulatedBarometricPressureSensor : SimulatedSamplingSensorBase<Pressure>, ISimulatedSensor, IBarometricPressureSensor, ISamplingSensor<Pressure>, ISensor<Pressure>, ISensor, ISamplingSensor

Inheritance: System.Object -> Meadow.Foundation.Sensors.SimulatedSensorBase -> Meadow.Foundation.Sensors.SimulatedSamplingSensorBase<UNIT>

Implements:
Meadow.Peripherals.Sensors.ISimulatedSensor, Meadow.Peripherals.Sensors.Atmospheric.IBarometricPressureSensor, Meadow.Peripherals.Sensors.ISamplingSensor<Meadow.Units.Pressure>, Meadow.Peripherals.Sensors.ISensor<Meadow.Units.Pressure>, Meadow.Peripherals.Sensors.ISensor, Meadow.Peripherals.Sensors.ISamplingSensor

Properties​

Pressure​

Gets the current pressure reading.

View Source​
Declaration
public Pressure? Pressure { get; }

ValueType​

Gets the type of value the sensor produces.

View Source​
Declaration
public override Type ValueType { get; }

Methods​

SetSensorValue(object)​

Sets the sensor value.

View Source​
Declaration
public override void SetSensorValue(object value)
Parameters​
TypeNameDescription
System.ObjectvalueThe value to set.

GenerateSimulatedValue(SimulationBehavior)​

Generates a simulated pressure value based on the specified behavior.

View Source​
Declaration
protected override Pressure GenerateSimulatedValue(SimulationBehavior behavior)
Returns​

Meadow.Units.Pressure: A simulated Meadow.Foundation.Sensors.SimulatedBarometricPressureSensor.Pressure value.

Parameters​
TypeNameDescription
Meadow.Peripherals.Sensors.SimulationBehaviorbehaviorThe simulation behavior to use.

Implements​

  • Meadow.Peripherals.Sensors.ISimulatedSensor
  • Meadow.Peripherals.Sensors.Atmospheric.IBarometricPressureSensor
  • Meadow.Peripherals.Sensors.ISamplingSensor<Meadow.Units.Pressure>
  • Meadow.Peripherals.Sensors.ISensor<Meadow.Units.Pressure>
  • Meadow.Peripherals.Sensors.ISensor
  • Meadow.Peripherals.Sensors.ISamplingSensor