MedMonitor: Open-Source Medical IoT Telemetry Gateway (SaMD)

License: MIT Compliance Region Tech Stack

MedMonitor is an open-source, pre-compliant Medical IoT Gateway and real-time vital signs dashboard, designed to demonstrate feasibility for MIC@Home (Mobile Inpatient Care at Home) and hospital step-down wards in the ASEAN region.

๐Ÿ“ GitHub Repository ยท ๐Ÿ“„ View Docs


โš ๏ธ IMPORTANT DISCLAIMER โ€“ NOT A MEDICAL DEVICE

This software is provided for RESEARCH, DEVELOPMENT, INVESTIGATIONAL/PROTOTYPE, AND EDUCATIONAL PURPOSES ONLY.
It is NOT a medical device, NOT cleared or approved by any regulatory agency (such as Singapore HSA, Malaysia MDA, US FDA, or EMA), and NOT intended for clinical use.

๐Ÿ”ฌ Data Source & Synthetic Nature

MedMonitor is a functional prototype. All physiological data processed by this system (Heart Rate, SpO2, BP) is derived from public Kaggle ICU datasets or generated via synthetic simulation. This project does not collect, process, or store real-world Patient Identifiable Information (PII) or Protected Health Information (PHI).

โš–๏ธ Investigational Use Only (IUO)

This software is intended to demonstrate technical feasibility for medical IoT telemetry. Any use of this software in a clinical setting or with real patients is strictly prohibited unless conducted under a formal Investigational Testing Exemption (ITE) or within a sanctioned Regulatory Sandbox (e.g., Singapore MIC@Home or Malaysia MOH Sandbox) under the supervision of qualified medical professionals.

โŒ What this software is NOT

โœ… What this software IS

๐Ÿ”’ Liability Waiver

THE SOFTWARE IS PROVIDED โ€œAS ISโ€, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

By using this software, you confirm that you understand and agree to these terms.


๐Ÿ›‘ The Problem & ๐Ÿ’ก The Solution

Hospital IT architects and researchers frequently encounter the same roadblocks when deploying medical telemetry. MedMonitor explicitly solves these core industry challenges:

1. Alarm Fatigue in Step-Down Wards

2. Network Instability in MIC@Home

3. Strict Regulatory & Privacy Compliance


๐Ÿ—๏ธ System Architecture

MedMonitor uses a modern, decoupled architecture designed for high-throughput sensor telemetry.

graph TD
    subgraph Edge["MIC@Home / Ward Edge"]
        D1[Patient Sensor 1] -->|Raw Vitals| Sim[Edge Buffer Gateway]
        D2[Patient Sensor 2] -->|Raw Vitals| Sim
        Sim -- "REST (JSON) + X-Api-Key" --> API
    end
    subgraph Backend [".NET 8 Application Server"]
        API[Ingestion API] --> RS[Reading Service / MEWS Logic]
        RS --> |Save| ORM[EF Core]
        RS --> |Broadcast| SigR[SignalR WebSocket Hub]
    end
    subgraph Database ["PostgreSQL (Supabase/AWS)"]
        ORM -- "Session Pooling (5432) + RLS" --> DB[(PostgreSQL)]
        DB --> Aud[HMAC-SHA256 Audit Log]
    end
    subgraph Frontend["React 19 SPA"]
        SigR -- "Real-time Telemetry" --> UI[Clinical Dashboard]
        UI -- "JWT Authentication" --> API
    end

โš™๏ธ Tech Stack & Regulatory Mapping

Component Technology Regulatory / Security Purpose
Backend API .NET 8 (C#) High-performance async ingestion; handles EF Core execution strategies.
Real-time Engine SignalR (WebSockets) Sub-second telemetry propagation to clinical dashboards.
Database PostgreSQL (Supabase) Managed JSONB datastore; Port 5432 Session Pooling for RLS enforcement.
Frontend React 19 + Vite + Recharts Append-only UI rendering to prevent DOM blocking under high data loads.
Authentication JWT + TOTP (2FA) Secures clinical API endpoints; bakes dynamic RBAC capabilities into claims.
Observability VictoriaMetrics + Loki 15-day system metric retention (PMS evidence for regulatory audits).
PDF Reporting QuestPDF (.NET) Generates end-of-shift clinical handover reports offline without external dependencies.

โš–๏ธ MedMonitor vs. Traditional Medical IoT

Feature / Capability Traditional IoT Gateways MedMonitor
Audit Log Integrity Standard text/DB logs (editable by DBAs) HMAC-SHA256 Hash Chain โ€” cryptographically tamper-proof
Device Authentication Static API keys or IP whitelisting Mutual TLS (mTLS) using X.509 client certificates
Cross-Ward Data Leakage Application-level filtering only PostgreSQL Row-Level Security (RLS) injected into DB session pools
Alarm Fatigue Mitigation Triggers on every threshold breach IEC 60601-1-8 Compliant โ€” 5-min rolling suppression + MEWS scoring
Regulatory Alignment Black-box compliance Pre-mapped for IEC 62304 Class B & HSA CLS-MD Level 2
Deployment Cost High licensing fees, vendor lock-in Open-source, deployable on PaaS (Render / AWS / Supabase)

๐Ÿ›ก๏ธ Built for Compliance Reviewers & Healthcare IT

MedMonitor implements a strict Dynamic RBAC (Role-Based Access Control) where the API role (medmon_api) has its UPDATE and DELETE privileges explicitly revoked for clinical telemetry and audit logs โ€” ensuring full compliance with data immutability requirements under zero-trust architecture guidelines for medical devices.


๐Ÿš€ Getting Started

# 1. Clone the repository
git clone https://github.com/Calaweh/medmonitor-iot-gateway.git
cd medmonitor-iot-gateway

# 2. Copy environment variables
cp .env.example .env

# 3. Start all services with Docker
docker compose up --build

See the full setup guide and configuration options in the repository README.


MedMonitor is an open-source project by Calaweh ยท Licensed under MIT