Control Surface main
MIDI Control Surface library for Arduino
Loading...
Searching...
No Matches
BluetoothMIDI_Interface.hpp
Go to the documentation of this file.
1#pragma once
2
3#ifndef CS_BLE_MIDI_NOT_SUPPORTED
4
5#include <Settings/NamespaceSettings.hpp>
6
7#ifdef DOXYGEN
12END_BEGIN_CS_NAMESPACE
15#define CS_BLE_MIDI_SUPPORTED 1
19#define CS_USE_NIMBLE
20
21#elif defined(ESP32)
22#include <sdkconfig.h>
23#if CONFIG_BT_BLE_ENABLED
24// ESP32 with BLE support
25#ifdef CS_USE_NIMBLE
26// NimBLE backend
31#define CS_BLE_MIDI_SUPPORTED 1
32#else
33// Bluedroid backend (default)
38#define CS_BLE_MIDI_SUPPORTED 1
39#endif
40#endif
41
42#elif defined(ARDUINO_RASPBERRY_PI_PICO_W)
43// Pico W
44#if ENABLE_BLE
49#define CS_BLE_MIDI_SUPPORTED 1
50#endif
51
52#elif (defined(ARDUINO_ARCH_MBED) && defined(ARDUINO_ARDUINO_NANO33BLE)) || \
53 (defined(ARDUINO_ARCH_MBED) && defined(ARDUINO_ARCH_RP2040)) || \
54 (defined(ARDUINO_ARCH_MBED) && defined(ARDUINO_GIGA)) || \
55 defined(ARDUINO_UNOR4_WIFI) || defined(ARDUINO_SAMD_NANO_33_IOT) || \
56 defined(ARDUINO_SAMD_MKRWIFI1010) || defined(CS_USE_ARDUINOBLE)
57// Arduino Nano 33 BLE, RP2040, Arduino GIGA, Arduino UNO R4 WiFi,
58// Arduino Nano 33 IoT, Arduino MKR 1010 WiFi
63#define CS_BLE_MIDI_SUPPORTED 1
64#endif
65
66#ifdef CS_BLE_MIDI_SUPPORTED
79#endif
80
81#ifndef CS_BLE_MIDI_SUPPORTED
82#define CS_BLE_MIDI_NOT_SUPPORTED 1
83#endif
84
85#endif // CS_BLE_MIDI_NOT_SUPPORTED
ESP32BLEBackend< ble_backend::ESP32BluedroidBLE > ESP32BluedroidBackend
ESP32 Bluedroid backend intended to be plugged into GenericBLEMIDI_Interface.
ESP32BLEBackend< ble_backend::ESP32NimBLE > ESP32NimBLEBackend
ESP32 NimBLE backend intended to be plugged into GenericBLEMIDI_Interface.
#define END_CS_NAMESPACE
#define BEGIN_CS_NAMESPACE
ArduinoBLE backend intended to be plugged into GenericBLEMIDI_Interface.
Raspberry Pi Pico BTstack background backend intended to be plugged into GenericBLEMIDI_Interface.
Bluetooth Low Energy MIDI Interface.
Default backend for the BluetoothMIDI_Interface class.
A class for MIDI interfaces sending MIDI messages over a Bluetooth Low Energy (BLE) connection.