TribeWarez

ESP PoT-O Miner

Mining firmware for ESP32-S and ESP8266 microcontrollers

Connects to pot.rpc.gateway.tribewarez.com to fetch PoT-O challenges, execute tensor operations on-device, and submit proofs for on-chain verification.

MIT C/C++ (Arduino) PlatformIO ESP32-S / ESP8266

Device Capabilities

Device Max Tensor Working Memory Supported Ops
ESP32-S 64×64 320 KB matrix_multiply, convolution, relu, sigmoid, dot_product, normalize
ESP8266 32×32 80 KB relu, sigmoid, dot_product, normalize

Quick Start

1. Configure WiFi

Edit lib/pot_o_firmware_core/include/pot_o/pot_o_config.h:

#define WIFI_SSID "YOUR_SSID" #define WIFI_PASS "YOUR_PASS"

Or pass via build flags: -DWIFI_SSID='"MySSID"' -DWIFI_PASS='"MyPass"'

2. Build & Upload

# ESP32-S pio run -e esp32s -t upload # ESP8266 (NodeMCU v2) pio run -e esp8266 -t upload

3. Monitor

pio device monitor -b 115200

Mining Flow

  1. Boot → Connect WiFi → Register device with RPC
  2. Loop:
    • POST /challenge → get tensor challenge
    • Execute tensor operation (matrix multiply, convolution, activation, etc.)
    • Compute MML score (entropy-based approximation of DEFLATE ratio)
    • Search nonces for neural path match within Hamming distance tolerance
    • POST /submit → submit proof for on-chain verification
  3. Progress → POST /devices/progress every few seconds
  4. Heartbeat → GET /health every 30s

Architecture

Core Library

lib/pot_o_firmware_core/ — Tensor ops (base + ESP32 tiled matmul, optional ESP-DSP), neural path, SHA-256, MML score.

App

src/main.cpp — setup, mining loop, HTTP client, proof assembly.

Hardware SHA

ESP32 hardware SHA enabled via sdkconfig.defaults (CONFIG_MBEDTLS_HARDWARE_SHA=y).

Self-Check

Optional boot-time firmware update check against status.rpc.gateway.tribewarez.com.

RPC Endpoint

Default: https://pot.rpc.gateway.tribewarez.com

Override in platformio.ini build flags:

build_flags = -DPOT_RPC_HOST=\"your-host.example.com\" -DPOT_RPC_PORT=8900 -DPOT_RPC_TLS=0

Part of the PoT-O validator ecosystem. Read the docs →