Active Topics

 


Reply
Thread Tools
zwiik's Avatar
Posts: 41 | Thanked: 14 times | Joined on Jul 2010
#1
hey
i have been tryin to get myself started with QTMovility sensors qsensors
qacclerometer especially
the following
Code:
QAccelerometer *sensor = new QAccelerometer(this);
    sensor->start();

       QAccelerometerReading *reading = sensor->reading();
       qreal x = reading->x();
       qreal y = reading->y();
       QString res="";

       ui->lineEdit->setText(res.number(reading->x(),'g',3));
gives me
"0" as the reading all the time no matter how i hold the phone
this code is part of a slot which activates when i click a pushbutton
__________________
zwiik kkaran
CGPA Calculator
 
Posts: 20 | Thanked: 11 times | Joined on Feb 2010
#2
Check out this, it may be your case:


http://bugreports.qt.nokia.com/browse/QTMOBILITY-326
 

The Following User Says Thank You to saveas For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 15:37.