There are two kinds, but I’ll explain capacitive touch because it’s cooler and easier to use. There are electrons being rapidly pumped into and out of a bunch of transparent wires on your screen. When something comes near the screen, it makes it easier for these electrons to move into the screen since they’re attracted to the something. The computer senses this easier movement, and knows there is something there. If the movement is too easy, it’s probably just a piece of metal. If the movement is too hard then there’s probably nothing there or something with a lot of resistance (not a finger).
Latest Answers