ArduinoBLE V1.1.0 Adds BLE Central Support
Maybe your like
Arduino boards with a Bluetooth Low Energy (BLE) chipset can act as a “host” for other BLE devices. That’s because the ArduinoBLE library has added BLE Central support.
BLE Central vs. PeripheralLike most modern protocols, BLE devices fit into different roles: either central or peripheral. Central devices are typically something like a PC, Raspberry Pi, or smartphone. Peripherals tend to be smaller devices like a sensor, Bluetooth tag, or even a multimeter.
An advantage of supporting both roles is that an Arduino can now serve as a hub for other BLE devices.
ArduinoBLE Library v1.1.0In the past, the ArduinoBLE library only supported the peripheral role. With the new v1.1.0 release, BLE-enabled Arduino boards can act as a central device.
The latest batch of Arduino Nano 33 boards includes a u-blox NINA-W102 module. It supports WiFi, Bluetooth, and BLE. The updated ArduinoBLE library works with boards like the MKR WiFi 1010, Uno WiFi Rev 2, Nano 33 BLE, Nano 33 BLE Sense, and Nano 33 IoT.
The library is available through the web-based IDE on Arduino Create or in the Library Manager for the IDE.
Arduino Nano 33 BLE scanning for periphery devicesIn the above screenshot, the Central Scan example scans for BLE devices. As you can see, there are many in my area. However, why not add one more?
Two Arduino, One BLENow I have attached a second Nano 33 BLE and have programmed it to use the periphery role. The code is just the LED and LEDControl examples included with the ArduinoBLE library. The one change I made is it uses serial to control the remote LED. The control code checks for a ‘!’ character to turn on and a ‘@’ character to turn off. As you can see, the two BLE devices are communicating without the use of another host. (Well, other than power!)
Two Arduino Nano 33 BLE boards communicatingWith BLE Central support in the ArduinoBLE library, Arduino boards can now connect to peripheral devices and perhaps even act as a hub for IoT applications. For more information, check out the post by Sandeep Mistry on the Arduino blog, where he explains the considerable effort to bring BLE Central support to the Arduino ecosystem.
Tag » Arduino Ble Central And Peripheral
-
Simultaneous Central & Peripheral Roles On One Device?
-
How To Choose Central And Peripheral In BLE Communication?
-
ArduinoBLE - BLE.central() - Arduino Reference
-
BLE Central Support Added To ArduinoBLE | Arduino Blog
-
BLE Peripheral And Central At The Same Time - Arduino Forum
-
Nano 33 BLE Peripheral --> Central Comms - Arduino Forum
-
CurieBLE Library | Arduino Documentation
-
ArduinoBLE - Arduino Reference
-
Control LED Status Using BLE Peripheral And Central Devices On ...
-
BLE Peripheral Examples - GitHub Pages
-
ArduinoBLE/o At Master · Arduino-libraries ...
-
Connect 4 Peripherals To One Central #185 - GitHub
-
Communication Entre ARDUINO NANO 33 BLE SENSE?
-
Central And Peripheral Roles - V3.1 - Bluetooth API Documentation ...