Help with (fairly simple?) application


Last Updated:

  1. Copaman

    Copaman New Member This Topic's Starter

    Joined:
    Jun 5, 2010
    Messages:
    4
    Likes Received:
    0
    Hey guys.

    I'm currently working on an application for a course I'm taking. It's due on the 14th, when I will have to somehow demonstrate it to a panel of engineers at my school.

    Please understand that I have very little Java experience.

    at the moment, my program uses getSpeed() to get the speed of the handset. It then displays the speed of the handset, and the maximum speed the handset has gone since the program started.

    I need the program to enable or disable Airplane Mode if mySpeed [gotten by getSpeed()] is above or below a certain value (limitSpeed, set arbitrarily by me).

    I was thinking something like:

    Code (Text):
    1. if(mySpeed>=limitSpeed){
    2. //long mess of programming here to enable Airplane Mode
    3. }
    4.  
    5. if(mySpeed<limitSpeed){
    6. //long mess of programming to disable Airplane Mode
    7. }
    How can I do this? If the above method will work, how do I get it to work? If it won't, what should I do instead?

    Thanks

    Copa
     

    Advertisement
  2. mkeath

    mkeath Well-Known Member

    Joined:
    May 14, 2010
    Messages:
    209
    Likes Received:
    15

Share This Page

Loading...