FDRS (Falcons Disaster Response System) is a comprehensive, multi-platform disaster management ecosystem designed to bridge the critical communication gap between disaster-affected civilians and government emergency response agencies. The system implements a layered architecture comprising four principal modules: (1) a Flutter-based cross-platform mobile application for real-time SOS signal transmission with a three-tier delivery fallback chain, (2) a React.js administrative web portal for centralized multi-agency coordination and real-time geospatial signal monitoring, (3) an Ethereum blockchain-powered donation platform ensuring transparent, tamper-proof relief fund management, and (4) a native Android application for legacy device support.
The platform leverages Firebase Realtime Database for sub-second data synchronization, Google Maps API for geospatial intelligence, an AI-powered chatbot driven by Meta's LLaMA 3.3 (70B) model for multilingual crisis assistance, and Solidity-based smart contracts on the Ethereum Sepolia testnet for immutable financial audit trails. FDRS was engineered to address real-world challenges in disaster relief coordination—latency in SOS delivery under degraded network conditions, lack of transparency in donation management, and fragmented inter-agency communication.
- Introduction
- System Architecture
- Module I — Flutter Mobile Application
- Module II — Administrative Web Portal
- Module III — Blockchain Donation Platform
- Module IV — Native Android Application
- AI-Powered Disaster Assistance
- Environmental Impact & Relief Analysis
- Technology Stack
- Live Demo & Credentials
- Installation & Setup
- Contributing
- Disclaimer
- Authors & Contributors
- Contact
Natural and man-made disasters pose an existential threat to human life, infrastructure, and economic stability. According to the United Nations Office for Disaster Risk Reduction (UNDRR), disasters displaced over 32 million people in 2023 alone. The primary bottleneck in disaster response is not the absence of relief resources but the coordination latency between distressed civilians and emergency responders.
FDRS was conceived to mitigate this latency through a multi-pronged technological approach:
- Instant SOS Signal Delivery: A three-tier fallback mechanism ensures that distress signals reach authorities even under complete network failure—first via Firebase Realtime Database, then via radio mesh links, and finally through local offline caching with auto-retry on connectivity restoration.
- Centralized Multi-Agency Dashboard: Government departments (NDRF, CRPF, Police, Fire Brigades, Hospitals) operate from a unified real-time dashboard that displays SOS signals as geolocated markers on an interactive map, enabling intelligent resource routing.
- Transparent Blockchain Donations: Every relief donation is processed through an Ethereum smart contract, creating an immutable, publicly auditable financial trail that eliminates corruption and fund misuse.
- AI-Powered Crisis Intelligence: A large language model (LLaMA 3.3 70B Instruct Turbo) provides multilingual, context-aware disaster guidance to both civilians and responders.
FDRS follows a modular, service-oriented architecture where each sub-system operates independently while sharing a common Firebase Realtime Database as the central data bus.
The Flutter module serves as the primary civilian-facing interface, enabling disaster-affected individuals to send SOS distress signals, access emergency knowledge resources, and manage their user profiles. Built with Flutter for true cross-platform deployment (Android, iOS, Web, Desktop), the application follows the MVVM (Model-View-ViewModel) architectural pattern with Provider-based state management.
The SOS screen is the centerpiece of the mobile application. It implements a long-press activation mechanism with a visually immersive water-fill animation to prevent accidental triggers while maintaining accessibility during high-stress scenarios.
Activation Flow:
- The user presses and holds the SOS button for 2 seconds.
- A reddish-orange water-like fill animation progressively covers the button using a custom
WaterClipper(bezier-curve basedCustomClipper). - Haptic feedback (vibration) is triggered upon successful activation.
- The distress signal—containing the user's live GPS coordinates, device build number, and UTC timestamp—is dispatched through the three-tier delivery chain.
Three-Tier Distress Signal Delivery Chain:
| Tier | Mechanism | Timeout | Description |
|---|---|---|---|
| 1 | Firebase RTDB | 5 seconds | Primary channel. Signal is written to /signals/{userId}_{buildNumber} in Firebase Realtime Database for instant propagation to the admin dashboard. |
| 2 | Radio Mesh Link | 1 second (simulated) | Fallback for RTDB failure. Placeholder for LoRa/mesh radio SDK integration—designed for areas with zero internet connectivity. |
| 3 | Offline Queue | Persistent | Last-resort safety net. Signals are serialized to a local JSON file (pending_distress_signals.json) on the device's file system and automatically flushed to RTDB when connectivity is restored via connectivity_plus listener. |
This architecture ensures zero signal loss—even in the most adverse network conditions, the distress signal is persisted locally and will eventually reach authorities.
Key Implementation Details:
- Status Indicators: Real-time cards display the status of Location Services (GPS accuracy), Network Connection (Firestore reachability), and Signal Readiness (authentication state).
- Authentication Modes: Supports authenticated SOS (linked to user profile) and anonymous SOS (for unregistered users), ensuring no one is excluded from sending emergency alerts.
- Device Fingerprinting: Each signal includes the Android
displaybuild number (viadevice_info_plus), enabling device-level signal deduplication and tracking.
The Knowledge Base screen provides a curated repository of disaster preparedness protocols, emergency guidelines, and reference documents. It functions as a self-contained educational resource that civilians can access even in offline scenarios.
Content Categories:
- Emergency Protocols: Quick-reference cards for Earthquake Response, Flood Safety, and Fire Evacuation procedures, each linking to authoritative external resources (NDMA, Red Cross, NFPA).
- Official Documents: Downloadable PDF guides including the NDMA Disaster Management Guidelines, accessible via
url_launcherfor web resources oropen_filexfor locally bundled assets. - Search Functionality: A top-of-page search bar enables rapid lookup within the knowledge base content.
The Profile screen enables authenticated users to manage their personal information, which is persisted to Firebase Realtime Database under /users/{uid}.
Profile Fields:
- Personal Information: Name, Mobile Number (with custom
MobileNumberFormatterfor regional formats), Age - Medical Information: Blood Group, Medical Conditions (multi-line textarea)
- Location Data: Address details for pre-positioning relief resources
All profile data is read from and written to RTDB via the DatabaseService, with reactive UI updates through ProfileViewModel (ChangeNotifier pattern).
The AuthService (extending ChangeNotifier) provides a flexible, multi-method authentication layer:
| Method | Implementation | Use Case |
|---|---|---|
| Email/Password | FirebaseAuth.signInWithEmailAndPassword |
Standard registration and login |
| Google Sign-In | GoogleSignIn → GoogleAuthProvider.credential → FirebaseAuth.signInWithCredential |
One-tap social login |
| Anonymous | FirebaseAuth.signInAnonymously |
Guest access for emergency-only users |
Upon successful authentication (any method), user metadata (UID, email, last login timestamp) is automatically persisted to RTDB. Error codes from Firebase are mapped to human-readable messages via _mapAuthError() for clear user feedback.
The MainScreen implements a glassmorphism-styled bottom navigation bar using BackdropFilter with ImageFilter.blur, providing three primary tabs:
- Home (SOS Screen): Default landing tab for emergency actions
- Info (Knowledge Base): Disaster preparedness resources with amber accent highlighting
- Profile (Profile/Login): Conditional rendering—authenticated users see their profile, guests see the login screen
Screen transitions are animated using AnimatedSwitcher with a 500ms FadeTransition for smooth, polished navigation.
The web portal is a React.js single-page application (SPA) built with Vite, designed for government department administrators to monitor, analyze, and respond to incoming distress signals in real time.
The Dashboard component is the operational nerve center, providing:
- Live Signal Stream: All SOS signals stored under
/usersin Firebase RTDB are streamed in real time viaonValuelisteners. Each signal's raw GPS coordinates are reverse-geocoded into human-readable addresses using the OpenStreetMap Nominatim API (nominatim.openstreetmap.org/reverse). - Interactive Google Maps Visualization: The
MapComponentembeds a fully interactive Google Maps instance (via the Maps JavaScript API) that dynamically plots markers for every active distress signal. The map is centered on coordinates[18.5316, 73.8670](Pune, India) by default and supports zoom/pan. - Hotspot Detection Engine: The dashboard algorithmically clusters SOS signals by rounding latitude/longitude to the nearest integer degree. Areas with ≥ 10 signals within the same grid cell are flagged as Critical Hotspots (
⚠️ ), enabling authorities to prioritize high-density disaster zones. - Department Context Panel: Displays the logged-in administrator's department details (name, camp type, address) fetched from
/admins/{uid}in RTDB. - Signal-to-Maps Deep Linking: Each signal card in the Recent Signals list is a clickable link that opens Google Maps with a search query for the signal's reverse-geocoded address, facilitating rapid navigation for field responders.
The platform supports concurrent operation by multiple government agencies, each authenticated into their own admin account:
- NDRF (National Disaster Response Force)
- CRPF (Central Reserve Police Force)
- Local Police Stations
- Fire Brigades
- Hospitals & Medical Centers
Each department's admin dashboard provides identical real-time signal visibility, enabling synchronized, non-duplicative response coordination across agencies.
The web portal implements a full authentication flow with:
- Signup (
Signup.jsx): New department registration with Firebase AuthcreateUserWithEmailAndPassword, storing admin details (department name, type, address) under/admins/{uid}. - Login (
Login.jsx): Department authentication withsignInWithEmailAndPassword. - Protected Routes (
PrivateRoute.jsx): Dashboard access is gated behind authentication state, redirecting unauthenticated users to the login page. - Landing Page (
LandingPage.jsx): Public-facing entry point with navigation to login/signup flows.
The donation module is a standalone React.js + Ethers.js web application that combines the transparency of blockchain technology with the usability of modern web interfaces. It enables donors to contribute relief funds via Ethereum cryptocurrency, with every transaction recorded immutably on-chain.
The platform interacts with a custom Solidity smart contract deployed on the Ethereum Sepolia Testnet (Chain ID: 11155111).
Contract Interface (ABI):
function donate() external payable // Accepts ETH donations
function getTotalRaised() external view returns (uint256) // Returns cumulative donationsKey Contract Interactions:
donate(signer, amount): Converts a human-readable ETH amount (e.g.,"0.01") to wei usingethers.parseEther(), then invokes the contract'sdonate()function. MetaMask prompts the user for transaction confirmation. The transaction hash is returned immediately for non-blocking UI feedback.getTotalRaised(): Calls the contract's view function via a read-onlyJsonRpcProvider(no wallet required), converts the returned BigInt from wei to ETH, and returns a formatted string.
The wallet.js module provides seamless MetaMask connectivity:
- Detection: Checks for
window.ethereum.isMetaMaskto verify MetaMask installation. - Account Access: Requests account access via
eth_requestAccounts. - Network Auto-Switch: Automatically switches the user's wallet to the Sepolia testnet. If Sepolia is not configured, it programmatically adds the network with the correct RPC URL (
ethereum-sepolia-rpc.publicnode.com) and block explorer (sepolia.etherscan.io).
Campaigns serve as the organizational unit for relief fundraising. The system is backed by Firebase Realtime Database under /campaigns.
Campaign Lifecycle:
| Phase | Action | Implementation |
|---|---|---|
| Creation | Admin or donor creates a new campaign | createCampaign() pushes to Firebase with title, tag, description, goal (INR), creator wallet address, and timestamp |
| Real-Time Subscription | All clients receive live updates | subscribeCampaigns() uses onValue listener with deduplication by title and newest-first sorting |
| Donation Recording | Donation amount is converted and tracked | recordDonation() converts ETH to INR (at ≈₹2,50,000/ETH), increments raised, recalculates percent, and auto-closes campaigns at 100% |
| Seeding | Default campaigns populate empty databases | seedDefaultCampaigns() provisions three example campaigns (Assam Floods, Uttarakhand Earthquake, Cyclone Reena) on first load |
Campaign Tags & Visual System:
Each campaign is categorized with a disaster type tag—Flood Relief, Earthquake, Cyclone, Drought, Fire, Pandemic, or Other—each rendered with a distinctive color-coded banner via CampaignBanner inline SVG components.
UI Components:
CreateCampaignModal: Form for creating new campaigns with title, tag (dropdown), description, and goal amount.DonationModal: Wallet-connected donation interface with ETH amount input, connected wallet display, and transaction state management.KnowMoreModal: Expanded campaign details including description, raised/goal breakdown, and status badge.CampaignCard: Grid-rendered card with progress bar, raised amount (INR formatted), and action buttons (Donate, Know More).HowItWorks: Three-step explainer section (Create Campaign → Share & Connect → Track Impact).AboutUs: Mission statement and organizational information.
The FDRS-Android module is a standalone native Android application built with Kotlin/Java and Gradle (KTS). It serves as a legacy-compatible alternative to the Flutter mobile app, providing core SOS signal generation functionality for devices that may not support the Flutter runtime.
Core Capabilities:
- SOS distress signal generation with GPS coordinate extraction
- Firebase Realtime Database integration for signal transmission
- Device-level location tracking and metadata collection
- Compatible with Android API levels specified in the Gradle configuration
The FDRS web portal integrates an AI chatbot (Bot.jsx) powered by Meta's LLaMA 3.3 70B Instruct Turbo model, accessed via the Together AI inference API (api.together.xyz/v1/chat/completions).
Chatbot Capabilities:
- Contextual Disaster Guidance: Users can ask about evacuation procedures, first-aid protocols, shelter locations, and resource availability. The model processes conversational history for multi-turn contextual responses.
- Multilingual Support: Leveraging the LLaMA 3.3 model's training on 100+ languages, the chatbot can assist users in their native language, critical for India's linguistically diverse disaster zones.
- Markdown-Rich Responses: Bot responses are rendered via
ReactMarkdownwith custom component overrides for headings, lists, bold text, and paragraphs—ensuring clear, structured, and readable crisis information.
Technical Configuration:
- Model:
meta-llama/Llama-3.3-70B-Instruct-Turbo - Temperature:
0.7(balanced creativity/accuracy for crisis scenarios) - Max Tokens:
1000(sufficient for detailed procedural guidance)
FDRS provides data-driven environmental and relief intelligence through its dashboard analytics:
- Real-Time Damage Assessment: The dashboard aggregates SOS signal density, geographic distribution, and temporal patterns to generate live damage assessment reports for incident commanders.
- Predictive Hotspot Detection: The algorithmic clustering engine (rounding coordinates to integer degrees and flagging cells with ≥10 signals) identifies emerging disaster hotspots, enabling preemptive resource staging.
- Reverse Geocoding Intelligence: Every SOS signal's raw GPS coordinates are resolved to human-readable addresses via OpenStreetMap's Nominatim service, providing street-level situational awareness.
- Geospatial Resource Allocation: Admin department addresses (stored in
/admins) are mapped alongside civilian SOS signals, enabling distance-optimized dispatch of the nearest available response unit.
Experience the platform live:
| Platform | URL |
|---|---|
| Web Portal | https://fdrs.vercel.app |
Test Credentials
Email: test@gmail.com
Password: testadmin
| Technology | Module | Purpose |
|---|---|---|
| Flutter (Dart) | FDRS-Flutter | Cross-platform mobile application (Android, iOS, Web, Desktop) with MVVM architecture and Provider state management |
| React.js 18 | FDRS-Webpage, FDRS-Donation | Single-page applications for admin dashboard and donation portal |
| Vite | FDRS-Webpage, FDRS-Donation | Next-generation build tooling with hot module replacement (HMR) |
| Kotlin/Java | FDRS-Android | Native Android app with Gradle KTS build system |
| Technology | Purpose |
|---|---|
| Firebase Realtime Database | Sub-second data synchronization for SOS signals (/signals), user data (/users), admin metadata (/admins), and campaigns (/campaigns) |
| Firebase Authentication | Multi-method auth: Email/Password, Google Sign-In, Anonymous—shared across Flutter and Web modules |
| Cloud Functions (Node.js) | Serverless backend logic, automation triggers, and real-time event processing |
| Technology | Purpose |
|---|---|
| Solidity | Smart contract for transparent, tamper-proof donation tracking with donate() and getTotalRaised() functions |
| Ethers.js v6 | JavaScript library for Ethereum contract interaction, transaction signing, and wei/ETH conversion |
| MetaMask | Browser wallet for user authentication, transaction signing, and Sepolia testnet management |
| Ethereum Sepolia Testnet | Test network for development and demonstration (Chain ID: 11155111, RPC: ethereum-sepolia-rpc.publicnode.com) |
| Technology | Purpose |
|---|---|
| Meta LLaMA 3.3 70B Instruct Turbo | Large language model for multilingual disaster assistance chatbot |
| Together AI API | Inference hosting for LLaMA model with low-latency chat completions endpoint |
| ReactMarkdown | Markdown rendering engine for structured AI response display |
| Technology | Purpose |
|---|---|
| Google Maps JavaScript API | Interactive map visualization with dynamic marker placement for SOS signals |
| OpenStreetMap Nominatim | Free reverse geocoding service for converting GPS coordinates to human-readable addresses |
Flutter location Plugin |
Native GPS access on mobile devices with runtime permission handling |
device_info_plus |
Android device fingerprinting (build number extraction) for signal deduplication |
| Package | Purpose |
|---|---|
firebase_core, firebase_auth, firebase_database |
Firebase ecosystem integration |
google_sign_in |
Google OAuth 2.0 social login |
provider |
Reactive state management (ChangeNotifier pattern) |
location, permission_handler |
GPS access and runtime permission requests |
connectivity_plus |
Network state monitoring for offline queue auto-flush |
vibration |
Haptic feedback on SOS activation |
url_launcher, open_filex |
External URL/document opening in Knowledge Base |
path_provider |
Local file system access for offline distress signal persistence |
| Service | Purpose |
|---|---|
| Vercel | Hosting with CI/CD for web client (auto-deploys on git push) |
| Firebase Hosting | Serverless deployment for backend APIs and database rules |
| Google Play Store (Planned) | Upcoming distribution channel for the Flutter and Android apps |
- Flutter SDK (≥ 3.0) for the mobile application
- Node.js (≥ 18) and npm/bun for web modules
- MetaMask browser extension for blockchain donation testing
- Firebase Project with Realtime Database and Authentication enabled
cd FDRS-Flutter
flutter pub get
flutter runcd FDRS-Webpage
npm install
# Create .env with Firebase and Google Maps API keys
npm run devcd FDRS-Donation
npm install
# Create .env with Firebase keys, contract address, and Together API key
npm run devcd FDRS-Android
./gradlew build
# Open in Android Studio and run on device/emulatorWe welcome contributions from the open-source community. To contribute:
- Fork the repository
- Create a feature branch (
git checkout -b feature/your-feature-name) - Commit your changes with descriptive messages (
git commit -m 'Add feature: description') - Push to your branch (
git push origin feature/your-feature-name) - Open a Pull Request with a detailed description of your changes
Please ensure your code follows the existing project conventions and includes relevant documentation.
FDRS is a research prototype developed for academic demonstration, hackathon presentation, and proof-of-concept validation. For real-world deployment in active disaster scenarios, the following are prerequisite:
- Official partnerships with government disaster management agencies (NDMA, NDRF, State SDMAs)
- Legal compliance with data protection regulations (IT Act 2000, DPDP Act 2023)
- Verified integration with official emergency communication infrastructure
- Security audits and penetration testing for all public-facing modules
- Smart contract audits by certified blockchain security firms
-
Sarthak Patil
GitHub: Precise-Goals -
Gaurav Chaudhari
GitHub: Chgauravpc -
Prathamesh Kolhe
GitHub: prathamesh-6099 -
Utkarsh Vidwat
GitHub: Utkarsh9090
Email: sarthakpatil.ug@gmail.com
Project Repository: https://github.com/Precise-Goals/Complete-FDRS






