An Integrated Simulink and Iot Framework for Data Acquisition and Control using Custom Driver Blocks
DOI:
https://doi.org/10.63746/njtd.v22i5.4034Keywords:
Data acquisition, Driver blocks, Embedded Systems, IoT, S-Function, Simulink environmentAbstract
This study deals with the design and implementation of a fully modularized, embedded system equipped with Internet of Things (IoT) technology, which is developed in the Simulink integrated control. A key contribution of the work is the utilization of the Simulink environment only to conduct object-oriented models without the use of the traditional script-based programming methods. It describes a combination of extensive integration of custom driver blocks through supplementary libraries and S-function algorithm development combined with sensor reading calibration and filtering that further extends the flexibility of the workflow. The performance of the system was validated by creating a real-time data acquisition, on/off control logic, and cloud-based data visualization through ThingSpeak platform, demonstrated by a case study of an irrigation system in an arid area. The system is versatile, as it is modular and can be adapted to embedded systems in arid, resource-constrained regions, making it suitable for applications in intelligent control and automation in many other applications beyond irrigation.
References
Al-Omary, A., H. M. AlSabbagh & H. Al-Rizzo (2018). Cloud based IoT for smart garden watering system using Arduino Uno. Smart Cities Symposium (SCS ’18), University of Bahrain, 249–254.
Alldatasheet (2024). DS18B20 Dallas. Available online at: https://www.alldatasheet.com. Accessed July 20, 2025.
Arduino (2024). map() – Arduino reference. Available online at: https://www.arduino.cc/reference/en/language/functions/math/map/. Accessed July 29, 2025.
Barrozo, J., (2024). How to Use the Arduino map() Function: A Complete Guide. Flux AI Blog, 11 July. Available online at: https://www.flux.ai/p/blog/how-to-use-the-arduino-map-function-a-complete-guide. Accessed September 1, 2025.
Belkadi, A., D. Mezghani & A. Mami (2020). Design and implementation of FLC applied to a smart greenhouse. Engenharia Agrícola, 40(6), 777–790. https://doi.org/10.1590/1809-4430-Eng.Agric.v40n6p777-790/2020
Bona, E., N. Massa, O. Toumatia, G. Novello, P. Cesaro, V. Todeschini, L. Boatti, F. Mignone, H. Titouah, A. Zitouni, G. Lingua, F. Vuolo & E. Gamalero (2021). Climatic Zone and Soil Properties Determine the Biodiversity of the Soil Bacterial Communities Associated to Native Plants from Desert Areas of North-Central Algeria. Microorganisms, 9(7), 1359. https://doi.org/10.3390/microorganisms9071359
Caseiro, L., D. Caires & A. Mendes (2022). Prototyping Power Electronics Systems with Zynq-Based Boards Using Matlab/Simulink—A Complete Methodology. Electronics, 11(7), 1130. https://doi.org/10.3390/electronics11071130
Helpful (2024). Filters on data. Available online at: https://helpful.knobs-dials.com/index.php/Filters_on_data. Accessed July 29, 2025.
Hurts, J., (2024). Rensselaer Arduino Support Package Library (RASPLib). GitHub. Available online at: https://www.mathworks.com/matlabcentral/fileexchange/62702-rensselaer-arduino-support-package-library-rasplib. Accessed August 25, 2025.
Jackson, D., B. Tannenbaum & W. Jachimczyk (2006). Adoption, impact, and vision of model-based design. Proceedings of SPIE, the International Society for Optical Engineering, 6228, 622817. https://doi.org/10.1117/12.665078
Kshirsagar, K., P. Shah & R. Sekhar (2022). Model based design in industrial automation. 2022 6th International Conference on Computing, Communication, Control and Automation (ICCUBEA), 1–6. https://doi.org/10.1109/iccubea54992.2022.10010895
Laktionov, I. S., O. V. Vovna, Y. O. Bashkov, A. A. Zori & V. A. Lebediev (2019). Improved Computer-oriented Method for Processing of Measurement Information on Greenhouse Microclimate. International Journal of Bioautomation, 23(1), 71–86. https://doi.org/10.7546/ijba.2019.23.1.71-86
Liu, T., (2024). DHT22 (AM2302) digital-output relative humidity & temperature sensor/module. Aosong Electronics Co., Ltd. Available online at: https://www.alldatasheet.com. Accessed July 20, 2025.
Mashhadany, Y. A., H. R. Alsanad, M. A. Al-Askari, S. Algburi & B. A. Taha (2024). Irrigation intelligence—enabling a cloud-based Internet of Things approach for enhanced water management in agriculture. Environmental Monitoring and Assessment, 196(5), 438. https://doi.org/10.1007/s10661-024-12606-1
MathWorks (2025). Build S-Functions Automatically Using S-Function Builder. MATLAB Simulink Documentation. Available online at: https://www.mathworks.com/help/simulink/slref/sfunctionbuilder.html. Accessed August 25, 2025.
MathWorks (2025). Internet of Things – MATLAB & Simulink for IoT applications. Available online at: https://www.mathworks.com/solutions/internet-of-things.html. Accessed August 25, 2025.
MathWorks (2025). Model-based design. Available online at: https://www.mathworks.com/solutions/model-based-design.html. Accessed August 25, 2025.
MathWorks (2025). Simulink Documentation. Available online at: https://www.mathworks.com/help/simulink/index.html. Accessed August 25, 2025.
Morgan, E. J., (2014). HC-SR04 ultrasonic sensor. Alldatasheet. Available online at: https://www.alldatasheet.com. Accessed July 20, 2025.
Nicola, C., M. Nicola, M. Ni?u, D. Sacerdo?ianu & A. Aciu (2021). Real-Time Sensorless Control of the PMSM based on Genetic Algorithm, Sliding Mode Observer, and SCADA Integration. Annals of the University of Craiova Electrical Engineering Series, 45(1), 24–31. https://doi.org/10.52846/aucee.2021.1.04
Roslovets, P., (2024). Arduino additional sensors library (DHT, LPS331). GitHub. Available online at: https://github.com/roslovets/Arduino_Additional_Sensors_Simulink_Library_DHT_LPS331/releases/tag/v1.0.1. Accessed August 25, 2025.
Schwamback, D., M. Persson, R. Berndtsson, L. E. Bertotto, A. N. A. Kobayashi & E. C. Wendland (2023). Automated Low-Cost Soil Moisture Sensors: Trade-Off between Cost and Accuracy. Sensors, 23(5), 2451. https://doi.org/10.3390/s23052451
Tyler, N., (2020). How to integrate DS18B20 with Arduino in Simulink / Simulink S-function builder basics-1 temp Probe1. YouTube. Available online at: https://www.youtube.com/watch?v=0OClHIdCyDg. Accessed August 25, 2025.
United Electronic Industries (2025). Model-Based Design Tutorial & Reference Guide – Aerospace DAQ, Test, HIL. UEI. Available online at: https://www.ueidaq.com/model-based-design-tutorial-reference-guide. Accessed August 20, 2025.
Weather Atlas (2024). Yearly & monthly weather – Béchar, Algeria. Available online at: https://www.weather-atlas.com/en/algeria/bechar-climate. Accessed July 20, 2025.
Wilcher, D., (2025). What Is a Low Pass Filter? Understanding an Electronic Filter Circuit. DigiKey Maker.io. Available online at: https://www.digikey.com/en/maker/tutorials/2025/what-is-a-low-pass-filter-understanding-an-electronic-filter-circuit. Accessed September 1, 2025.
Zafeiriou, S., (2025). Arduino map() Function. Steve Zafeiriou. Available online at: https://stevezafeiriou.com/arduino-map-function/. Accessed September 1, 2025.
Downloads
Published
Issue
Section
License
Copyright (c) 2025 Nigerian Journal of Technological Development

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
In accordance with the Copyright Act of 1976, which became effective January 1, 1978, the following statement signed by each author must accompany the manuscript submitted: "I, the undersigned author, transfer all copyright ownership of the manuscript referenced above to the Nigerian Journal of Technological Development, in the event the work is published. I warrant that the article is original, does not infringe upon any copyright or other proprietary right of any third party, is not under consideration by another journal, and has not been published previously. I have reviewed and approved the submitted version of the manuscript and agree to its publication in the Nigerian Journal of Technological Development." A copyright transfer form can be downloaded from the NJTD Website (http://njtd.com.ng/index.php/njtd). Author(s) will be consulted, whenever possible, regarding republication of material. All authors must have access to the data presented, and the authors and sponsor (if applicable) must agree to share original data with the editor if requested.
