p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional Android Application Development ISBN: 978-0-470-34471-2
This is the forum to discuss the Wrox book Professional Android Application Development by Reto Meier; ISBN: 9780470344712

Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional Android Application Development ISBN: 978-0-470-34471-2 section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 12th, 2009, 08:46 PM
Registered User
Points: 11, Level: 1
Points: 11, Level: 1 Points: 11, Level: 1 Points: 11, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default speedometer

Hi,

I am reading the chapter about work with sensors, and I tried to run the app Speedometer but seems like it is not working,

I tried to change the time of update of this part of code as well,

PHP Code:
 Timer updateTimer = new Timer("velocityUpdate");
      
updateTimer.scheduleAtFixedRate(new TimerTask() {
        public 
void run() {
          
updateGUI();
        }
      }, 
010); 
here is the thing: I am triying to use this example to know when my cellphone is falling down or , when I move my cellphone quickly with my hands,

any idea?

best,
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #2 (permalink)  
Old August 12th, 2009, 10:04 PM
Registered User
Points: 11, Level: 1
Points: 11, Level: 1 Points: 11, Level: 1 Points: 11, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I think I am learning why is not working, my first idea is because mytextview is not been updating, so I check the code with a toast and:

PHP Code:
Context context getApplicationContext();
      
      
Toast toast Toast.makeText(contextString.valueOf(currentAcceleration), );
      
toast.show(); 
and is working, the first values are between 9.8-9.9 and I thought that was because is the gravity force, I think will be very interesting if you can explain a little bit more about:

calibration
and why the example is not working 100%, cuold be a configuration of the phone?

best,
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 7 Speedometer SensorSimulator JHandal BOOK: Professional Android Application Development ISBN: 978-0-470-34471-2 0 April 16th, 2009 03:42 PM



All times are GMT -4. The time now is 10:59 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc