Documentation

Giantronic Docs

Everything you need to set up, configure, and manage your ESP32 IoT fleet with Giantronic.

Overview

Giantronic is a full-stack IoT platform for managing ESP32 devices at scale. It provides real-time monitoring, remote configuration, automation, and OTA firmware updates through a unified web dashboard and mobile app.

ESP32 Devices

Pair, monitor, and control ESP32 microcontrollers from anywhere.

Real-time Dashboard

Live device status, pin states, and energy consumption metrics.

REST API

Full RESTful API for integrations, automation, and custom workflows.

Mobile App

Native Android app for device management on the go.


Features

Giantronic includes everything you need for professional IoT fleet management.

Device Pairing

Secure MAC-based pairing with QR code and manual entry support.

Pin Configuration

Configure GPIO pins as digital/analog I/O with custom names and modes.

Schedules

Time-based automation with per-minute triggers and weekly repeats.

Scenes

One-tap multi-device actions with custom voice keywords.

Fleet Management

Group devices into fleets with health monitoring and alerts.

Energy Monitoring

Track power consumption per device, pin, or fleet in real time.

OTA Updates

Over-the-air firmware updates from GitHub releases or custom binaries.

Notifications

Email and push notifications for device events, alerts, and schedules.

Security

JWT auth, Firebase integration, two-factor authentication, and role-based access.


Quick Start

Get up and running with Giantronic in minutes.

  1. Create Your Account

    Sign up at the Giantronic dashboard. Verify your email address to activate your account.

  2. Flash Your ESP32

    Flash the Giantronic firmware to your ESP32 using the OTA updater or USB. The firmware is available in the Firmware section of the dashboard.

  3. Pair Your Device

    Power on your ESP32. It will broadcast its MAC address. Go to Devices → Add Device and enter the MAC address to pair it.

  4. Configure Pins

    Assign functions to GPIO pins: digital input/output, analog input, relay control, or LED indicators.

  5. Automate with Schedules

    Create time-based schedules to turn devices on/off at specific times with optional weekly repeats.

You can also use the Giantronic mobile app (Android) for on-the-go device management. Download it from the Play Store or build from source.


Device Pairing

Pair your ESP32 devices to start managing them through the dashboard or mobile app.

How Pairing Works

Giantronic uses a deterministic device key based on the ESP32's MAC address. The key format is MAC_{sanitized_mac} where the MAC address colons are replaced with underscores.

Device Key Format
// MAC Address: AA:BB:CC:DD:EE:FF
"MAC_AA_BB_CC_DD_EE_FF"

Pairing Flow

  1. ESP32 connects to WiFi

    The device boots, connects to WiFi, and registers itself in Firebase with its MAC address and IP.

  2. User pairs the device

    From the dashboard or mobile app, enter the device's MAC address. The backend creates a Django Device record and links it to the Firebase entry.

  3. Two-way sync begins

    Pin configurations, schedules, and scenes sync between Django, Firebase, and the ESP32 via HTTP polling.

Owner filtering: Normal users can only see their own paired devices. Admin users can see all devices in the system.


Pin Configuration

Configure ESP32 GPIO pins with custom functions, names, and modes.

Pin Fields

FieldTypeDescription
pin_namestringHuman-readable name (e.g., "Living Room Light")
gpio_pinstringGPIO number (e.g., "2", "4", "15")
functionstringdigital_input, digital_output, analog_input, pwm_output, relay
modestringinput or output
statebooleanCurrent on/off state (output pins)
descriptionstringOptional description
analog_valueintegerCurrent analog reading (0-4095 for ESP32 ADC)
timestampISO 8601Last state change timestamp

Cross-platform sync: Pin configurations are synchronized across web dashboard, mobile app, and ESP32 via Firebase. All platforms use identical field names.


Schedules

Automate your devices with time-based schedules that trigger at specific times.

Schedule Fields

FieldTypeDescription
deviceKeystringMAC-based device key
triggerTimestringTime in "HH:mm" format (24-hour)
turnOnbooleantrue to turn on, false to turn off
logicalPinstringTarget pin name (e.g., "pin_02")
repeatstringComma-separated days: "Mon,Tue,Wed,Thu,Fri" or empty for one-time
targetsarrayList of target objects with device/pin info

Double-execution prevention: Schedules include a _lastExecutionId field that prevents re-execution within the same minute window.


Scenes

Create one-tap actions that control multiple devices simultaneously.

Scene Structure

Each scene contains an action list with device targets and desired pin states. Scenes can be triggered from the web dashboard, mobile app, or via voice keywords.

Scene Action Format
{
  "name": "Movie Night",
  "actions": [
    {
      "deviceKey": "MAC_AA_BB_CC_DD_EE_FF",
      "pin": "pin_02",
      "state": true
    },
    {
      "deviceKey": "MAC_11_22_33_44_55_66",
      "pin": "pin_04",
      "state": false
    }
  ]
}

Voice Keywords

Scenes can be assigned custom voice keywords for voice assistant integration. Keywords are stored in the format:

Voice Keyword Format
{
  "keyword": "movie night",
  "turnOn": true,
  "deviceType": "scene",
  "language": "en",
  "targets": [...]
}

Fleet Management

Group devices into fleets for organized management and monitoring.

Fleets

Logical groups of devices (e.g., "Office Building", "Home Sensors").

Fleet Health

Aggregated health metrics: online count, offline count, error rates.

Fleet Alerts

Automatic alerts when devices go offline, report errors, or deviate from thresholds.

Fleet Commands

Broadcast commands to all devices in a fleet simultaneously.


Energy Monitoring

Track real-time power consumption across your device fleet.

Energy data is collected from ESP32 devices via analog pin readings and reported to the backend. The dashboard displays:

Per-Device Usage

Real-time wattage and historical consumption per device.

Per-Pin Breakdown

Energy consumption broken down by individual GPIO pins.

Daily Summaries

Automated daily, weekly, and monthly energy reports.


Notifications

Stay informed with email and push notifications for device events.

Email Notifications

Welcome emails, verification, password resets, and device alerts.

Push Notifications

FCM push notifications to the Android mobile app.

Preferences

Per-user notification preferences for different event types.


OTA Updates

Update ESP32 firmware over-the-air without physical access.

Update Sources

  • GitHub Releases

    Link your firmware repository. Giantronic fetches releases and makes them available for OTA flashing.

  • Custom Binary Upload

    Upload .bin firmware files directly through the dashboard.

  • Bulk OTA

    Push firmware updates to an entire fleet simultaneously with rollback support.


API Reference

Giantronic provides a full REST API for programmatic access. All endpoints require JWT authentication.

Authentication

Get JWT Token
POST /api/token/
// Body
{
  "username": "your_username",
  "password": "your_password"
}

// Response
{
  "access": "eyJhbGci...",
  "refresh": "eyJhbGci..."
}
Use Token in Request
GET /api/devices/
Authorization: Bearer eyJhbGci...

Core Endpoints

MethodEndpointDescription
GET /users/me/ Get current user profile
GET /api/devices/ List all paired devices
POST /api/devices/ Pair a new device
GET /api/devices/{id}/ Get device details
PATCH /api/devices/{id}/ Update device configuration
DEL /api/devices/{id}/ Remove/unpair device
GET /api/fleets/ List all fleets
GET /api/notifications/ List notifications
POST /api/flash-jobs/ Create OTA flash job
GET /api/fleet-alerts/ List fleet alerts

API Documentation

Swagger UI

Interactive API explorer with request/response examples.

OpenAPI Schema

Download the schema in OpenAPI 3.0 format.

ReDoc

Beautiful API documentation generated from the schema.


Mobile App

The Giantronic Android app provides full device management on the go.

Features

Auth

Login, register, forgot password, email verification, and Google OAuth.

Devices

Pair, view, and control ESP32 devices with real-time status.

Pin Config

Configure GPIO pins with inline state toggles.

Schedules

Create and manage time-based automation rules.

Scenes

One-tap scene execution and voice keyword management.

Fleet

Fleet overview, health status, and alert management.

Authentication Flow

The mobile app uses Firebase Authentication for user sign-in, then exchanges the Firebase ID token for a Django JWT via the /accounts/firebase/exchange-token/ endpoint.

Firebase Token Exchange
POST /accounts/firebase/exchange-token/
Content-Type: application/json

{
  "id_token": "firebase_id_token_from_client_sdk"
}

// Response
{
  "access": "jwt_access_token",
  "refresh": "jwt_refresh_token",
  "user": { /* user profile */ }
}

Troubleshooting

Common issues and their solutions.

Device not appearing after pairing

Ensure the ESP32 has successfully connected to WiFi and registered in Firebase. The device must be online before pairing can complete. Check the Firebase console under esp32_devices/ to verify the device is registered.

Pin state not syncing

Pin configurations sync via Firebase. If changes aren't reflecting, check that the ESP32 is polling the Firebase path esp32_devices/{device_key}/pins/ at the expected interval (typically every 2-5 seconds).

Schedule not executing

Verify the schedule format uses the correct field names (deviceKey, triggerTime, turnOn). Check that the device is online at the scheduled time. One-time schedules clear after execution.

Mobile app shows "Email not verified"

Check your inbox (and spam folder) for the verification email. You can resend it from the app. Both Django and Firebase send separate verification emails.

OTA update fails

Ensure the ESP32 has a stable WiFi connection. Large firmware files may take several minutes. Check the flash history in the dashboard for detailed error messages.


FAQ

What ESP32 boards are supported?

Giantronic supports all ESP32 variants (ESP32, ESP32-S2, ESP32-S3, ESP32-C3) running the Giantronic firmware.

Is there a limit to the number of devices?

Free accounts can pair up to 10 devices. Enterprise accounts have unlimited device support.

Can I use Giantronic without the mobile app?

Yes. The web dashboard provides full functionality. The mobile app is optional for on-the-go management.

How does cross-platform sync work?

All device data flows through Firebase as the real-time sync layer. Django serves as the persistent database and API layer. Both web and mobile write to Firebase with identical field names, and the ESP32 reads directly from Firebase.

Is the API rate-limited?

API requests are rate-limited to 100 requests per minute per user. Device polling to Firebase is not rate-limited.