Experiment 6 - Capacitive Sensors II

In this experiment you are going to learn how you finger is influencing the capacitance of capacitive touch sensors, how touch sensors detect a change in capacitance and how this can be implemented in hard- and software.

Material

  • aluminum foil
  • multimeter which is able to measure capacitance in the range down to picofarad
  • wires and clips to connect the multimeter
  • sheet of paper (or other thin insulator)
  • oscilloscope
  • DFRobot touch sensor kit
  • Arduino Uno
  • USB A to USB B cable
  • Notebook with USB A port
  • Jumper kabels

Tasks 1

  1. Build two electrodes out of the aluminum foil, approximately as big as your hand.
  2. Attach the wires and clips to the multimeter and the electrodes
  3. Use capacitance mode of multimeter and watch the display
  4. Play around with area between electrodes and distance between electrodes (use sheet of paper as insulator between electrodes)
  5. Use only one electrode. Take the clamp of the unused electrode in one hand and slowly place your hand onto the other active electrode (use sheet of paper as insulator between electrode and hand)
  6. Attach the clamp in your hand to earth ground (e.g. at a power outlet, if you do → don't come in contact with the other contacts!!)
    → slowly place your hand onto the other active electrode (use sheet of paper as insulator between electrode and hand)
  7. Place your hand on the electrode with sheet of paper as insulator. Now compare the capacitance value on the multimeter with two situations (keep hand on electrode without moving)
    1. Take of your shoes off and place your feet on the ground 
    2. lift up your feet from the ground

Task 2

  1. Take the single touch key PCB of the DFRobot touch sensor kit
  2. Supply the PCB with voltage (5 V). For example from Arduino Uno pin header
  3. Try out at which distance the LED lights up
  4. Attach probe of oscilloscope two the wire which is soldered to the IC input pin and ground o PCB → Find settings suitable to observe oscillations → activate frequency measurement for that channel
  5. Slowly bring your finger towards the sensor electrode and watch the oscillations on the oscilloscope. How big is the frequency change between finger far away and finger very near to electrode?

Task 3

  1. You need the following parts
    1. Electrode matrix of DFRobot touch sensor kit
    2. Sensor PCB of DFRobot touch sensor kit
    3. Arduino Uno + USB cable
    4. Notebook with Arduino IDE installed
  2. Go to https://wiki.dfrobot.com/Capacitive_Touch_Kit_For_Arduino_SKU_DFR0129_
  3. Connect electrode matrix, sensor PCB and Arduino Uno as described in the link
  4. Download https://image.dfrobot.com/image/data/DFR0129/MPR121%20v1.0.zip and unzip
  5. Use touchpad example code in Arduino IDE from that folder
  6. Connect Arduino via USB to Notebook and compile and flash the microcontroller
  7. Open Serial console in Arduino IDE and choose correct BAUD rate (same as in code example)
  8. Play around with your finger on the touchpad matrix and watch console output
  9. Try to understand the code in the main .ino file.
    To understand the function calls CapaTouch.begin(), CapaTouch.getX() and CapaTouch.getY() go into the library files of the mpr121 (mpr121.h and mpr121.cpp) and try to understand the implementation

Institut für Mechatronik im Maschinenbau (iMEK), Eißendorfer Straße 38, 21073 Hamburg