Brain-Controlled Car: EEG + EMG Robotic Control

by Upside Down Labs in Circuits > Sensors

6076 Views, 23 Favorites, 0 Comments

Brain-Controlled Car: EEG + EMG Robotic Control

Brain-Controlled Car EEG + EMG Robotic Control Instructable(1).gif

Ever dreamed of driving a car with your brain signals alone?

This project makes it possible - using EEG (brainwave) and EMG (muscle) signals to control a robotic car wirelessly via Bluetooth Low Energy (BLE).

What is an Electroencephalography (EEG)?

Electroencephalography (EEG) is a method used to record an electrogram of the brain's spontaneous electrical activity. It is typically non-invasive, with electrodes placed along the scalp (commonly referred to as "scalp EEG") using the International 10–20 system.

What is an Electromyography (EMG)?

Electromyography (EMG) is a diagnostic and research technique that records the electrical signals generated by muscles when they contract or are at rest.

Focus your mind → Move forward

Flex your left/right arm → Steer left/right

Flex both arms together → Move reverse

Powered by the NPG Lite Device

Neuro PlayGround (NPG) Lite is a compact Adafruit Feather form factor, a multi-channel wireless biopotential signal amplifier designed for EMG, ECG, EOG, and EEG recording.

It offers Wi-Fi, Bluetooth, Zigbee, and Thread connectivity, along with patient protection, LEDs (User LED, charging LED, six addressable RGB LEDs), buttons (Reset and user button), LiPo battery charging, and USB-C with ESD protection. Its lightweight and user-friendly design makes it perfect for research, education, and wearable applications.

Neuro PlayGround Lite is available on Tindie.

Watch the complete tutorial for this project on YouTube

This project is made by Aman Maheshwari and Deepak khatri

Supplies

BIOAMP EXG PILL.png
WhatsApp Image 2025-08-23 at 4.18.44 PM.jpeg

1. Bio-potential acquisition setup

  1. NPG Lite
  2. Snap cables + electrodes (or alligator clips)
  3. Nuprep + alcohol wipes
  4. USB-C cable


2. Car Components

  1. Robotic chassis (e.g., VoidBot)
  2. 2 × geared DC motors (6V–12V)
  3. Motor driver: MX1508/ MX1616
  4. XIAO ESP32C6 board (receiver)
  5. LiPo battery
  6. Slide switch


3. Miscellaneous Tools

  1. Soldering iron + wires
  2. Screwdriver
  3. Laptop with Arduino IDE

Hardware Assembly

Brain-Controlled Car EEG + EMG Robotic Control Instructable(2).gif
Brain-Controlled Car EEG + EMG Robotic Control Instructable.00_00_05_30.Still002.jpg

A. Build the Robotic Car

  1. Watch this video for step-by-step guidance (only up to 5 minutes).
  2. After 5 minutes, follow the circuit diagram below for wiring and connections.
  3. Mount the DC motors to the chassis.


Motor Driver Connection

Motor driver.png
  1. Connect motors to the driver: Motor A → Left wheel, Motor B → Right wheel.
  2. Provide power to the motor driver MX1508/ MX1616
  3. Wire the motor driver inputs to the XIAO ESP32C6 receiver pins.

Motor Driver to XIAO Board Connection

Main Connection Diagram.png
  1. Wire the motor driver inputs to the XIAO ESP32C6 receiver pins.
  2. Secure all wiring and components to the chassis like this and the final setup should look like this.

Connecting NPG Lite

NPG brain Control car instructable diagram.png
Brain-Controlled Car EEG + EMG Robotic Control Instructable(3).gif

Connect the snap cables to your Neuro PlayGround Lite device.

Skin Preparation

Brain-Controlled Car EEG + EMG Robotic Control Instructable.00_00_05_56.Still003.jpg
  1. Clean the electrode placement areas with an alcohol swab or wet wipe.
  2. For even better signal quality, you can optionally apply a small amount of Nuprep Skin Preparation Gel before cleaning the skin.
  3. Allow the skin to dry before placing the electrodes.
  4. Proper skin preparation removes oils and dead skin cells, improving electrode contact and signal quality.

Wearable Setup

NPG brain Control car instructable diagram.png
Brain-Controlled Car EEG + EMG Robotic Control Instructable(4).gif
Electrode Placement
Electrode Placement Signal Type
A0P Center Forehead EEG
A0N Behind Right Ear EEG
A1P/A1N Left Arm (biceps) EMG
A2P/A2N Right Arm (biceps) EMG
REF Behind Left Ear Ground

Pro Tips:

Clean skin with alcohol wipes before applying electrodes for better signal quality


Install ESP32 Board

Focus(2).jpg

Install the following board in Arduino IDE

  1. Install board manager: ESP32.

Tools → Board Manager → search for esp32 → Install esp32 by Espressif Systems(version - 3.2.0 compulsary).

Install Adafruit NeoPixel Library

Focus(1).jpg

Install the following library in Arduino IDE

  1. Install library: Adafruit NeoPixel.

Sketch → Include libraries → Manage libraries → Search for Adafruit NeoPixel → Install Adafruit NeoPixel

Upload the Code

Brain-Controlled Car EEG + EMG Robotic Control Instructable(2).png
Brain-Controlled Car EEG + EMG Robotic Control Instructable(8).png
Brain-Controlled Car EEG + EMG Robotic Control Instructable(5).png
Brain-Controlled Car EEG + EMG Robotic Control Instructable(9).png

Turn ON the NPG Lite device, connect it to your Laptop with a Type-C cable, and then follow the steps below:

A. NPG Lite Device

  1. Select board: ESP32C6 Dev Module.

Tools → Board → esp32c6 esp32c6 Dev Module.

  1. Enable CDC On Boot in the Tools menu.

Tools → USB CDC ON BOOT "ENABLED".

  1. Upload BLE-BCI-Car-Remote.ino.
  2. Calibrate EEG using Serial Monitor - adjust BETA_THRESHOLD if needed (Set a value slightly above your relaxed state as the threshold)
  3. Now connect the XIAO board to your laptop using the USB-C cable attached to the car, and launch the Arduino IDE.
  4. Re-upload the firmware


B. XIAO ESP32C6 (Receiver Car)

  1. Select XIAO ESP32C6 in Arduino IDE.
  2. Upload BLE-BCI-Car.ino.

Set the Beta Threshold Value

21.png
22.png
23.png
24.png
  1. Open the Serial Monitor and observe the values. If no values appear, type Debug in the Serial Monitor's command box and press Enter.
  2. Observe the beta-wave percentage while staying focused (default threshold is 2%).
  3. Set a value slightly above your relaxed state as the threshold.
  4. After calibration is done.
  5. It is now time to reflash it, and after flashing, you can disconnect the USB-C cable.

NPG Lite will handle everything wirelessly from here.

Run

Follow these steps to run the car :

  1. Power the car and NPG Lite.
  2. Focus your mind → Car moves forward.
  3. Flex left/right arm → Steering control.
  4. Flex both arms together → Car moves reverse.


Applications

  1. Neurotechnology research
  2. Accessibility devices
  3. Human-computer interaction experiments

Video Tutorial

Controlling a car with Brain and Muscle signals using NPG Lite || Detailed tutorial with codes!

The full step-by-step tutorial for this project is available on our YouTube channel, where we explain every step in detail—from hardware setup and wiring to programming and testing.