Managing irrigation systems for parks and public gardens in smart cities requires real-time monitoring, intelligent automation, and seamless integration with urban infrastructure platforms. Traditional irrigation systems waste water, lack visibility into soil conditions, and cannot adapt to changing weather patterns or city-wide smart city initiatives.

We developed ASIP (Advanced Smart Irrigation Platform) [fictitious name for confidentiality], a comprehensive cloud-based IoT platform from scratch for a confidential smart city technology company. The platform provides complete control over irrigation devices (nodes, sensors, actuators) with cloud-based data management, real-time telemetry processing, and integration with third-party smart city platforms including FIWARE.
The Challenge: Building a Complete IoT Platform from Scratch
The client needed a proprietary solution to replace third-party platforms like Sentilo due to their technical limitations. The system had to support:
Technical requirements:
- Real-time bidirectional communication with field devices via GPRS and LoRa networks.
- Scalable telemetry storage for thousands of sensor readings per minute.
- Flexible integration with multiple smart city platforms (FIWARE, custom APIs).
- Automated irrigation control based on soil moisture, weather conditions, and schedules.
- Multi-tenant architecture supporting multiple municipalities and clients.
- Comprehensive user management with role-based access control.
Deployment context:
- Regional smart city initiative: Large-scale publicly-funded project monitoring water consumption and irrigation management across multiple municipalities in collaboration with telecom infrastructure providers.
- Urban pilot deployment: Critical pilot with smart city platform partner requiring rapid deployment with tight deadlines (November 2019).
- Water utility partnership: Strategic deployment using proprietary frontend for distribution partnership with a major water services company.
Enhancement opportunities identified:
The solution: complete IoT platform built from scratch with modular microservices architecture, real-time telemetry processing, and seamless smart city integration.

Solution Architecture
We designed a modular microservices architecture with four independent services, each handling specific responsibilities for maximum scalability and maintainability.
Core Components
| Component | Technology | Purpose |
|---|---|---|
| ASIP Gateway | Symfony 4 + API Gateway | Single entry point for all API requests with authentication and routing |
| ASIPAPI | Symfony 4 + PostgreSQL | Configuration management, user/role administration, device parameter downloads |
| ASIPFLUX | Symfony 4 + InfluxDB | Telemetry ingestion and storage for high-frequency sensor data |
| ASIPConnector | Symfony 4 + REST Client | Integration layer for third-party platforms (FIWARE, partner APIs) |
| Frontend | React + JWT | User interface for monitoring, configuration, and irrigation control |
Architecture Diagram

Implementation Details
1. Modular Microservices Architecture
The platform’s core strength lies in its clear separation of concerns across four independent services:
ASIP Gateway - API Entry Point:
- Single point of entry for all API requests.
- JWT-based authentication and authorization.
- Request routing to appropriate backend services.
- Rate limiting and security controls.
ASIPAPI - Configuration Management:
- User and role management with granular permissions.
- Park, zone, and device configuration.
- Irrigation schedule management.
- Device parameter downloads (downlink messages).
- PostgreSQL database for relational data.
ASIPFLUX - Telemetry Processing:
- High-frequency sensor data ingestion (uplink messages).
- InfluxDB time-series database for efficient storage.
- Real-time metrics processing.
- Historical data queries and aggregations.
- Alerting system based on sensor thresholds.
ASIPConnector - Integration Layer:
- Translation between ASIP API and third-party platform formats.
- FIWARE entity mapping and data transformation.
- Custom API integration with partner platforms.
- Bidirectional synchronization of device states and configurations.
2. Bidirectional Device Communication
We designed a JSON-based messaging protocol for efficient bidirectional communication between cloud and field devices:
Uplink Messages (Device → Cloud):
{
"device_type": "weather_station",
"creation_date": "2019-07-21T13:24:35.234Z",
"park_id": "001",
"park_name": "Central Park",
"park_zone": 1,
"measures": {
"air_temperature": -12,
"air_humidity": 36,
"barometric_pressure": 1100.7,
"rainfall_hour": 67,
"rainfall_day": 123,
"uv_radiation": 7.2,
"wind_direction": 145,
"wind_speed": 12.3,
"power_status": 55
}
}
Downlink Messages (Cloud → Device):
{
"device_type": "remote_actuator",
"creation_date": "2019-07-21T12:36:06Z",
"park_id": "001",
"park_name": "Central Park",
"park_zone": 1,
"parameters": {
"enabled_sectors": {
"1": true,
"2": true,
"3": false,
"4": false,
"5": true,
"6": true,
"7": true,
"8": true
},
"sector_watering_time": "P30M",
"sector_watering_volume": 85,
"manual_irrigation_start_hour": "08:00:00Z",
"manual_irrigation_end_hour": "21:00:00Z",
"irrigation_mode": "time",
"automatic_irrigation_enabled_weekdays": {
"monday": true,
"tuesday": false,
"wednesday": true,
"thursday": false,
"friday": true,
"saturday": false,
"sunday": false
}
}
}
3. IoT Device Types
The platform supports five types of field devices, each with specific sensors and capabilities:
Weather Station (METEO):
- Air temperature and humidity sensors.
- Barometric pressure measurement.
- Rainfall accumulation (hourly and daily).
- UV radiation monitoring.
- Wind speed and direction.
- Solar panel power status.
Soil Sensor Node:
- Soil moisture measurement (multiple depths).
- Soil temperature monitoring.
- Solar radiation detection.
- Battery/power status reporting.
Remote Actuator:
- Electrovalve control (up to 8 sectors).
- Sector-specific watering time and volume configuration.
- Manual and automatic irrigation modes.
- Incidence reporting per sector.
- Weekday-based scheduling.
Flow Meter:
- Water consumption measurement.
- Flow rate monitoring.
- Irrigation duration tracking.
- Leak detection capabilities.
Electronic Control Unit (U.E.C.):
- Central gateway for LoRa device communication.
- Protocol translation between LoRa and GPRS/cloud.
- Local data buffering and synchronization.
4. FIWARE Integration
For the regional smart city initiative, we developed the ASIPConnector module to integrate with FIWARE smart city platforms:
Key integration features:
- Entity mapping: ASIP device types → FIWARE entity models.
- Data transformation: JSON format conversion between APIs.
- Bidirectional synchronization: Sensor data upload and configuration download.
- Real-time updates: WebSocket-based event streaming.
- Historical data access: Query interface for analytics and reporting.
5. Rapid Deployment for Urban Pilot
The urban pilot deployment required exceptional agility:
Challenge: Deploy a functional system within a tight deadline, with one park (4 electrovalves + weather station).
Solution implemented:
- Simplified React frontend (independent branch) with essential features only.
- Direct integration with partner smart city platform API (POST requests for metrics).
- GPRS communication for all devices (bypassing LoRa complexity).
- Minimal configuration: soil moisture thresholds, watering schedules, data visualization.
Result: Successfully deployed on time, demonstrating platform flexibility and rapid adaptation capabilities.
Technology Stack Deep Dive
Backend: Symfony 4
Why Symfony 4:
- Mature, enterprise-grade PHP framework with excellent documentation.
- Robust dependency injection and service container.
- Doctrine ORM for PostgreSQL with migrations.
- Built-in REST API capabilities with FOSRestBundle.
- JWT authentication with LexikJWTAuthenticationBundle.
- Comprehensive testing tools (PHPUnit integration).
Key Symfony features used:
- Custom console commands for device provisioning and data import.
- Event subscribers for telemetry processing and alerting.
- Doctrine migrations for database schema versioning.
- Symfony Messenger for asynchronous task processing.
- API Platform for automatic REST API generation.
Frontend: React
Why React:
- Component-based architecture for reusable UI elements.
- Virtual DOM for efficient real-time data updates.
- Rich ecosystem of libraries for charts, maps, and forms.
- JWT token management with axios interceptors.
- Responsive design with CSS-in-JS (styled-components).
Key React features:
- Real-time dashboard with WebSocket updates.
- Interactive park maps with device location visualization.
- Configuration forms with validation and error handling.
- Historical data charts (Chart.js integration).
- Mobile-responsive design for field technicians.
Note: This image is not from the actual system for confidentiality reasons. It is used for illustrative purposes only.
Time-Series Database: InfluxDB
Why InfluxDB:
- Purpose-built for time-series data with exceptional write performance.
- Efficient storage with automatic data compression.
- Powerful query language (InfluxQL) for aggregations and downsampling.
- Built-in retention policies for automatic data lifecycle management.
- Native support for tags and fields for flexible querying.
InfluxDB schema design:
Measurement: sensor_readings
Tags: device_id, device_type, park_id, park_zone
Fields: temperature, humidity, soil_moisture, rainfall, etc.
Timestamp: Nanosecond precision
Retention policies:
- Raw data: 90 days (full resolution).
- Hourly aggregates: 1 year.
- Daily aggregates: 5 years.
Communication Protocols
LoRa (Long Range):
- Low-power, long-range wireless protocol for IoT devices.
- Ideal for battery-powered sensors in large parks.
- Centralized gateway (U.E.C.) for device coordination.
- Challenges: Synchronization complexity, message collision handling.
GPRS (General Packet Radio Service):
- Cellular data connectivity for autonomous devices.
- Higher power consumption but more reliable.
- Direct cloud communication without gateway dependency.
- Used in urban pilot for rapid deployment.
Results and Impact
The platform successfully supported multiple large-scale deployments:
Regional Smart City Initiative:
- Multiple municipalities across a large geographic region.
- Dozens of parks with hundreds of sensors and actuators.
- FIWARE integration for smart city data aggregation.
- Real-time water consumption monitoring and optimization.
Urban Pilot Deployment:
- Rapid deployment meeting tight deadline.
- Successful integration with partner smart city platform.
- Demonstrated platform flexibility and adaptability.
Water Utility Partnership:
- Strategic partnership demonstration with major water services company.
- Proprietary frontend showcasing platform capabilities.
- Foundation for distribution agreement.
Technical achievements:
- Scalable architecture: Modular design supporting multiple clients and municipalities.
- Real-time telemetry: InfluxDB handling thousands of sensor readings per minute.
- Flexible integration: Connector architecture enabling seamless third-party platform integration.
- Rapid deployment: Ability to deploy new installations in weeks, not months.
- Comprehensive monitoring: Complete visibility into irrigation systems and water consumption.
Lessons Learned
Architectural decisions:
- Microservices separation proved essential for independent scaling and maintenance.
- InfluxDB was the right choice for time-series data, significantly outperforming relational databases.
- JWT authentication provided secure, stateless API access across all services.
Communication protocols:
- LoRa complexity required significant engineering effort for synchronization and collision avoidance.
- GPRS fallback proved valuable for rapid deployments and troubleshooting.
- JSON messaging protocol provided flexibility for future device types and capabilities.
Integration challenges:
- FIWARE mapping required deep understanding of both platforms’ data models.
- Custom API integration with partner platforms highlighted the value of the connector abstraction layer.
- Bidirectional synchronization needed careful state management to avoid conflicts.
Project management:
- Tight deadlines in pilot deployments demonstrated the importance of architectural flexibility.
- Multiple stakeholders (municipalities, telecom providers, utility companies) required clear communication and documentation.
- Hardware dependencies (device availability, network coverage) impacted deployment timelines.
Technologies Used
Backend:
- Symfony 4 (PHP framework)
- PostgreSQL (relational database)
- InfluxDB (time-series database)
- JWT authentication
- REST API design
- Doctrine ORM
Frontend:
- React (JavaScript library)
- Chart.js (data visualization)
- Styled-components (CSS-in-JS)
- Axios (HTTP client)
- WebSocket (real-time updates)
IoT & Communication:
- LoRa (long-range wireless)
- GPRS (cellular data)
- JSON messaging protocol
- MQTT (optional)
Integration:
- FIWARE (smart city platform)
- Custom REST APIs
- WebSocket streaming
Infrastructure:
- AWS CodeCommit (version control)
- GitLab (CI/CD)
- Docker (containerization)
- Linux servers
Monitoring & Tools:
- Custom alerting system
- InfluxDB dashboards
- Symfony Profiler
- PHPUnit (testing)
Conclusion
Developing ASIP (Advanced Smart Irrigation Platform) from scratch demonstrated the power of well-architected microservices for complex IoT platforms. The modular design enabled rapid adaptation to diverse deployment scenarios (regional smart city initiatives, urban pilots, utility partnerships) while maintaining code quality and system reliability.
The platform’s success in multiple large-scale projects validated key architectural decisions: Symfony 4 for robust backend services, React for responsive frontends, InfluxDB for efficient telemetry storage, and a flexible connector layer for seamless smart city integration.
This project showcased our ability to design and implement complete end-to-end IoT solutions, from low-level device communication protocols to high-level smart city platform integration, all while meeting aggressive deadlines and adapting to changing requirements.
Need to develop a scalable IoT platform?
If your organization faces similar challenges:
- Managing thousands of IoT devices with diverse communication protocols (LoRa, GPRS, MQTT).
- Real-time telemetry processing and efficient time-series data storage.
- Smart city platform integration with FIWARE and municipal systems.
- Interactive dashboards for IoT data visualization and analysis.
- Scalable microservices architecture adaptable to different deployment scenarios.
As a full-stack developer with experience in IoT, microservices architecture, and smart cities, we can help you design and implement complete IoT platforms from device protocols to enterprise system integration.
Specialized in Symfony, React, InfluxDB, IoT protocols (LoRa, MQTT), Docker, and smart city platform integration.
Get in touch →
About the author
Daniel López Azaña
Tech entrepreneur and cloud architect with over 25 years of experience transforming infrastructures and automating processes. Specialist in AI/LLM integration, Rust and Python development, and AWS & GCP architecture. Restless mind, idea generator, and passionate about technological innovation and AI.
Related projects

Live Car Auction Platform - Real-Time Bidding System with WebSockets
Full-featured web application for conducting live car auctions simultaneously onsite and online, featuring real-time websocket-based bidding engine, responsive multi-device interface, and comprehensive auction management system built with AngularJS, Symfony, and AWS infrastructure.

IG.com Rust Client - Open Source SDK for Algorithmic Trading
Professional Rust SDK for IG.com REST and Streaming APIs. First complete Rust client library enabling integration with algorithmic trading platforms, account management, order execution, and real-time market data. Published on crates.io as open-source contribution.

GeoWebcams - Intelligent Webcam Discovery Platform
Comprehensive platform combining Python data processing, Rust web applications, and AI-powered workflows to discover, validate, and serve thousands of live webcams from around the world, with advanced geographic search and live streaming capabilities.
Comments
Submit comment