Skip to content

Instantly share code, notes, and snippets.

View beegee-tokyo's full-sized avatar
🙃

Bernd Giesecke beegee-tokyo

🙃
View GitHub Profile
@beegee-tokyo
beegee-tokyo / BLE2902.cpp
Last active April 22, 2020 10:07
Dirty patch for ESP32 BLE server to allow multiple clients to connect and subscribe to Notify or Indicate
/** Patch for adding multi client subscriptions to NOTIFY and INDICATE
* All functions adapted to support data for up to 10 clients
* Check lines 23, 24, 25, 34, 35, 43, 44, 52, 53, 55, 57, 66, 67, 69, 71
* for changes
*/
/*
* BLE2902.cpp
*
* Created on: Jun 25, 2017
* Author: kolban
// Define digital output UUID
#define OUTPUT_UUID 0x2A57
/** Characteristic for digital output */
BLECharacteristic *pCharacteristicOutput;
/**
* MyServerCallbacks
* Callbacks for client write requests
*/
@beegee-tokyo
beegee-tokyo / gist:33a3e882dc327c86806441585a60eb1a
Created November 8, 2022 05:25
Send data in CayenneLPP format
#include <CayenneLPP.h>
/** Buffer for Cayenne LPP formatter */
CayenneLPP g_solution_data(255);
/** LoRaWAN application data buffer. */
static uint8_t m_lora_app_data_buffer[256];
/** Lora application data structure. */
static lmh_app_data_t m_lora_app_data = {m_lora_app_data_buffer, 0, 0, 0, 0};