Android/TimeLapsePhotoApp

private Runnable timerUpdateTask = new Runnable { public void run { if (currentTime < SECONDS_BETWEEN_PHOTOS) { currentTime++; } else { camera.takePicture(null,null,null,TimelapseSnapShot.this); currentTime = 0; } timerUpdateHandler.postDelayed(timerUpdateTask, 1000); countdownTextView.setText(""+currentTime); } };