Most cheap styluses are capacitive meaning they can conduct a weak electrical current. Those are both cheap and easy to make and essentially function just as a finger.
If you want one like apple or Samsung those are not simple capacitive styluses. They’re actually fairly complex and incorporate small circuit boards which include position sensors as well as pressure sensors. Making one would be very difficult and making one that works as well as apples or Samsungs would be pretty much impossible as a regular person
Latest Answers