360e04fa36
* BLERemoteChar: fix descriptor 2902 write for characteristic notifications When registering a notification on a characteristic, the 2902 descriptor (CCCD) value is set to 1 (or 2 for indication). According to the BLUETOOTH CORE SPECIFICATION Version 5.2, Revision Date 2019-12-31, section 4.12.3 "Write Characteristic Descriptors" (page 1588), the characteristic descriptor write must expect a response. Currently, the descriptor write is performed without expecting a reponse, which prevents the notification to be functional with some BLE stacks. This commit modify the write to expect the response. Signed-off-by: Jimmy Durand Wesolowski <jimmy.durand.wesolowski@commsolid.com> * BLERemoteChar: forward GATT client event to characteristic descriptors This commits prevents a permanent wait when calling BLERemoteDescriptor readValue function, on the m_semaphoreReadDescrEvt semaphore. ESP32 BLE stack calls to remote characteristic - notification, - value read - value write and remote characteristic descriptor - value read are asynchronous. When such a call is performed by this library, a semaphore is taken prior to the BLE stack read or write operation, and waited on after it. Releasing the semaphore is done by the characteristic event handling function (gattClientEventHandler), when the appropriate event is received. However, the characteristic descriptor events are discarded, and the value read semaphore is never released. This commits forwards the GATT client events from the remote characteristic down to their remote characteristic descriptor, and implements their event handling. Adding a semaphore for the remote characteristic descriptor value write will be done in a separate commit. Signed-off-by: Jimmy Durand Wesolowski <jimmy.durand.wesolowski@commsolid.com> * BLERemoteDescriptor: add semaphore to characteristic descriptor write This adds a semaphore to characteristic descriptor value write, to mimic the value read function, and to ensure completion of the operation before we carry on. Signed-off-by: Jimmy Durand Wesolowski <jimmy.durand.wesolowski@commsolid.com> Co-authored-by: Jimmy Durand Wesolowski <jimmy.durand.wesolowski@commsolid.com> |
||
---|---|---|
.. | ||
ArduinoOTA | ||
AsyncUDP | ||
AzureIoT@5e8ffb2111 | ||
BLE | ||
BluetoothSerial | ||
DNSServer | ||
EEPROM | ||
ESP32 | ||
ESPmDNS | ||
FFat | ||
FS | ||
HTTPClient | ||
HTTPUpdate | ||
NetBIOS | ||
Preferences | ||
SD | ||
SD_MMC | ||
SimpleBLE | ||
SPI | ||
SPIFFS | ||
Ticker | ||
Update | ||
WebServer | ||
WiFi | ||
WiFiClientSecure | ||
Wire | ||
README.md |
ESP32 Libraries
arduino-esp32 includes libraries for Arduino compatibility along with some object wrappers around hardware specific devices. Examples are included in the examples folder under each library folder. The ESP32 includes additional examples which need no special drivers.
ArduinoOTA
Over The Air firmware update daemon. Use espota.py to upload to the device.
AsyncUDP
Asynchronous task driven UDP datagram client/server
AzureIoT
Library to interact with Microsoft Azure IoT services
BLE
Bluetooth Low Energy v4.2 client/server framework
BluetoothSerial
Serial to Bluetooth redirection server
DNSServer
A basic UDP DNS daemon (includes captive portal demo)
EEPROM
Arduino compatibility for EEPROM (using flash)
ESP32
Additional examples
- AnalogOut
- Camera
- ChipID
- DeepSleep
- ESPNow
- FreeRTOS
- GPIO
- HallSensor
- I2S
- ResetReason
- RMT
- Time
- Timer
- Touch
ESPmDNS
mDNS service advertising
FFat
FAT indexed filesystem on SPI flash
FS
Filesystem virtualization framework
HTTPClient
A simple HTTP client, compatible with WiFiClientSecure
HTTPUpdate
Download a firmware update from HTTPd and apply it using Update
NetBIOS
NetBIOS name advertiser
Preferences
Flash keystore using ESP32 NVS
SD
Secure Digital card filesystem using SPI access
SD_MMC
Secure Digital card filesystem using 4-lane access
SimpleBLE
Minimal BLE advertiser
SPI
Arduino compatible Serial Peripheral Interface driver (master only)
SPIFFS
SPI Flash Filesystem (see spiffs-plugin to upload to device)
Ticker
A timer to call functions on an interval
Update
Sketch Update using ESP32 OTA functionality
WebServer
A simple HTTP daemon
WiFi
Arduino compatible WiFi driver (includes Ethernet driver)
WiFiClientSecure
Arduino compatible WiFi client object using embedded encryption
Wire
Arduino compatible I2C driver (master only)