6
Connect the six touch points
A0-A5
of the
FruitKey
to
5V
of Mars with a
1M pull-up resistor
between each. If there is no touch, A0-A5 are High level by default (that is, the default value of
A0-A5 is 1023). Since each of the six points is connected to a
0.1
μ
F ceramic capacitor
respectively, when you touch the GND and one or two of A0-A5, the corresponding capacitor
will discharge, and the input voltage will be reduced, thus the input
AD value
. Once the AD
value decreases to the threshold, it can be considered that the corresponding touching pad
has been triggered. Besides, we can connect six
LEDs
to digital pin6-pin11 as the signal
indicators for A0-A5 separately.
SunFounder