Haven is for people who need a way to protect their personal spaces and possessions without compromising their own privacy, through an Android app and on-device sensors
quick clean-up of logging on micsamplertask
n8fr82870d2b559cc
diff --git a/src/main/java/org/havenapp/main/sensors/media/MicSamplerTask.java b/src/main/java/org/havenapp/main/sensors/media/MicSamplerTask.javaindex ba01ae9..934a4d8 100644--- a/src/main/java/org/havenapp/main/sensors/media/MicSamplerTask.java+++ b/src/main/java/org/havenapp/main/sensors/media/MicSamplerTask.java@@ -52,14 +52,13 @@ public class MicSamplerTask extends AsyncTask<Void,Object,Void> {while (true) {if (listener != null) {- Log.i("MicSamplerTask", "Requesting amplitude");+ Log.d("MicSamplerTask", "Requesting amplitude");publishProgress(volumeMeter.getAmplitude());}try {Thread.sleep(250);} catch (InterruptedException e) {- //Nothing to do we exit next line-+ //Nothing to do we exit next line}boolean restartVolumeMeter = false;@@ -72,22 +71,19 @@ public class MicSamplerTask extends AsyncTask<Void,Object,Void> {try {Thread.sleep(500);} catch (InterruptedException e) {- // TODO Auto-generated catch block- e.printStackTrace();+ //Nothing to do we exit next line}}if (restartVolumeMeter) {try {- Log.i("MicSamplerTask", "Task restarted");+ Log.d("MicSamplerTask", "Task restarted");volumeMeter = new AudioCodec();volumeMeter.start();sampling = true;} catch (IllegalStateException e) {- // TODO Auto-generated catch block- e.printStackTrace();+ Log.d("MicSamplerTask","Failed to start",e);} catch (IOException e) {- // TODO Auto-generated catch block- e.printStackTrace();+ Log.d("MicSamplerTask","Failed to start",e);}}if (isCancelled()) { volumeMeter.stop(); sampling = false; return null; }