Skip to content

PlatformIO SDK

riteshrajas edited this page Aug 31, 2026 · 1 revision

PlatformIO SDK

Official PlatformIO package for Pyintel Lux (riteshrajas/Pyintel_Lux).


1. Installation (platformio.ini)

Add Pyintel_Lux to lib_deps in your platformio.ini:

[env:esp32dev]
platform = espressif32
board = esp32dev
framework = arduino
monitor_speed = 115200
lib_deps =
    riteshrajas/Pyintel_Lux@^0.1.2

For direct Git dependency tracking:

lib_deps =
    https://github.com/Pyintel/pyintel-lux-platformio.git

2. Basic Example (src/main.cpp)

#include <Arduino.h>
#include <Pyintel_Lux.h>

Lux lux;

void setup() {
    Serial.begin(115200);
    
    // Join UUID-synchronized mesh network across available hardware transports
    lux.beginMesh("f47ac10b-58cc-4372-a567-0e02b2c3d479");
    
    // Register message callback
    lux.onMessage(0x0100, [](const lux_frame_t *frame) {
        // Handle incoming binary frame
    });
}

void loop() {
    lux.tick(); // Process queues & routing table
    lux.broadcast(0x0100, (float)24.5f); // Broadcast sensor payload
    delay(1000);
}

3. Supported Architecture Frameworks

  • Espressif ESP32: ESP32, ESP32-S3, ESP32-C3, ESP32-C6 (ESP-NOW, Wi-Fi UDP, Serial)
  • Nordic nRF52: nRF52840, micro:bit v2, Adafruit CLUE (BLE, Nordic 2.4GHz Radio)
  • Raspberry Pi: RP2040, RP2350 (UART, SPI, Multi-Node Mesh)
  • STM32 & SAMD21: STM32F4, SAMD21 Cortex-M0+ (Serial UART)
  • AVR: ATmega328P (Uno, Nano), ATmega2560 (Mega)

Clone this wiki locally