@openrfid/mqtt
v1.0.0
Published
MQTT client and telemetry publisher plugin for OpenRFID Simulator.
Readme
@openrfid/mqtt
MQTT IoT Broker Publisher & Telemetry Protocol Plugin for OpenRFID Simulator
🚀 Overview
@openrfid/mqtt is an IoT protocol plugin for OpenRFID Simulator. It connects virtual simulated RFID readers to local or cloud MQTT brokers (e.g. EMQX, Mosquitto, AWS IoT Core, HiveMQ), publishing real-time tag scan telemetry and health diagnostics to structured MQTT topics (openrfid/readers/{readerId}/tags).
Developed & Maintained by RFID Software India Private Limited.
📦 Installation
# npm
npm install @openrfid/mqtt
# pnpm
pnpm add @openrfid/mqtt💻 Code Example
1. Register MQTT Publisher Plugin
import { SimulationEngine } from '@openrfid/simulator';
import { MqttPlugin } from '@openrfid/mqtt';
const engine = new SimulationEngine();
// Configure MQTT Plugin
const mqttPlugin = new MqttPlugin({
brokerUrl: 'mqtt://localhost:1883',
topicPrefix: 'openrfid/telemetry',
clientId: 'openrfid-sim-01',
qos: 1
});
// Register plugin into simulation lifecycle
await engine.pluginManager.registerPlugin(mqttPlugin);
await engine.start();
console.log('MQTT Plugin publishing tag telemetry to mqtt://localhost:1883');📡 MQTT Topic Structure & JSON Payload
Published Topic: openrfid/telemetry/readers/{readerId}/tags
{
"epc": "E28011700000020C3C9101AB",
"readerId": "GATE-WAREHOUSE-01",
"antennaPort": 1,
"rssi": -58.5,
"readCount": 14,
"timestamp": 1721473200000
}🌐 Monorepo Ecosystem
| Package | Description |
| :--- | :--- |
| @openrfid/plugin-api | Plugin lifecycle interfaces & sandbox manager |
| @openrfid/simulator | High-throughput inventory simulation engine |
| @openrfid/websocket | WebSocket real-time tag stream broadcaster |
📄 License & Corporate Support
Licensed under the MIT License.
Brought to you by RFID Software India Private Limited.
For enterprise RFID middleware, hardware drivers, or custom protocol plugins, visit rfidsoftwares.com.
