Friday, February 16, 2018

Arduino Bluetooth (BLE) Robot Buggy with L298 (Android example) 

Use you Mobile Phone to control the ESP32 Arduino Robot


Bought one of the cheap Arduino Robot Car Kits from aliexpress (scroll at

Using the ESP32 with four GPIO Pins (18,19,22,23) to the four Inputs of the L298 Module:

ESP32 and L298
The L298 is a dual full-bridge driver and a datasheet can be found here 

L298 Module

3V-6V Motor with gears

Than wrote the Arduino software using the BLE_UART example based on Neil Kolban example for IDF ( This is based on NUS (Nordic UART Service) to provide a defined BLE Service with two Characteristics and known UUIDs. 

#define SERVICE_UUID           "6E400001-B5A3-F393-E0A9-E50E24DCCA9E" 
#define CHARACTERISTIC_UUID_RX "6E400002-B5A3-F393-E0A9-E50E24DCCA9E"
#define CHARACTERISTIC_UUID_TX "6E400003-B5A3-F393-E0A9-E50E24DCCA9E"

Bluetooth Low Energy Server

To send BLE commands I use the Android App nRF Toolbox from Nordic Semiconductor (
nRF Toolbox for Android

And define the keys for the commands "up","down","left","right" by pressing EDIT and after configuration press DONE.

nRF Toolbox by Nordic Semiconductor
Don't forget to enable Bluetooth on your Phone.

ESP32 Arduino BLE Robot Buggy

See the Robot car in action: