diff --git a/src/BLEMIDI_Transport.h b/src/BLEMIDI_Transport.h index 63a61ec..b960e6f 100644 --- a/src/BLEMIDI_Transport.h +++ b/src/BLEMIDI_Transport.h @@ -46,6 +46,11 @@ public: void begin() { mBleClass.begin(mDeviceName, this); + } + + void end() + { + mBleClass.end(); } bool beginTransmission(MIDI_NAMESPACE::MidiType type) diff --git a/src/hardware/BLE-MIDI_Client_ESP32.h b/src/hardware/BLE-MIDI_Client_ESP32.h index b2a1029..8b31f3b 100644 --- a/src/hardware/BLE-MIDI_Client_ESP32.h +++ b/src/hardware/BLE-MIDI_Client_ESP32.h @@ -21,7 +21,12 @@ public: } bool begin(const char*, BLEMIDI*); - + + void end() + { + + } + void write(uint8_t* data, uint8_t length) { _characteristic->setValue(data, length); diff --git a/src/hardware/BLEMIDI_ArduinoBLE.h b/src/hardware/BLEMIDI_ArduinoBLE.h index c88bdc1..3b4cb9f 100644 --- a/src/hardware/BLEMIDI_ArduinoBLE.h +++ b/src/hardware/BLEMIDI_ArduinoBLE.h @@ -75,6 +75,11 @@ public: bool begin(const char*, BLEMIDI_Transport*); + void end() + { + + } + void write(uint8_t* buffer, size_t length) { // TODO: test length diff --git a/src/hardware/BLEMIDI_ESP32.h b/src/hardware/BLEMIDI_ESP32.h index c9868dc..ec961eb 100644 --- a/src/hardware/BLEMIDI_ESP32.h +++ b/src/hardware/BLEMIDI_ESP32.h @@ -30,6 +30,11 @@ public: bool begin(const char*, BLEMIDI_Transport*); + void end() + { + + } + void write(uint8_t* buffer, size_t length) { _characteristic->setValue(buffer, length); diff --git a/src/hardware/BLEMIDI_ESP32_NimBLE.h b/src/hardware/BLEMIDI_ESP32_NimBLE.h index 5a8483a..b601f61 100644 --- a/src/hardware/BLEMIDI_ESP32_NimBLE.h +++ b/src/hardware/BLEMIDI_ESP32_NimBLE.h @@ -27,6 +27,11 @@ public: bool begin(const char*, BLEMIDI_Transport*); + void end() + { + + } + void write(uint8_t* buffer, size_t length) { _characteristic->setValue(buffer, length); diff --git a/src/hardware/BLEMIDI_nRF52.h b/src/hardware/BLEMIDI_nRF52.h index 619f6b9..2210897 100644 --- a/src/hardware/BLEMIDI_nRF52.h +++ b/src/hardware/BLEMIDI_nRF52.h @@ -24,6 +24,11 @@ public: bool begin(const char*, BLEMIDI_NAMESPACE::BLEMIDI_Transport*); + void end() + { + + } + void write(uint8_t* buffer, size_t length) { }