Пример #1
0
void meegoals::slotDataAvailable(const Unsigned& data)
{
    QAmbientLightReading::LightLevel level = getLightLevel(data.x());
    if (level != m_reading.lightLevel()) {
        m_reading.setLightLevel(level);
        m_reading.setTimestamp(data.UnsignedData().timestamp_);
        newReadingAvailable();
    }
}
void SensorfwProximitySensor::slotDataAvailable(const Unsigned& data)
{
    bool close = data.x()? true: false;
    if (close == m_exClose) return;
    m_reading.setClose(close);
    m_reading.setTimestamp(data.UnsignedData().timestamp_);
    newReadingAvailable();
    m_exClose = close;
}
void SensorfwLightSensor::slotDataAvailable(const Unsigned& data)
{
    m_reading.setLux(data.x());
    m_reading.setTimestamp(data.UnsignedData().timestamp_);
    newReadingAvailable();
}
Пример #4
0
void SensorfwOrientationSensor::slotDataAvailable(const Unsigned& data)
{
    m_reading.setOrientation(SensorfwOrientationSensor::getOrientation(data.x()));
    m_reading.setTimestamp(data.UnsignedData().timestamp_);
    newReadingAvailable();
}