8000 Merge pull request #124 from me-no-dev/master · kebot-embedded/esp32-snippets@e978c60 · GitHub
[go: up one dir, main page]

Skip to content

Commit e978c60

Browse files
authored
Merge pull request nkolban#124 from me-no-dev/master
Enable Logging in Arduino IDE
2 parents 5bac3df + fdafe2f commit e978c60

16 files changed

+48
-0
lines changed

cpp_utils/BLEAddress.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
#include <iomanip>
1414
#include <string.h>
1515
#include <stdio.h>
16+
#ifdef ARDUINO_ARCH_ESP32
17+
#include "esp32-hal-log.h"
18+
#endif
1619

1720

1821
/**

cpp_utils/BLEAdvertisedDevice.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
#include <sstream>
1818
#include "BLEAdvertisedDevice.h"
1919
#include "BLEUtils.h"
20+
#ifdef ARDUINO_ARCH_ESP32
21+
#include "esp32-hal-log.h"
22+
#endif
2023
static const char* LOG_TAG="BLEAdvertisedDevice";
2124

2225
BLEAdvertisedDevice::BLEAdvertisedDevice() {

cpp_utils/BLEAdvertising.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
#include <esp_err.h>
1313
#include "BLEUtils.h"
1414
#include "GeneralUtils.h"
15+
#ifdef ARDUINO_ARCH_ESP32
16+
#include "esp32-hal-log.h"
17+
#endif
1518

1619
static const char* LOG_TAG = "BLEAdvertising";
1720

cpp_utils/BLECharacteristic.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@
1818
#include "BLEUtils.h"
1919
#include "BLE2902.h"
2020
#include "GeneralUtils.h"
21+
#ifdef ARDUINO_ARCH_ESP32
22+
#include "esp32-hal-log.h"
23+
#endif
2124

2225
static const char* LOG_TAG = "BLECharacteristic";
2326

cpp_utils/BLECharacteristicCallbacks.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@
88
#if defined(CONFIG_BT_ENABLED)
99
#include "BLECharacteristic.h"
1010
#include <esp_log.h>
11+
#ifdef ARDUINO_ARCH_ESP32
12+
#include "esp32-hal-log.h"
13+
#endif
1114
static const char* LOG_TAG = "BLECharacteristicCallbacks";
1215

1316

cpp_utils/BLECharacteristicMap.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
#include <sstream>
1010
#include <iomanip>
1111
#include "BLEService.h"
12+
#ifdef ARDUINO_ARCH_ESP32
13+
#include "esp32-hal-log.h"
14+
#endif
1215

1316

1417
/**

cpp_utils/BLEClient.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@
1818
#include <string>
1919
#include <sstream>
2020
#include <unordered_set>
21+
#ifdef ARDUINO_ARCH_ESP32
22+
#include "esp32-hal-log.h"
23+
#endif
2124

2225
/*
2326
* Design

cpp_utils/BLEDescriptor.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@
1616
#include "BLEService.h"
1717
#include "BLEDescriptor.h"
1818
#include "GeneralUtils.h"
19+
#ifdef ARDUINO_ARCH_ESP32
20+
#include "esp32-hal-log.h"
21+
#endif
1922

2023
static const char* LOG_TAG = "BLEDescriptor";
2124

cpp_utils/BLEDescriptorMap.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111
#include "BLECharacteristic.h"
1212
#include "BLEDescriptor.h"
1313
#include <esp_gatts_api.h> // ESP32 BLE
14+
#ifdef ARDUINO_ARCH_ESP32
15+
#include "esp32-hal-log.h"
16+
#endif
1417

1518
/**
1619
* @brief Return the descriptor by UUID.

cpp_utils/BLEDevice.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@
2626
#include "BLEClient.h"
2727
#include "BLEUtils.h"
2828
#include "GeneralUtils.h"
29+
#ifdef ARDUINO_ARCH_ESP32
30+
#include "esp32-hal-log.h"
31+
#endif
2932

3033
static const char* LOG_TAG = "BLEDevice";
3134

cpp_utils/BLERemoteCharacteristic.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@
1818
#include "BLEUtils.h"
1919
#include "GeneralUtils.h"
2020
#include "BLERemoteDescriptor.h"
21+
#ifdef ARDUINO_ARCH_ESP32
22+
#include "esp32-hal-log.h"
23+
#endif
2124

2225

2326
static const char* LOG_TAG = "BLERemoteCharacteristic"; // The logging tag for this class.

cpp_utils/BLERemoteDescriptor.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
#include "BLERemoteDescriptor.h"
1111
#include "GeneralUtils.h"
1212
#include <esp_log.h>
13+
#ifdef ARDUINO_ARCH_ESP32
14+
#include "esp32-hal-log.h"
15+
#endif
1316

1417
static const char* LOG_TAG = "BLERemoteDescriptor";
1518

cpp_utils/BLERemoteService.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
#include "GeneralUtils.h"
1414
#include <esp_log.h>
1515
#include <esp_err.h>
16+
#ifdef ARDUINO_ARCH_ESP32
17+
#include "esp32-hal-log.h"
18+
#endif
1619

1720
static const char* LOG_TAG = "BLERemoteService";
1821

cpp_utils/BLEScan.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
#include "BLEScan.h"
1818
#include "BLEUtils.h"
1919
#include "GeneralUtils.h"
20+
#ifdef ARDUINO_ARCH_ESP32
21+
#include "esp32-hal-log.h"
22+
#endif
2023

2124
static const char* LOG_TAG = "BLEScan";
2225

cpp_utils/BLEServer.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
#include <string>
2121
#include <gatt_api.h>
2222
#include <unordered_set>
23+
#ifdef ARDUINO_ARCH_ESP32
24+
#include "esp32-hal-log.h"
25+
#endif
2326

2427
static const char* LOG_TAG = "BLEServer";
2528

cpp_utils/BLEValue.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
#include <esp_log.h>
1111

1212
#include "BLEValue.h"
13+
#ifdef ARDUINO_ARCH_ESP32
14+
#include "esp32-hal-log.h"
15+
#endif
1316

1417
static const char* LOG_TAG="BLEValue";
1518

0 commit comments

Comments
 (0)
0