JFrog, Thanks a ton for that reply. I will try not using a background service, the way you mentioned. Let me see how that goes and post something quick back here.
Thanks again. Abhi On Jan 29, 8:49 am, JFrog <jeremiah.paul.sna...@gmail.com> wrote: > Hey Abhi, > > If what I've understood about dealing with the sensors right now, you > don't need to start abackgroundservice. You can simply access the > accelerometer values through the following: > SensorManager myManager; > List <Sensor> sensors[ ]; > myManager = (SensorManager)getSystemService(Context.SENSOR_SERVICE); > sensors = myManager.getSensorList(Sensor.TYPE_ACCELEROMETER); > Then within your program you can go off of the trigger for a user's > tap on the screen (I don't know this off-hand). When the user clicks > again, another trigger should fire. The code that you might want > accomplished could be handled within these triggers without having to > affect your current code in the Activity. This will handle things > for > you during your activity. Of course if you are specifically trying > to > get somebackgroundexperience and feedback, at least I can get a > small discussion started possibly for you. > > ~ JFrog > "Debugging something is twice as difficult as coding something the > first time. Therefore, if we make the code as clever as possible, we > are by definition not smart enough to debug it". -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en