Roman wrote:
> You are missing in the onResume method
> 
> super.onResume();

Not to mention the fact that, since the OP is doing all the TextView
updates in a tight loop, only the last one will wind up having a visual
impact.

>>  What I really want to do is to get the sound level in the mic while
>> the program is running, I have the code for that but I don't know how
>> to make it check the sound level periodically.

Option #1: Do it when the user tells you to do it, via a button push or
something.

Option #2: Think long and hard about going with option #1.

Option #3: Use postDelayed() on some widget to set up a periodic task.

Option #4: Honestly, particularly for tying up and listening on a
microphone, I would think the users would want to control the timing of
it, so option #1 really should be the answer.

Option #5: Use TimerTask, as per regular Java.

Option #6: Fork a thread that uses SystemClock.sleep() and a Handler.

Option #7: Use AsyncTask, where you sleep() for a bit in
doInBackground() and check the mic/schedule the next task in
onPostExecute().

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android App Developer Training: http://commonsware.com/training.html

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to android-beginners@googlegroups.com
To unsubscribe from this group, send email to
android-beginners-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to