ELECTRO MOTIF
Published

Capacitive Touch Control Panel using Arduino Nano

A low-cost Arduino Nano based capacitive touch panel that replaces physical buttons with touch-sensitive controls.

BeginnerFull instructions provided1 hour134
Capacitive Touch Control Panel using Arduino Nano

Things used in this project

Hardware components

LED (generic)
LED (generic)
×3
Arduino Nano R3
Arduino Nano R3
×1
USB Cable, Mini USB Type B Plug
USB Cable, Mini USB Type B Plug
×1
Resistor 1M ohm
Resistor 1M ohm
×3
Jumper wires (generic)
Jumper wires (generic)
×1
Capacitor 100 nF
Capacitor 100 nF
×3

Software apps and online services

Arduino IDE
Arduino IDE

Story

Read more

Schematics

Main Project Image 1

Complete capacitive touch control panel using Arduino Nano with 3 touch inputs and LED outputs.

Main Project Image 2

Complete capacitive touch control panel using Arduino Nano with 3 touch inputs and LED outputs.

Main Project Image 3

Complete capacitive touch control panel using Arduino Nano with 3 touch inputs and LED outputs.

Main Project Image 4

Complete capacitive touch control panel using Arduino Nano with 3 touch inputs and LED outputs.

Code

Capacitive_Touch_Pannel.ino

C/C++
Arduino Nano based capacitive touch control system with 3 touch inputs to control LEDs. Uses CapacitiveSensor library to detect human touch without mechanical buttons.
#include <CapacitiveSensor.h>

// Touch sensors
CapacitiveSensor touch1 = CapacitiveSensor(4, 2);
CapacitiveSensor touch2 = CapacitiveSensor(4, 3);
CapacitiveSensor touch3 = CapacitiveSensor(4, 5);

// LED pins
int led1 = A1;
int led2 = A4;
int led3 = 13;

void setup() {
  Serial.begin(9600);

  pinMode(led1, OUTPUT);
  pinMode(led2, OUTPUT);
  pinMode(led3, OUTPUT);
}

void loop() {
  long val1 = touch1.capacitiveSensor(30);
  long val2 = touch2.capacitiveSensor(30);
  long val3 = touch3.capacitiveSensor(30);

  // Debug values
  Serial.print("T1: "); Serial.print(val1);
  Serial.print("  T2: "); Serial.print(val2);
  Serial.print("  T3: "); Serial.println(val3);

  // Touch logic
  digitalWrite(led1, val1 > 1000 ? HIGH : LOW);
  digitalWrite(led2, val2 > 1000 ? HIGH : LOW);
  digitalWrite(led3, val3 > 1000 ? HIGH : LOW);

  delay(100);
}

Credits

ELECTRO MOTIF
4 projects • 0 followers
Electronics enthusiast focused on PCB design, power electronics, and embedded hardware. I design circuits and share hardware projects.

Comments