Description:
This touch sensor module offers a convenient replacement for traditional direct switch keys by providing stable detection of human touch. Its response time at low power mode is typically 220mS at a voltage of 3V, with an adjustable sensitivity of up to 50pF capacitance outside. The module operates on a voltage range of 2.0V to 5.5V and provides low power mode for energy efficiency. It offers multiple output modes, including direct mode and toggle mode, with the option to select active high or active low through pad options. The module features an auto-calibration function for life and a re-calibration period of about 4.0sec in low power mode. After power-on, it requires approximately 0.5sec of stable time before use. However, its stability may not be as reliable as some other models, such as the TTP223-BA6. Additionally, the auto-recalibration will be redone after about 16sec from releasing the key, making it a convenient option for various applications.
Package Includes:
- 1 x TTP223 Touch Sensor Module
Features:
- Operating voltage range of 2.0V to 5.5V
- Operating current at VDD = 3V, with no load
- Low power mode with a typical current draw of 1.5uA and maximum current draw of 3.0uA
- Response time of a maximum of 220mS in low power mode @VDD=3V
- Adjustable sensitivity with a capacitance range of 0~50pF outside
- Stable touch detection of the human body, offering a reliable replacement for traditional direct switch keys
- Low power mode for energy efficiency
- Provides direct mode and toggle mode through the TOG pin with a CMOS output through the Q pin
- All output modes can be selected as active high or active low through the AHLB pin
- After power-on, the module requires approximately 0.5 sec of stable time before use. During this time, the keypad should not be touched, as the function is disabled.
- Auto-calibration function for life
- Re-calibration period of about 4.0sec in low power mode
- Auto re-calibration occurs about 16sec after releasing the key
- The sensitivity of TTP223N-BA6 is better than TTP223-BA6's, but the stability of TTP223N-BA6 is worse than TTP223-BA6's.
Â
Circuit:
Example Arduino code for using the TTP223 touch sensor with Arduino connected to pin 3:
Connections:
- VCC to Arduino 5V
- GND to Arduino GND
- SIG to Arduino digital pin 3
First, we define the input pin for the touch sensor, which is connected to Arduino's digital pin 3. We also define a variable "state" to keep track of the current state of the touch sensor. In the setup function, we initialize the serial communication at a baud rate of 9600 and set the input pin as an INPUT_PULLUP. In the loop function, we read the state of the input pin and compare it to the previous state. If the current state is different from the previous state, we update the "state" variable and print the new state to the serial monitor. If the "state" variable is HIGH, we turn on an LED connected to digital pin 13. If the "state" variable is LOW, we turn off the LED.
Â
// define the TTP223 touch sensor pin
const int touchPin = 3;
void setup() {
// initialize serial communication for debugging
Serial.begin(9600);
// set the touch sensor pin as input
pinMode(touchPin, INPUT);
}
void loop() {
// read the touch sensor state
int touchState = digitalRead(touchPin);
// check if the touch sensor is touched
if (touchState == HIGH) {
// print a message to the serial monitor
Serial.println("Touch detected");
}
// wait a short time before checking again
delay(50);
}