×

Discussion Board

Results 1 to 6 of 6

Thread: QSensor problem

  1. #1
    Registered User
    Join Date
    Nov 2009
    Posts
    6

    QSensor problem

    Hi! I'm trying to do an app with Qt Mobility libs and new Qt Nokia SDK.

    I've this in .pro:
    ...
    CONFIG += mobility
    MOBILITY = sensors

    symbian {
    TARGET.UID3 = 0xe27aa5b4
    TARGET.CAPABILITY += Location \
    NetworkServices \
    LocalServices \
    ReadUserData \
    WriteUserData \
    UserEnvironment \
    ReadDeviceData \
    WriteDeviceData
    ...
    //.cpp
    ...
    Sensors::Sensors(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::Sensors),acc(0)
    {
    ui->setupUi(this);
    acc = new QSensor("QAccelerometer");

    acc->setIdentifier("sym.accelerometer");
    acc->addFilter(this);
    acc->start();
    }
    ...

    Then it gives to me that errors:
    undefined reference to 'QtMobility::QSensor::QSensor(QByteArray const&......
    undefined reference to 'QtMobility::QSensor::setIdentifier(QByteArray.......
    .....
    .....
    .....

    Thanks!

  2. #2
    Super Contributor
    Join Date
    Oct 2008
    Location
    INDIA
    Posts
    2,326

    Re: QSensor problem

    Hi, Nanokun

    Just little change :
    Try to add this in your .pro file.
    Code:
    MOBILITY += sensors
    I think you missed + sign there.

    Best regards,
    RaHuL

  3. #3
    Registered User
    Join Date
    Nov 2009
    Posts
    6

    Re: QSensor problem

    nop, I've the same problem......

    thanks anyway!

  4. #4
    Registered User
    Join Date
    Apr 2009
    Posts
    32

    Re: QSensor problem

    Sorry guys - it probably this bug: http://bugreports.qt.nokia.com/browse/QTSDK-98

  5. #5
    Registered User
    Join Date
    Oct 2008
    Posts
    6

    Re: QSensor problem

    Even after updating the SDK today (25/7/10), still facing the same issue..
    I was able to compile by hacking the mmp accel_0xE68119a1.
    Add this to mmp
    LIBRARY qtsensors.lib
    And rebuild the project !

  6. #6
    Registered User
    Join Date
    Apr 2009
    Posts
    32

    Re: QSensor problem

    Please clean up your project completly. Even the C:\NokiaQtSDK\Symbian\SDK\epoc32\BUILD directory and then try it again.

    Sorry for the late answer.

Similar Threads

  1. error: 'QSensor' was not declared in this scope
    By mextil in forum [Archived] Qt Mobility Project
    Replies: 5
    Last Post: 2011-08-03, 14:52
  2. QSensor failing to connect to Backend
    By sweedyar in forum [Archived] Qt Mobility Project
    Replies: 4
    Last Post: 2010-06-20, 23:30
  3. Running QSensor examples using Nokia Qt SDK RC for Symbian device
    By sweedyar in forum [Archived] Qt SDKs and Tools
    Replies: 2
    Last Post: 2010-06-20, 12:07
  4. QSensor compilation problem
    By alenon in forum [Archived] Qt Mobility Project
    Replies: 2
    Last Post: 2010-05-21, 11:47

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •