File tree Expand file tree Collapse file tree 4 files changed +13
-1
lines changed Expand file tree Collapse file tree 4 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 1414
1515#include "esp32-hal-bt.h"
1616
17- #if CONFIG_BT_ENABLED
17+ #if defined(CONFIG_BT_ENABLED ) && defined(CONFIG_BLUEDROID_ENABLED )
18+
1819
1920#include "bt.h"
2021#include "esp_bt_defs.h"
Original file line number Diff line number Diff line change 1616// Useful if you want to advertise some sort of message
1717// Button is attached between GPIO 0 and GND, and the device name changes each time the button is pressed
1818
19+ #if !defined(CONFIG_BT_ENABLED) || !defined(CONFIG_BLUEDROID_ENABLED)
20+ #error Bluetooth is not enabled! Please run `make menuconfig` to and enable it
21+ #endif
22+
1923#include " SimpleBLE.h"
2024SimpleBLE ble;
2125
Original file line number Diff line number Diff line change 1212// See the License for the specific language governing permissions and
1313// limitations under the License.
1414
15+ #if defined(CONFIG_BT_ENABLED) && defined(CONFIG_BLUEDROID_ENABLED)
16+
1517#include " SimpleBLE.h"
1618#include " esp32-hal-log.h"
1719
@@ -125,3 +127,5 @@ void SimpleBLE::end()
125127{
126128 _stop_gap ();
127129}
130+
131+ #endif
Original file line number Diff line number Diff line change 1515#ifndef _SIMPLE_BLE_H_
1616#define _SIMPLE_BLE_H_
1717
18+ #if defined(CONFIG_BT_ENABLED) && defined(CONFIG_BLUEDROID_ENABLED)
1819
1920#include < cstdint>
2021#include < cstdio>
@@ -58,3 +59,5 @@ class SimpleBLE {
5859};
5960
6061#endif
62+
63+ #endif
You can’t perform that action at this time.
0 commit comments