How to determine what touched the screen of my Android device?

I want to say that I want to know what has touched the screen of my Android device? As if the FINGERS touched the screen, he would know that it was a finger, if the ball, pencil, notebook or something, he knew that it was not FINGERS.

How does a touchscreen determine what touches it? because I want to develop a FINGERPRINT SCANNER. which method am i using? is there an android function that determines that a thing has touched the screen?

Thanks.

I canโ€™t explain it, but I hope you have an idea.

+6
source share
4 answers

there were no sensors on the screen of your devices to determine the type of touch.

+1
source

Touch screens do not determine what affects them.

In the case of resistive touch screens, they come solely due to the pressure of pressing the tool. (They are a bit dated, and I don't know any Android devices that use this type of touch screen.)

capacitive touchscreens , as you might have guessed, use capacitors and electric currents to determine when they touch. Since the skin of the human body is a conductor, it signals that the screen has been touched. However, they develop styluses that are also favorable, so they also install it. However, the screen does not know the difference between the two; they are just conductors of electricity.

You cannot determine the exact shape of the fingerprint using the touch screen technology on smartphones. You can determine the touch pressure , major and minor axis of the ellipse, representing the area of โ€‹โ€‹contact, or the approximate size by touch. Nothing more.

0
source

You can do this quite easily with API 14:

myView.setOnTouchListener(new Button.OnTouchListener() { @Override public boolean onTouch(View v, MotionEvent arg1) { if (arg1.getAction() == android.view.MotionEvent.ACTION_DOWN && (MotionEvent.TOOL_TYPE_FINGER == arg1.getToolType(0)) { Toast.makeText(this, "You touched me with your finger!", Toast.LENGTH_LONG).show(); } return true; } }); 

It really only tells you that touch input has been introduced, but is different from styluses and mouse pointers. Most devices use thermal detection for touch input, but some devices there were designed to simulate finger input. Ex. Gloves SmartPhone, iPad Stylus

0
source

Unfortunately, our touch screen technology, used today on phones, has not advanced. Of course, I would like to create an application for unlocking biometric protection on Android, too;)

0
source

Source: https://habr.com/ru/post/919089/


All Articles