{"id":10826,"date":"2024-05-26T09:24:18","date_gmt":"2024-05-26T13:24:18","guid":{"rendered":"https:\/\/dronebotworkshop.com\/?p=10826"},"modified":"2024-05-26T09:24:18","modified_gmt":"2024-05-26T13:24:18","slug":"esp32-bluetooth","status":"publish","type":"post","link":"https:\/\/dronebotworkshop.com\/esp32-bluetooth\/","title":{"rendered":"Bluetooth Classic & BLE with ESP32"},"content":{"rendered":"\n

\"Download<\/a> \"View<\/a> \"Download<\/a><\/p>\n

Today, we will learn how to use the ESP32’s Bluetooth and BLE features to communicate with phones, tablets, sensors, and other ESP32 boards.\u00a0<\/span><\/p>\n

<\/div>\n

Introduction<\/span><\/h2>\n

In 1994, engineers Nils Rydbeck, Johan Ullman, and Dr. Jaap Haartsen at the Swedish technology company Ericsson conceived a method to replace the ever-expanding jungle of computer cables with a wireless system. Four years later, Ericsson partnered with IBM, Intel, Nokia, and Toshiba to form the <\/span>Bluetooth Special Interest Group (SIG).<\/span><\/a> One year later, in 1999, the specifications for Bluetooth 1.0 were released.<\/span><\/p>\n

\"\"<\/p>\n

Bluetooth (named after the 10th-century king Harald “Bluetooth” Gormsson, who united Denmark and Norway) was initially designed to replace RS-232 (serial) cables with a 2.4GHz wireless link. It has since been expanded to include audio streaming and direction finding.<\/span><\/p>\n

In 2010, Bluetooth Low Energy, or BLE, was introduced as part of the Bluetooth 4.0 specifications.\u00a0 This low-powered technology was designed for short data bursts like sensor data.\u00a0 BLE devices have very low power consumption, and the technology is used in items like smartwatches and fitness trackers.<\/span><\/p>\n

The Espressif ESP32 microcontroller is an ideal component for hobbyists who want to build Bluetooth and BLE projects. It\u2019s inexpensive, easy to use, and well-documented.\u00a0<\/span><\/p>\n

Today, we will see how easy it is to get started with Bluetooth on the ESP32.<\/span><\/p>\n

Bluetooth Classic & BLE<\/span><\/h2>\n

Both Bluetooth (now called <\/span>Bluetooth Classic<\/span><\/i>) and BLE (formerly known as <\/span>Bluetooth Smart<\/span><\/i>) use the 2.4 GHz ISM (Industrial\u2014Scientific\u2014Medical) band, which is available worldwide for non-licensed low-powered radio communications.<\/span><\/p>\n

Bluetooth (both flavors) is designed to communicate over short distances, making it ideal for connecting computers and mobile devices to peripherals.<\/span><\/p>\n

Similarities and Differences<\/span><\/h3>\n

The two protocols are used for different purposes:<\/span><\/p>\n