ReelTwo
RSeries astromech firmware
PSControllerInternal.h
Go to the documentation of this file.
1
#ifndef PSControllerInternal_h
2
#define PSControllerInternal_h
3
4
#include "sdkconfig.h"
5
7
#ifndef ARDUINO_ARCH_ESP32
8
9
#ifndef CONFIG_BT_ENABLED
10
#error "The ESP32-PS3 module requires the Bluetooth component to be enabled in the project's menuconfig"
11
#endif
12
13
#ifndef CONFIG_BLUEDROID_ENABLED
14
#error "The ESP32-PS3 module requires Bluedroid to be enabled in the project's menuconfig"
15
#endif
16
17
#ifndef CONFIG_CLASSIC_BT_ENABLED
18
#error "The ESP32-PS3 module requires Classic Bluetooth to be enabled in the project's menuconfig"
19
#endif
20
21
#ifndef CONFIG_BT_SPP_ENABLED
22
#error "The ESP32-PS3 module requires Classic Bluetooth's SPP to be enabled in the project's menuconfig"
23
#endif
24
26
#ifdef CONFIG_BTDM_CONTROLLER_MODE_BTDM
27
#define BT_MODE ESP_BT_MODE_BTDM
28
#elif defined CONFIG_BTDM_CONTROLLER_MODE_BR_EDR_ONLY
29
#define BT_MODE ESP_BT_MODE_CLASSIC_BT
30
#else
31
#error "The selected Bluetooth controller mode is not supported by the ESP32-PS3 module"
32
#endif
33
34
#endif // ARDUINO_ARCH_ESP32
35
36
/* Detect ESP-IDF releases */
37
#if __has_include("esp_idf_version.h")
38
#include <esp_idf_version.h>
39
40
#else
41
42
/* Detect Arduino releases */
43
#if __has_include("core_version.h")
44
#include <core_version.h>
45
#endif
46
47
/* Arduino releases using IDF v3.2.3 */
48
#if defined(ARDUINO_ESP32_RELEASE_1_0_4) || defined(ARDUINO_ESP32_RELEASE_1_0_3)
49
#define ESP_IDF_VERSION_MAJOR 3
50
#define ESP_IDF_VERSION_MINOR 2
51
#define ESP_IDF_VERSION_PATCH 3
52
#endif
53
54
/* Arduino releases using IDF v3.2.2 */
55
#if defined(ARDUINO_ESP32_RELEASE_1_0_3) || defined(ARDUINO_ESP32_RELEASE_1_0_2) || defined(ARDUINO_ESP32_RELEASE_1_0_1) || defined(ARDUINO_ESP32_RELEASE_1_0_0)
56
#define ESP_IDF_VERSION_MAJOR 3
57
#define ESP_IDF_VERSION_MINOR 2
58
#define ESP_IDF_VERSION_PATCH 2
59
#endif
60
61
// Macro to convert IDF version number into an integer
62
#define ESP_IDF_VERSION_VAL(major, minor, patch) ((major << 16) | (minor << 8) | (patch))
63
64
// Current IDF version, as an integer
65
#define ESP_IDF_VERSION ESP_IDF_VERSION_VAL(ESP_IDF_VERSION_MAJOR, \
66
ESP_IDF_VERSION_MINOR, \
67
ESP_IDF_VERSION_PATCH)
68
69
#endif // __has_include("esp_idf_version.h")
70
71
extern
"C"
{
72
#include "esp_log.h"
73
#include "esp_bt.h"
74
#include "esp_bt_main.h"
75
#include "esp_bt_device.h"
76
#include "esp_gap_bt_api.h"
77
#include "esp_spp_api.h"
78
#include "
bt/private/stack/gap_api.h
"
79
#include "
bt/private/stack/bt_types.h
"
80
#include "
bt/private/stack/l2c_api.h
"
81
#include "
bt/private/stack/btm_api.h
"
82
#include "
bt/private/osi/allocator.h
"
83
}
84
85
#include "
PSController.h
"
86
87
#endif
l2c_api.h
gap_api.h
btm_api.h
PSController.h
allocator.h
bt_types.h
bt
PSController
PSControllerInternal.h
Generated by
1.8.17