how to indentify finger is on the camera lens or not in android?

Please check This Post on Google Code

http://code.google.com/p/android-heart-rate-monitor/issues/detail?id=1#c22

It Explains how to check finger is on the camera or not.

"For anyone interested, I figured out how to detect whether the user has his finger placed on the camera or not. In the imageProcessing.java, in the decodeYUV420SPtoRedAvg() method, we calculate the average value of the pixels of the red color. Doing a small experiment, I found out that when the user has his finger placed on the camera lens, the average has a value of > 200. In other cases, the average value is <200. thus, in the HeartRateActivity you can add an if statement after the call of the decodeYUV420SPtoRedAvg(), to find whether the value returned is >200 or < 199. You can use this to display an alert box or something similar to guide the user to place his finger on the camera lens."