QPressureReading Class

The QPressureReading class holds readings from the pressure sensor. 更多...

头文件: #include <QPressureReading>
qmake: QT += sensors
开始支持版本: Qt 5.1
基类: QSensorReading

属性

公有函数

qreal pressure() const
void setPressure(qreal pressure)
void setTemperature(qreal temperature)
qreal temperature() const

其他继承的成员

  • 1 个公有槽函数继承自 QObject
  • 2 个信号继承自 QObject
  • 1 个公有变量继承自 QObject
  • 10 个静态公有成员继承自 QObject
  • 9 个受保护的函数继承自 QObject
  • 2 个受保护的变量继承自 QObject

详细描述

The QPressureReading class holds readings from the pressure sensor.

QPressureReading Units

The pressure sensor returns atmospheric pressure values in Pascals.

属性

pressure : const qreal

This property holds the measured atmospheric pressure.

Returned as Pascals.

访问函数:

qreal pressure() const

参见 QPressureReading Units.

temperature : const qreal

This property holds the pressure sensor's temperature.

The temperature is returned in degree Celsius. This property, if supported, provides the pressure sensor die temperature. Note that this temperature may be (and usually is) different than the temperature reported from QAmbientTemperatureSensor. Use QSensor::isFeatureSupported() with the QSensor::PressureSensorTemperature flag to determine its availability.

This property was introduced in Qt 5.2.

访问函数:

qreal temperature() const

成员函数

void QPressureReading::setPressure(qreal pressure)

Sets the pressure to pressure.

参见 pressure().

void QPressureReading::setTemperature(qreal temperature)

Sets the pressure sensor's temperature to temperature.

This function was introduced in Qt 5.2.

参见 temperature().