Registered Transit Guardians
0 devices registered
No devices registered yet.
Go to Add / Setup to register a Transit Guardian.
Register a New Transit Guardian
Each physical unit must be registered here. A unique user code is generated automatically — give this code to the recipient so they can monitor their specific device.
Per-Device Setup Checklist
Complete these steps for each physical unit before shipping.
- Flash the Transit Guardian firmware to the Heltec WiFi LoRa 32 board (see Build Guide).
- Power on the device and connect to its setup AP (
TransitGuardian-SETUP). - Open
192.168.4.1in a browser and enter the destination WiFi credentials. - Note the device's local IP address once it joins the network (shown on the OLED display).
- Enter that IP in the Device WiFi URL field above and register the device.
- Test all sensors from the Transit Hub live view (Connect → verify telemetry).
- Calibrate the shock threshold if needed via the device web interface.
- Insert a formatted microSD card (FAT32, ≤32 GB) into the device.
- Label the physical unit with the generated user code and the owner's name.
- Pack securely and share the user code with the recipient.
📶 Meshtastic Node Auto-Setup Wizard
Use this wizard to configure a new Meshtastic node for use with Transit Guardian. Connect the node via USB or BLE, then follow each step. For full configuration, open the Meshtastic tab.
🔗 flasher.meshtastic.org
mqtt.meshtastic.org (public) or your own broker.
Enable "Map Reporting" to see your nodes on
the mesh map.
🛒 Bill of Materials
Parts required to build one Transit Guardian unit.
| Component | Specification / Part # | Qty | Notes |
|---|---|---|---|
| Main Board | Heltec WiFi LoRa 32 V3 (ESP32-S3 + SX1262) | 1 | Built-in OLED, LoRa, WiFi, BLE |
| IMU (Shock/Tilt) | MPU-6050 (GY-521 breakout) | 1 | I²C: SDA=21, SCL=22 |
| Barometric / Temp | BMP280 or BMP388 breakout | 1 | I²C shared bus |
| Light Sensor | LDR (GL5537) + 10 kΩ resistor (voltage divider) | 1 | Analog → GPIO 35 |
| Reed Switch (Tamper) | Normally-Closed reed switch | 1 | Digital input, pull-up → GPIO 32 |
| Sound Sensor | KY-037 or MAX4466 microphone module | 1 | Digital out → GPIO 33; analog optional |
| microSD Module | SPI microSD card adapter | 1 | SPI: CS=5, MOSI=23, MISO=19, SCK=18 |
| Battery | LiPo 3.7 V 2000 mAh (JST-PH 2-pin) | 1 | Connected to Heltec BAT pin |
| LoRa Antenna | 868/915 MHz 2 dBi stub (SMA) | 1 | Must attach before power-on |
| Enclosure | IP54 ABS project box ≥80×60×35 mm | 1 | Drill holes for antenna, USB, OLED window |
| microSD Card | Class 10 / U1, ≤32 GB, FAT32 formatted | 1 | Included with device |
| Misc. | Jumper wires, 2.54 mm headers, hot glue, foam padding | — |
🔌 Wiring Diagram (GPIO Pin Map)
Heltec WiFi LoRa 32 V3 pin assignments ─────────────────────────────────────── I²C Bus (shared): SDA → GPIO 21 SCL → GPIO 22 Devices: MPU-6050 (addr 0x68), BMP280 (addr 0x76) SPI Bus (microSD): CS → GPIO 5 MOSI → GPIO 23 MISO → GPIO 19 SCK → GPIO 18 Analog: LDR voltage divider → GPIO 35 (ADC1_CH7) Digital: Reed switch (NC, pull-up) → GPIO 32 Sound sensor (digital) → GPIO 33 Power: 3.3 V rail → MPU-6050 VCC, BMP280 VCC, LDR top, KY-037 VCC GND → all GND pins LiPo 3.7 V → Heltec BAT connector (JST-PH)
🔧 Step-by-Step Assembly
Phase 1 – Prepare Components
Inspect all components. Verify the Heltec board is a V3 (ESP32-S3). Check that the OLED display connector is seated.
Solder male headers to the MPU-6050 and BMP280 breakouts if not pre-soldered.
Build the LDR voltage divider: wire the LDR from 3.3 V to the mid-point, the 10 kΩ resistor from the mid-point to GND, and connect the mid-point to GPIO 35.
Format the microSD card as FAT32 on your computer before inserting it.
Phase 2 – Wiring
Connect MPU-6050: VCC→3.3 V, GND→GND, SDA→GPIO 21, SCL→GPIO 22. Leave AD0 floating (addr 0x68).
Connect BMP280: VCC→3.3 V, GND→GND, SDA→GPIO 21, SCL→GPIO 22, SDO→GND (addr 0x76).
Connect microSD module: VCC→3.3 V, GND→GND, CS→GPIO 5, MOSI→GPIO 23, MISO→GPIO 19, SCK→GPIO 18.
Connect reed switch: one leg to GPIO 32, other leg to GND. Enable the internal pull-up in firmware so the pin reads HIGH when the magnet is present and LOW when removed (tamper).
Connect KY-037 sound sensor: VCC→3.3 V, GND→GND, D0 (digital)→GPIO 33. Adjust the onboard trimpot to set the sound threshold.
Plug in the LiPo battery to the Heltec JST-PH BAT connector.
Phase 3 – Firmware
Install Arduino IDE 2.x and add the Heltec ESP32 board package:https://resource.heltec.cn/download/package_heltec_esp32_index.json
Install required Arduino libraries via Library Manager: Heltec ESP32 Dev-Boards, MPU6050 (ElectronicCats), Adafruit BMP280, SD (built-in), ArduinoJson, ESPAsyncWebServer, AsyncTCP.
Open the Transit Guardian sketch. Set your UNIT_ID and LORA_FREQUENCY constants at the top of the file (915 MHz for US, 868 MHz for EU).
Select Board: Heltec WiFi LoRa 32(V3) in Arduino IDE. Connect via USB-C. Select the correct port. Upload.
Watch the Serial Monitor (115200 baud). Verify "MPU-6050 OK", "BMP280 OK", "SD OK", "LoRa OK", "WiFi AP started" messages on boot.
Phase 4 – WiFi Configuration
On first boot the device creates a setup access point. Connect your phone/laptop to the WiFi network named TransitGuardian-SETUP (no password).
Open http://192.168.4.1 in your browser. Enter the destination network's SSID and password, then click Save.
The device reboots, joins the target WiFi, and displays its IP on the OLED. Note this IP — it becomes the Device WiFi URL you register above.
Phase 5 – Validation & Packaging
Open the Transit Hub, enter the device's IP, click Connect. Confirm all 6 sensor readings update in real time.
Physically shake the device and verify a COMPROMISED/WATCH shock event appears in the incident log.
Remove the magnet from the reed switch and verify a tamper event is logged.
Mount all components inside the enclosure with foam padding on all sides. Secure the antenna externally via the SMA bulkhead.
Apply a label inside the lid showing the unit ID, user code, and emergency contact email.
📋 Firmware Configuration Reference
Key constants to configure at the top of the Transit Guardian Arduino sketch.
// ── Transit Guardian Firmware Config ────────────────── const char* UNIT_ID = "TG-00000001"; // unique per device const char* LORA_BAND = "915E6"; // US: 915E6 | EU: 868E6 const int SHOCK_G_THRESH = 2; // trigger at 2g acceleration const int SOUND_THRESH = 80; // dB-equivalent trimpot level const int LOG_INTERVAL = 5000; // log every 5 s (ms) const int TELEMETRY_INT = 2000; // broadcast LoRa every 2 s const char* SETUP_AP_PASS = ""; // leave blank = open AP // ─────────────────────────────────────────────────────
🔑 Change Admin Password
The admin password is stored as a SHA-256 hash in this HTML file. To change it:
- Enter your new password below and click Compute Hash.
- Copy the resulting hash.
- Open
transit-guardian-admin.htmlin a text editor. - Find the constant
HASH_HEXin the<script>section. - Replace its value with the new hash (keep the surrounding quotes).
- Save and deploy the file.
🗑 Data Management
Device registrations are stored in your browser's localStorage. This data
is local to this browser. Export regularly to keep a backup.
ℹ️ About This Panel
Transit Guardian Admin v1.0 — © 2008-2026 Barbrick Design
Manage and monitor all Transit Guardian units from one password-protected page.
Device data is stored locally in localStorage — no cloud storage required.
Connect to Node
Connects to a Meshtastic node over Bluetooth Low Energy (BLE). Requires Chrome or Edge on a BLE-capable device. The node must be powered on and within ~10 m range.
Connects to a Meshtastic node plugged in via USB. Requires Chrome or Edge. Default baud rate: 921600. The node must be running Meshtastic firmware 2.x.
Connects to a Meshtastic node over its WiFi HTTP API. The node must have WiFi configured and be on the same network. Works in all browsers but may be blocked by CORS on some firmware versions.
Connects via WebSocket to Meshtastic TCP port 4403.
WiFi must be configured on the node. Enter only the IP — port 4403 is added automatically.
⚠️ HTTPS pages block ws:// (mixed content) — if blocked, open this admin
page via HTTP or use a local WebSocket proxy.
Mesh Network Nodes
Nodes discovered through BLE/Serial/HTTP connection appear here. Registered Transit Guardian devices are shown with their registration status.
| Node ID | Name | SNR / RSSI | Battery | Last Heard | Registration |
|---|---|---|---|---|---|
| No nodes discovered yet — connect to a node to see the mesh. | |||||
📡 Radio & Network Configuration Reference
Key settings for all Transit Guardian mesh nodes. Configure via the Meshtastic web client.
| Setting | Recommended Value | Location in Client |
|---|---|---|
| Region | US (or your country) | Config → LoRa |
| Modem Preset | LONG_FAST | Config → LoRa |
| Frequency Slot | 20 (US 906.875 MHz) | Config → LoRa |
| Hop Limit | 3 | Config → LoRa |
| Tx Power | 30 dBm (max legal) | Config → LoRa |
| Device Role | ROUTER_CLIENT | Config → Device |
| Node Long Name | Transit-Guardian-XX | Config → Device |
| Node Short Name | TGxx | Config → Device |
| WiFi Mode | Client (join network) | Config → Network |
| MQTT Server | mqtt.meshtastic.org (optional) | Config → MQTT |
| Map Reporting | Enabled | Config → MQTT |
📨 Send Broadcast Message
Sends a text message to ALL nodes on the mesh network (broadcast address 0xFFFFFFFF). The message will be relayed by all nodes within range.
Message History
📜 Activity Log
Persistent log of all admin actions, node connections, messages, and errors.
Stored in your browser's localStorage (up to 500 entries).
AGENTR — Root Orchestrator
Authority: SUPREME (Level 999) · Role: Root Orchestrator
Scope: All Systems · Foundation: Peace
Email: BarbrickDesign@gmail.com
🩺 System Health Monitor
📋 AgentR Orchestration Log
Live feed of AgentR orchestration events. All entries are simultaneously written to the where you can filter by source or level.
⚡ Quick Actions
ntR2
Node ID: !976874c · HW: HELTEC_V3
Node#: 2658568012 · Role: CLIENT
SNR: 6.25 dB · RSSI: -38 dBm
🔌 TCP / WebSocket Direct Connection
Connect directly to your Heltec V3 (ntR2) via WebSocket on port 4403. WiFi must be enabled on the node. If this page is served over HTTPS, browsers block non-TLS WebSocket connections — in that case use the HTTP tab or the official Meshtastic web client.
⚙️ Remote Control Plane
Send commands to the connected node from anywhere on the network. Requires an active connection in any tab (TCP, BLE, Serial, or HTTP).
📡 LoRa Parameter Tuning
Adjust LoRa radio settings for ntR2. Changes are queued and applied on next Admin-capable connection. Best-practice values for the Heltec V3 are pre-filled.
🚀 OTA Firmware & Config Push
⬆️ Push Firmware Update (OTA)
Initiate an OTA update via WiFi. Your Heltec V3 (ntR2) supports OTA once TCP/WiFi is active. Use the Meshtastic flasher or the web client OTA feature.
📋 Push Channel Set URL
Generate and distribute a channel configuration to all nodes in the mesh.
🧬 Autonomous Monitoring Config
AgentR2 continuously monitors the mesh, detects anomalies, and alerts in the Packet Analyzer tab and Activity Log. Configure thresholds below.
!976874c · HELTEC_V3)
📡 Signal Quality
🛰️ GPS / Position
🌡️ Environment Sensors
📊 Session Statistics
📋 Node Registry
| Node ID | Name | SNR | RSSI | Battery | Last Heard | Status |
|---|---|---|---|---|---|---|
| No nodes discovered — connect to a node to see the mesh | ||||||
🛡️ Mesh Guardian — Intrusion Detection
🔬 Live Packet Stream
All packets received via the active connection are captured in real time. Capture begins automatically when any connection is established.
| Time | Dir | From | To | Type | Content |
|---|---|---|---|---|---|
| No packets captured yet — connect to a node to begin capture | |||||
📊 Per-Node Traffic Analysis
Packet counts and message rates per source node this session.
| Node ID | Packets | Messages | Rate (pkt/min) | Status |
|---|---|---|---|---|
| No traffic data yet | ||||
📊 Live Anomaly Scores
Each metric is independently scored using Exponentially Weighted Moving Average (EWMA) baseline learning. Score > 2.5σ triggers a warning; > 4σ triggers a critical alert. Baselines update continuously from live or demo data.
🔮 Predictive Analytics
Linear regression on the last 20 data points per metric. Predicts values 5 samples ahead. Requires ≥ 10 data points per metric to activate.
⚠️ ML Anomaly Timeline
ℹ️ How the ML Engine Works
Algorithm: Exponentially Weighted Moving Average (EWMA) with Bollinger-Band-style anomaly scoring. Each telemetry stream independently maintains a rolling mean (μ) and variance (σ²) using a configurable learning rate α. A new sample is scored by its deviation from μ in units of σ.
Anomaly Threshold: Score > 2.5σ = warning; > 4.0σ = critical. Thresholds configurable in the 🤖 AgentR2 tab.
Predictions: Linear regression (Ordinary Least Squares) on the last 20 samples per metric, projected 5 steps forward. Battery life estimate uses drain-rate extrapolation to 0%.
No External Libraries: Pure JavaScript — no TensorFlow, no Python backend, no network calls. Runs entirely in your browser with zero latency.
Learning Rate (α): SNR/RSSI α=0.15, Battery α=0.05 (slower — battery changes gradually), Temperature α=0.10, Shock α=0.20 (faster — sudden events matter).