Table of Contents

Class Ms5611

Namespace
Iot.Device.Ms5611
Assembly
Iot.Device.Ms5611.dll

MS5611/GY-63 - Temperature and pressure sensor

[Interface("MS5611/GY-63 - temperature and pressure sensor")]
public class Ms5611
Inheritance
Ms5611

Constructors

Ms5611(I2cDevice, Sampling)

Constructs MS5611 instance

public Ms5611(I2cDevice i2cDevice, Sampling sampling = Sampling.HighResolution)

Parameters

i2cDevice I2cDevice

I2C device used to communicate with the device

sampling Sampling

Sampling resolution

Fields

AlternativeI2cAddress

Alternative I2C address

public const byte AlternativeI2cAddress = 118

Field Value

byte

DefaultI2cAddress

Default I2C address

public const byte DefaultI2cAddress = 119

Field Value

byte

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

ReadPressure()

Reads the pressure from the sensor

[Telemetry("Pressure")]
public Pressure ReadPressure()

Returns

Pressure

Atmospheric pressure

ReadSeaLevelPressure(Length)

Calculates the pressure at sea level when given a known altitude

public Pressure ReadSeaLevelPressure(Length altitude)

Parameters

altitude Length

Altitude in meters

Returns

Pressure

Pressure

ReadTemperature()

Reads the temperature from the sensor

[Telemetry("Temperature")]
public Temperature ReadTemperature()

Returns

Temperature

Temperature in degrees celsius

SetSampling(Sampling)

Sets sampling to the given value

public void SetSampling(Sampling sampling)

Parameters

sampling Sampling

Sampling resolution