Realized by Alice Giordani

FastTouch Open Source Arduino Library for Fast, Portable, Low Fidelity Capacitive Sensing

The fast touch algorithm reimplemented in the library available here was developed for my FingerPhone Instrument. The fast touch library senses touch on any digital I/O pin on many embedded controllers with the Arduino IDE. This includes Atmega 8-bit, SAMD21, and Teensy. This includes most pins on most micro-controllers. A few micro controllers have analog input pins that can't also do digital I/O . The library relies on the ability to enable a built-in pull-up resistor on the pin being sensed. Here is the algorithm:
  • set the pin to output a LOW value for 1uS or so.
  • set the pin to output a high via a built-in pulp resistor.
  • Read the pin regularly and evenly while it reads a low value.
  • The sensed value is reported as a function of the time it takes for the pull-up to bring the pin to a high value. This depends on whether the pin is touched.

    The example code provided with the library uses the Arduino Tone library to sound pitches according to which pins are touched.

    Notice that each call to the fast touch library implements a cycle of a relaxation oscillator.

    I am indebted to Alice Giordani for exemplifying use of the library so well in this dreamcatcher:

  • Syndicate content