To prevent and mitigate the environmental impact of the transportation and extraction of oil and its derivatives, the conception, design, development, and implementation of an embedded system for wireless sensor networks (WSN) is presented is this paper. The proposed embedded system is a static sensor node that detects and classifies pollutants in aquatic environments using machine learning and IoT (Internet of Things) approaches. The article presents the development of the sensor node, which consists of three phases. In the first phase, the conception and modeling of the embedded system are presented, including mathematical modeling of the node, the node’s power supply system, WSN communication structure, pollutant detection, and classification via machine learning and IoT. The implementation of the static sensor node is presented in the second phase of the project, which includes functional modeling of the measurement, the architecture of the embedded system, and its physical structure. In the last phase, the detection and classification tests of the proposed sensor node are presented, including implementing five sensors. They are evaluated indoors by analyzing seawater samples with gasoline and diesel, pH and turbidity measurements of seawater and freshwater with gasoline, and experiments through direct and indirect measurements of seawater and diesel. Since the initial results of the indoor experiments are satisfactory, the proposed sensor node is regarding as a promising device for detecting and classifying pollutants in real-world aquatic environments.
This paper proposes a novel intelligent sensor node architecture that integrates embedded systems, machine learning, and Internet of Things (IoT) technologies. The proposed sensor node plays a crucial role in a Wireless Sensor Network (WSN) designed to detect and classify pollutants from petroleum derivatives in aquatic environments. The operational workflow consists of four fundamental stages: a) observing environmental variables (pH, conductivity, liquid temperature, and turbidity); b) signal processing; c) classification through an artificial neural network; and d) displaying outputs for decision-making. The signals serve as inputs to a Multilayer Perceptron (MLP) neural network embedded in an ESP32e microcontroller via TinyML and MicroPython. As a key contribution, this work performs a multicriteria trade-off analysis comparing MLP, RBF, SVM-RBF, and NLR models, evaluating predictive performance, computational cost, and memory footprint. The results demonstrate a classification F-score of 87.32% and an overall accuracy of 85% for diesel and gasoline detection in aquatic environments. Furthermore, the development of an online monitoring stage and energy optimization techniques is presented, where tests using the Deep Sleep mode showed a 44.7% reduction in power consumption, ensuring the node’s survival in hostile aquatic environments.