Next Article in Journal
Design and Experimental Validation of Stem-Clamping-and-Pull-Out-Type Pepper Plug Seedling-Picking Mechanism
Previous Article in Journal
Cloning and Functional Validation of the Candidate Gene LuWRKY39 Conferring Resistance to Septoria linicola (Speg.) Garassini from Flax
Previous Article in Special Issue
Development of EV Crawler-Type Weeding Robot for Organic Onion
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Neural Network-Guided Smart Trap for Selective Monitoring of Nocturnal Pest Insects in Agriculture

by
Joel Hinojosa-Dávalos
1,2,
Miguel Ángel Robles-García
1,
Melesio Gutiérrez-Lomelí
1,
Ariadna Berenice Flores Jiménez
1 and
Cuauhtémoc Acosta Lúa
1,3,*
1
Centro Universitario de la Ciénega, Universidad de Guadalajara, Ocotlán 47820, Jalisco, Mexico
2
Programa Cátedra CONAHCYT, Consejo Nacional de Humanidades, Ciencias y Tecnologías, Mexico City 03940, Mexico
3
Center of Excellence DEWS, University of L’Aquila, Coppito, 67100 L’Aquila, Italy
*
Author to whom correspondence should be addressed.
Agriculture 2025, 15(14), 1562; https://doi.org/10.3390/agriculture15141562
Submission received: 4 June 2025 / Revised: 26 June 2025 / Accepted: 12 July 2025 / Published: 21 July 2025
(This article belongs to the Special Issue Design and Development of Smart Crop Protection Equipment)

Abstract

Insect pests remain a major threat to agricultural productivity, particularly in open-field cropping systems where conventional monitoring methods are labor-intensive and lack scalability. This study presents the design, implementation, and field evaluation of a neural network-guided smart trap specifically developed to monitor and selectively capture nocturnal insect pests under real agricultural conditions. The proposed trap integrates light and rain sensors, servo-controlled mechanical gates, and a single-layer perceptron neural network deployed on an ATmega-2560 microcontroller by Microchip Technology Inc. (Chandler, AZ, USA). The perceptron processes normalized sensor inputs to autonomously decide, in real time, whether to open or close the gate, thereby enhancing the selectivity of insect capture. The system features a removable tray containing a food-based attractant and yellow and green LEDs designed to lure target species such as moths and flies from the orders Lepidoptera and Diptera. Field trials were conducted between June and August 2023 in La Barca, Jalisco, Mexico, under diverse environmental conditions. Captured insects were analyzed and classified using the iNaturalist platform, with the successful identification of key pest species including Tetanolita floridiana, Synchlora spp., Estigmene acrea, Sphingomorpha chlorea, Gymnoscelis rufifasciata, and Musca domestica, while minimizing the capture of non-target organisms such as Carpophilus spp., Hexagenia limbata, and Chrysoperla spp. Statistical analysis using the Kruskal–Wallis test confirmed significant differences in capture rates across environmental conditions. The results highlight the potential of this low-cost device to improve pest monitoring accuracy, and lay the groundwork for the future integration of more advanced AI-based classification and species recognition systems targeting nocturnal Lepidoptera and other pest insects.

1. Introduction

The Food and Agriculture Organization of the United Nations (FAO) defines a pest as “any species, strain, or biotype of plant, animal, or pathogenic agent that is harmful to plants or plant products” [1]. In the context of agriculture, insect pests are particularly problematic and have the most significant impact. Insect pests demonstrate a high degree of adaptability, allowing them to thrive in a wide range of ecological and climatic conditions in crop fields. Their reproduction rates vary, but they have the capacity to reproduce rapidly, causing significant damage to crops in a short period of time.
Lepidopteran pests pose a substantial threat to global agriculture, contributing to significant reductions in the yield of various crops. Lepidoptera, a taxonomic order that encompasses butterflies and moths, are particularly notorious for their destructive feeding behaviors, especially during the larval stage. México is estimated to harbor approximately 23,750 species of Lepidoptera, of which around 14,500 have been formally described and documented [2]. However, several of these species are responsible for considerable agricultural damage, affecting the key crops vital to the country’s food security and economy. Among the most problematic lepidopteran species in México are Spodoptera frugiperda, Spodoptera exigua, and Pectinophora gossypiella. Spodoptera frugiperda can reduce maize yields by as much as 60% in areas with severe infestations [3]. Similarly, Pectinophora gossypiella is associated with up to 40% losses in cotton production [4]. Spodoptera exigua has been recognized as a pest in México since 1992, due to its impact on multiple crops, including cotton, chili peppers, tomatoes, and onions [5]. Furthermore, Mythimna unipuncta is known to cause up to 80% of the damage in crops such as sugarcane and maize, as well as in other grasses [6]. Additionally, Gymnoscelis rufifaciata has been reported to damage crops such as alfalfa.
Insecticides are the preferred method for controlling and eradicating insect pests in agricultural crops. Insecticides are natural or synthetic compounds that, when applied in specific doses, prevent, control, repel, and/or eliminate insects. However, insecticides are among the most harmful products to the environment, and their use often carries significant negative consequences. Although they help control and eradicate pests, they can also be lethal to non-target populations such as soil nutrient recyclers, beneficial pollinators, and insects that act as natural enemies of pests. Besides their detrimental effect on the beneficial fauna of crops, the excessive use of insecticides can potentially contaminate both soil and water sources.
Therefore, for the rational use of insecticides, a series of measures aimed at increasing crop protection must be implemented before the use of these products. Integrated pest management (IPM) proposes the application of preventive cultural practices such as quarantining fields infested by pests and/or destroying diseased plants. Additionally, IPM advocates for continuous sampling and monitoring to determine the emergence of pest outbreaks and to apply mechanical methods when necessary [7,8]. One of these mechanical controls is the use of automatic traps, which are devices designed to attract and capture insects for elimination.
A wide variety of mechanical traps have been developed for pest control purposes [9], and as described by [10], these traps can be classified as follows: Time-sorting traps: these traps are designed to provide detailed information regarding the time and date of insect captures. Although their mechanisms are somewhat rudimentary compared to modern systems, they offer valuable temporal data on pest activity. Automated counting and identification traps: the primary function of these traps is to enable real-time data collection via a network of traps. The data are then disseminated to regional farmers through the Internet, facilitating immediate pest management responses. Automated visual identification traps: these traps utilize digital imaging to count and identify insect samples. This approach employs image analysis and machine learning algorithms to automatically identify and quantify insect catches based on the digital images of the trapped insects. Recent advancements in this area have been documented by various studies [11,12,13,14,15,16,17].
In [18], a methodology was proposed to estimate the density of Cryptolestes pusillus (Schonherr) adults trapped in electronic probe traps in paddy bulks using neural networks. Similarly, ref. [19] describes a smart trap system that employs computer vision and deep learning algorithms to identify mosquitoes in real time, with the goal of reducing vector populations and limiting the spread of mosquito-borne diseases. A modular, model-agnostic, deep learning-based counting pipeline for estimating insect populations from images is presented in [20], aiming to reduce manual inspection efforts and enhance operational efficiency. Finally, ref. [21] introduces an image-based insect trap that integrates imaging sensors and microcontroller units with embedded deep learning algorithms to count agricultural pests within pheromone-based funnel traps.
One promising approach for automated species identification involves analyzing wingbeat harmonic signals. These signals are influenced by wings and related morphological traits, such as size, shape, and number, which generate species-specific frequencies that can be used for taxonomic classification through phylo-genetic clustering [22,23].
However, many of the current automated traps that rely on such identification methods lack gate control mechanisms, leaving their inlets open throughout the sampling period [24,25]. This design flaw often results in the unintended capture of non-target insects, including beneficial pollinators and predators [26].
Despite these promising developments, current automated pest monitoring systems face critical technological challenges that limit their effectiveness and large-scale adoption. Key limitations include (1) inaccurate species identification due to the sensitivity of computer vision algorithms to morphological variability and adverse environmental conditions [27]; (2) high implementation costs linked to complex electronics and AI systems, which hinder scalability in smallholder farming contexts; and (3) elevated energy demands that complicate autonomous field operation [28].
Another method for attracting pest or beneficial insects for cultivation is the use of light, either in laboratories [29], or in the field [30,31,32]. However, studies by [33,34,35] have examined the effects of different wavelengths emitted by light sources on certain insects, including those in the Lepidoptera and Diptera orders.
Integrated pest management (IPM) strategies have increasingly incorporated the use of food-based and pheromonal attractants for the selective capture of pest insects, particularly those in the Lepidoptera order. Food attractants are typically composed of custom mixtures of organic compounds, which may originate from fermentation processes or floral sources. Studies such as [36,37] have shown that fermentation-based attractants are particularly effective for moth species. In contrast, certain species from the Hymenoptera order have been reported to respond positively to pheromone-based lures [38].
In parallel, several field studies have explored the use of low-cost, non-automated traps constructed from recycled materials and baited with food-based solutions. For instance, the approach proposed by [39] and applied in works such as [24,40] has demonstrated the successful capture of insects from the Diptera, Coleoptera, and Hymenoptera orders using fermented and non-fermented molasses as attractants.
Building upon these strategies, the present work proposes a novel automated platform that integrates food attractants with intelligent environmental control mechanisms to enhance species selectivity and enable real-time monitoring in agricultural settings.
The main contributions of this work are summarized below:
  • Integrated smart trap design and deployment: this study presents the complete design, construction, and field implementation of an automatic trap system for the attraction and capture of pest insects. It responds to the limitations found in traditional methods, such as low selectivity, high manual labor, and insufficient automation.
  • Stimuli-driven selectivity (visual and chemical): the trap attracts insects using a combination of a fermented food-based attractant and a light stimulus based on high-luminosity LEDs (green: 500–570 nm, yellow: 570–590 nm). These wavelengths were selected to exploit the visual sensitivity of nocturnal pests, particularly from the Lepidoptera and Diptera orders, as validated by literature and INIFAP field trials.
  • Autonomous mechanical control based on environmental conditions: the device includes servo-actuated gates that selectively allow insects entry during periods of darkness and dry conditions. This is achieved through an environmental control logic implemented as a perceptron neural network embedded in an ATMEGA-2560 microcontroller, using binary-mapped inputs from light and rain sensors.
  • Real-time environmental sensing and system monitoring: the trap continuously collects operational data such as gate state, LED activity, temperature, and humidity, which are stored on an SD card, displayed via LCD/I2C, and optionally transmitted using LoRa. This architecture enables remote status monitoring and supports the long-term, unattended deployment in agricultural environments.
  • Structural and electronic integration: a modular mechanical structure houses all components, including a transparent upper dome, removable tray, gate drive system, and sensor platform. The integration of sensing, actuation, and processing ensures a compact and robust solution fabricated using PLA via 3D printing.
  • Validation through experimental field trials: field experiments were conducted over 21 consecutive days at the experimental site of the University of Guadalajara in La Barca, Jalisco, Mexico (20°16’29.0″ N, 102°36’14.4″ W). Multiple treatments were tested to evaluate performance under real environmental conditions using a non-automated baseline for comparison.
  • Biological classification and species identification: Captured insects were analyzed offline through a two-step process: initial morphological assessment, followed by species identification using the Seek application from iNaturalist. Target pests such as Tetanolita floridiana, Synchlora spp., Estigmene acrea, Sphingomorpha chlorea, and Musca domestica were successfully identified, while beneficial and non-target species such as Chrysoperla spp. and Carpophilus spp. were largely excluded.
  • Experimental treatments and statistical validation: the methodology included a comparative analysis of four treatments, using different attractant combinations and automation levels. The Kruskal–-Wallis test confirmed significant differences in the effectiveness and selectivity of the smart trap compared to traditional setups.
  • Support for integrated pest management (IPM): by enabling selective, data-driven pest detection with minimal human intervention, the proposed trap provides a practical and scalable solution aligned with sustainable agriculture and modern IPM strategies.
This work represents a notable advancement in agricultural pest management by introducing an automated solution that reduces dependence on manual monitoring while improving the accuracy of real-time insect surveillance. By integrating advanced sensing and control technologies with biologically validated visual and food attractants, the system enhances both the efficiency of capture and the selectivity for target pest species. This allows for the more precise tracking of population dynamics and supports the adoption of data-driven strategies within integrated pest management (IPM) programs.
To aid in the identification of captured specimens, this study leverages iNaturalist, a global citizen science platform designed to document and classify biodiversity. The platform enables species identification in situ through artificial intelligence and a large, active user community. By combining encyclopedic biodiversity databases with interactive Web 2.0 tools, iNaturalist offers a robust and dynamic classification system. Although crowd-sourced, the platform maintains high standards of taxonomic accuracy thanks to the oversight of curators, researchers, and domain experts. Its continuously updated infrastructure ensures reliable access to current, validated species information relevant to ecological monitoring.
iNaturalist is a multi-taxon platform and a joint initiative of the California Academy of Sciences and the National Geographic Society. It collaborates closely with several trusted and authoritative institutions, such as the Global Biodiversity Information Facility (GBIF Occurrence Download. Available online: https://doi.org/10.15468/dl.smu5d3 (accessed on 26 June 2025)), the Encyclopedia of Life (RR 2014/021), the International Union for the Conservation of Nature (IUCN), Calflora, among others. iNaturalist has also been utilized for scientific research and data collection purposes, having been cited in academic literature [41,42,43,44,45,46].
This article is organized as follows: Section 2 outlines the mechanical design of the smart trap, while Section 3 focuses on the electronic design. Section 4 details the insect pest trapping method and the preparation of feeding attractant solutions used in real-time testing. Section 5 presents the results of the real-time testing, where data on insect pest trapping are collected and analyzed across various treatments. Some comments conclude the paper.

2. Mechanical Design of the Automated Device for the Capture of Adult Arthropod Pests

The smart trap for adult arthropod pests, as illustrated in Figure 1, was specifically developed to attract and selectively capture nocturnal flying insects in their adult stage, with particular emphasis on species belonging to the orders Lepidoptera and Diptera. Table 1 and Table 2 list various pest species that can be effectively captured using this device.
The mechanical architecture of the smart trap for adult arthropod pests was fully designed using SolidWorks software (version 2023 SP3.0), enabling a detailed evaluation of the functional arrangement, including gate operation dynamics and the optimal positioning of the internal attractant tray.
To translate the virtual design into a physical prototype, all components were fabricated via 3D printing using polylactic acid (PLA), a biodegradable thermoplastic derived from renewable sources. While PLA is favored for its printability and environmental compatibility, its mechanical properties impose certain constraints. Specifically, PLA begins to deform at temperatures above 60–65 °C (glass transition) and has a maximum service temperature of approximately 50–60 °C. It is sensitive to environmental humidity, which can cause long-term molecular degradation.
Considering the above-mentioned material properties, the mechanical components of the smart trap were designed as
1.
Frame of the trap: This structural unit houses the mechanical and electronic subsystems. It features side openings for pest entry, a top-mounted dome, and a base cavity for the removable tray. The frame dimensions are 0.24 m (length), 0.20 m (width), and 0.17 m (height). The front aperture provides a usable width of 0.156 m to facilitate tray insertion and retrieval.
2.
Removable attraction tray: Located at the bottom of the trap, this container holds a fermented food attractant and includes a light module with green and yellow LEDs (wavelengths 500–570 nm and 570–590 nm [48]). These visual cues enhance species-specific attraction. Tray dimensions are 0.187 m × 0.179 m × 0.058 m.
3.
Dome: The upper dome is a square-pyramidal shell made of transparent or translucent material. It allows light emitted by the internal LEDs to escape upward, maximizing visual stimulus for flying nocturnal insects while minimizing unwanted illumination of surrounding vegetation.
4.
Gates: Two side gates, each measuring 0.15 m (width) and 0.11 m (height), are mounted to regulate insect access. These gates, made of plastic with serrated edges, are actuated by a motorized transmission mechanism and can be removed for cleaning or replacement.
5.
Gate open/close mechanism: An electric motor is housed within the main frame and is mechanically coupled to a gear assembly. The motor drives a toothed shaft that rotates the first gate and, via a pulley-linked secondary shaft, actuates the second gate in synchronized motion. The vertical clearance for this subsystem is approximately 0.078 m. Under 5 V operation, the complete open-close cycle of the gates is executed in approximately 3.2 s, ensuring rapid adaptation to changing environmental conditions.
6.
External support platform: This lateral circular platform (diameter: 0.26 m) serves as the mount for environmental sensors (e.g., sunlight, rain, humidity) and power modules such as solar panels (not included in this version). A built-in drainage outlet prevents water accumulation and protects the electronics.
All parts are designed for modularity, facilitating rapid maintenance, field deployment, and component replacement. Although the trap is not fully weatherproofed by industrial standards, its dome geometry, component layout, and the integrated drainage system helps reduce exposure to rain and humidity. The mechanical design supports the overall functionality of the intelligent trap, ensuring reliable performance in diverse agricultural environments while aligning with the principles of Integrated Pest Management (IPM).

3. Electrical Design of the Automated Device for the Capture of Adult Arthropod Pests

The smart trap electrical system is organized into five core functional blocks: (1) actuators, (2) sensors, (3) control unit (microcontroller), (4) information management, and (5) power supply. Each of these blocks is responsible for enabling autonomous detection, activation, and data collection within the trap system, as illustrated in Figure 2.
  • Actuators: This block includes the high-brightness LEDs and the servo motor used to control the gate mechanisms. Specifically, the system employs two 5 mm LEDs (green and yellow) with wavelengths ranging from 500 to 590 nm [48] to attract nocturnal pests (see Table 3). These components are installed in the removable tray, ensuring visual stimulus from within the trap. The gate movement is achieved by a high-torque Tower Pro MG995 servomotor (see Table 4), selected for its mechanical strength and compact integration within the frame.
  • Sensors: The trap continuously acquires environmental data through three key sensor types installed on the external support platform. These include a photosensitive light detection module, a rain drop sensor (YL-83), and a DHT11 module for temperature and humidity measurement. Each sensor is connected to the microcontroller via analog or digital interfaces and is described in detail in Table 5.
  • Microcontroller: The central processing unit of the trap is the ATMEGA-2560 microcontroller. It handles sensor input processing, neural decision logic, actuator control, and data communication. Its technical specifications and connectivity options are provided in Table 6.
  • Information management: Data generated by the system is stored locally and optionally transmitted wirelessly. The human–machine interface consists of an LCD screen with I2C module for real-time display, a microSD card for local data logging, and a LoRa module for remote data transmission. Technical details are summarized in Table 7.
  • Power supply: The system is powered by a 2S (7.4 V) lithium polymer (LiPo) battery, offering sufficient current for uninterrupted nocturnal operation. The battery characteristics and configuration are presented in Table 8.
This architecture allows the trap to operate fully autonomously under real environmental conditions, ensuring energy-efficient activation and high selectivity in pest capture.
In Figure 3, the general diagram of the circuit of the smart trap for adult pest arthropods is illustrated. This circuit is designed to efficiently control and monitor the presence of pests without requiring constant intervention from the farmer. The purposes of these electronic circuits include aiding in the continuous surveillance of pest populations, such as the fall armyworm, by providing real-time data on the presence and activity of the arthropods. In addition, it facilitates the early detection of infestations by continuously measuring the abiotic conditions in which the target pests develop, enabling the farmer to take preventive measures before the pests cause significant damage.
Figure 3 shows the electronic components that conform the smart trap for adult pest arthropods, which were previously described in the block diagram in Figure 2, where the components used and their interconnections are outlined. The gates of the smart trap operate based on solar light parameters and weather conditions, such as rain, snow, or dew. Since the target insects are nocturnal, the gates open when the absence of sunlight is detected and close when light is present. Additionally, if rain is detected, the gates close to prevent the attractant solution from being diluted or washed away. This behavior of the smart trap gates drives the DC motors to open or close the gates, depending on the aforementioned conditions, to allow or block the entry of crop-damaging pest insects. Furthermore, as also explained in Section 2, the smart trap has a removable tray with two LED light sources of green and yellow colors with wavelengths of 500–570 nm and 570–590 nm, respectively, inside to attract pest insects. Both the LEDs and actuators are connected to the LiPo battery power source and are controlled by the ATMEGA-2560 microcontroller.
To detect the various conditions in which the smart trap operates, different sensors are used. Among them is the light detection sensor, which provides information to the microcontroller to determine the presence or absence of sunlight. Additionally, there is a rain sensor that detects whether there is water in the environment or not. This information is crucial for the smart trap because, like the light sensor, it allows the ATMEGA-2560 to send information to the actuators to open or close the trap gates. There is also a humidity and temperature sensor, which helps to assess the environmental conditions of the crop field. Knowing these conditions can help determine the likelihood of pest insects arriving at the crop.
All the information provided by the light, rain, humidity, and temperature sensors is collected through the ATMEGA-2560 microcontroller to make decisions about opening or closing the gates of the smart trap. However, this information is also used for further analysis. To this end, the smart trap is equipped with a data logger that collects information directly from the microcontroller via an I2C module and displays it in real-time on an LCD screen. Additionally, a LoRa communication system can transmit the collected data in real-time to other devices for statistical analysis, and the data is also stored on an SD memory card in a log file that can be accessed as a text document. Finally, all the electronic circuits used in the automated device for capturing adult pest arthropods (sensors, microcontroller, actuators, and information management) are powered by a LiPo 2S battery.
The operational flow of the automated arthropod trap is illustrated in Figure 4. The system is divided into two primary domains: (1) Data acquisition and transmission, and (2) neural decision making and actuator control. In the first domain, the system initializes by activating onboard sensors, including a photosensitive light sensor, a rain detection module, and a DHT11 temperature and humidity sensor. It then synchronizes timing, binds GPS coordinates, stores environmental data, and transmits the data via the LoRa protocol.
The second domain involves environmental signal interpretation and trap gate control. Analog readings from the light and rain sensors are first converted into binary values to enable discrete decision making. Specifically, light sensor readings above 650 are interpreted as nighttime ( l i g h t = 0 ), while the readings below or equal to 650 correspond to daylight ( l i g h t = 1 ). For the rain sensor, readings exceeding 900 indicate dry conditions ( r a i n = 0 ), while values at or below 900 suggest rainfall ( r a i n = 1 ).
These binary inputs are processed by a single-layer perceptron neural network implemented on the ATmega-2560 microcontroller. The use of this architecture single-layer perceptron with binary inputs derived from analog environmental sensors (light and rain) was intentionally selected for its simplicity and deployment efficiency on a low-power ATmega-2560 microcontroller.
The model was trained in MATLAB (version R2022a (Academic Use)) using all possible combinations of input states:
x l i g h t = [ 0 0 1 1 ] T , x r a i n = [ 0 1 0 1 ] T
with a desired output vector of
o u t r e f = [ 1 0 0 0 ]
which activates the gate ( o u t p u t = 1 ) only under optimal trapping conditions—specifically, when it is dark and not raining.
After training, considering the input vectors mentioned above ( x l i g h t and x r a i n ) and the output vector ( o u t r e f ), the perceptron successfully learned the logic required to activate the trap gate only under optimal conditions (dark and dry), producing the following parameters: w 1 = 1.0866 , w 2 = 0.3676 and b i a s = 0.0975 . In order to assess performance, these values were evaluated through standard binary classification metrics. The model achieved 100% accuracy, precision, recall, and F1-score on the input space. These metrics were calculated as follows:
A c c u r a c y = T P + T N T P + T N + F P + F N
P r e c i s i o n = T P T P + F P
R e c a l l = T P T P + F N
F 1 = 2 · P r e c i s i o n · R e c a l l P r e c i s i o n + R e c a l l
where true positive T P = 1 , true negative T N = 3 , false positive F P = 0 , and false negative F N = 0 .
After ensuring their good performance, the weights and bias were used by the microcontroller to compute the net input:
n e t i n p u t = ( l i g h t · w 1 ) + ( r a i n · w 2 ) + b i a s .
A step activation function then determines the output:
If o u t p u t = 1 , the servo motor is activated and the gate opens to allow pest insects to enter the attractant chamber. If o u t p u t = 0 , the gate remains closed, preventing ineffective or undesired captures during daylight or rainy periods. This decision process repeats cyclically, enabling fully autonomous and adaptive trap behavior under field conditions.
Given the simplicity of the problem, real-world validation was conducted by deploying the trained model on an ATmega-2560 microcontroller in field conditions, where the gate control logic was observed to function reliably.

4. Methodology for the Capture of the Adult Arthropod Pests

The study was conducted in the municipality of La Barca, Jalisco, México, at the experimental field of the University of Guadalajara, located at 20°16′29.0″ N 102°36′14.4″ W (see Figure 5). Observations and data collection were carried out from June to August 2023. The site is bordered by native vegetation, Azul Tequilana Weber agave crops, and diverse fruit trees.
The operation of the automatic trap includes the following main features:
  • Sensors to measure the abiotic conditions relevant to the target pest insects, such as temperature, environmental humidity, among others.
  • An automatic on/off system for green and yellow LED lights, with wavelengths of 500–570 nm and 570–590 nm, respectively, as well as the automatic opening and closing of the gates in the absence of sunlight, controlled by actuators.
  • A system for managing the information collected in the trap.
  • The use of a smart trap with the feeding attractant solution proposed in [49] to attract target pest insects.

Evaluation of the Performance of the Automatic Trap

To evaluate the performance of the automatic trap, the following treatments were implemented:
(A)
Automatic trap equipped with sensors and an automated system, utilizing the attractant solution described in [49] within its reservoir.
(B)
Automatic trap without sensors or automation, using the attractant solution described in [49] in its reservoir.
(C)
Non-automated container incorporating the feeding attractant solution described in [39].
(D)
Automatic trap without sensors or automation, using distilled water as the attractant solution in its reservoir.
The mixture described in reference [49], used in treatments (A) and (B), as well as the food attractant solution proposed by [39] and applied in treatment (C), are detailed in Appendix A. For treatment (D), distilled water was used as a control attractant solution.
In each experiment involving the feeding attractants described in [39,49], the solutions were independently placed in a reservoir tray, which was then inserted into the smart trap designed to attract target adult pest insects (moths). For the analysis of the results described in previous paragraphs, two types of data were collected:
  • Operational data from the automatic trap for capturing pest insects in real-time, which was stored on a microSD memory card to create a database.
  • Manual insect counts conducted over a 21-day period at the trap site, with the reservoir tray being inspected every three days. The insect carcasses, which had drowned in the attractant solution, were retrieved using a strainer or mesh filter. After filtration, the captured insects were classified into their respective orders through visual comparison, based on their morphological characteristics. The number of individuals from each order was then tallied. Qualitative identification of the insect carcasses was performed using the Seek mobile application from iNaturalist. To ensure result reliability, all treatments were conducted in triplicate, and the number of insects caught was used as the primary evaluation metric.
After the 21-day period, a statistical analysis was performed to determine the measures of central tendency and percentages of the captured insects. Additionally, a Kruskal–Wallis test was performed to determine significant differences between the traps, using SPSS V21 software. A p < 0.05 was considered statistically significant.

5. Results and Discussions

5.1. Results

The functional prototype of the automatic trap for capturing pest insects under real environmental conditions is illustrated in Figure 6.
Furthermore, Figure 7 presents an example of the operational parameters of the trap, including date and time of use of the smart trap, location based on global positioning, ambient temperature in °C, relative humidity as a percentage, presence/absence of light (1 if present, 0 if absent), presence/absence of rain (1 if raining, 0 if not), and the status of the trap’s gates (1 for open, 0 for closed).
Figure 8 presents the inert bodies of pest insects captured over the 21-day duration of the real-time testing of the smart trap, in accordance with the treatments outlined in this study. To classify the captured insects by their respective orders, a visual examination was performed based on their morphological characteristics.
Additionally, some of the captured insects were qualitatively identified using the mobile application Seek by iNaturalist. Among the target insects from the order Lepidoptera, species such as Tetanolita floridiana, emerald moth (Synchlora spp.), white-spotted soldier moth (Estigmene acrea), Sphingomorpha chlorea, and Gymnoscelis rufifasciata were observed, along with the housefly (Musca domestica). Non-target insects from the order Hymenoptera, including Hexagenia limbata and common green lacewings (Chrysoperla spp.), as well as Coleoptera such as sap beetles (Carpophilus spp.) and Mayate (Mexican June beetle), were also identified, as shown in Figure 9.
The different groups were then counted to determine the number of individuals from each order. A total of 1240 insects were captured, resulting in the following distribution: 779 insects (62.82%) H(3) = 9.60, p = 0.022 belonged to the order Diptera, 319 insects (25.72%) H(3) = 12.34, p = 0.006 to the order Lepidoptera, 38 insects (3.06%) H(3) = 8.76, p = 0.033 to the order Coleoptera, and 104 insects (8.39%) H(3) = 14.89, p = 0.002 to the order Hymenoptera. As shown in Figure 10, the insect order most attracted was Diptera, which includes families such as fruit flies and houseflies. All treatments attracted at least one specimen from each insect order corresponding to Lepidoptera, Coleoptera, Hymenoptera, and Diptera.
Following the analysis of the total number of insects captured during the 21-day period, Figure 11 shows the number of insects captured using each of the four treatments. Treatment (A) resulted in a capture percentage of 7.75% (96 insects), treatment (B) achieved 38.47% (477 insects), treatment (C) captured 51.45% (638 insects), and treatment (D) 2.34% (29 insects). A Kruskal–Wallis test revealed statistically significant differences among the four treatments H(3) = 158.23, p < 0.001.
From the treatments described above, the target insects of the order Lepidoptera were successfully attracted (see Figure 12), including species identified with the iNaturalist software (version 2023) as Tetanolita floridiana, emerald moth (Synchlora spp.), white-spotted soldier moth (Estigmene acrea), Sphingomorpha chlorea, and Gymnoscelis rufifasciata, as well as the housefly (Musca domestica). Additionally, these treatments effectively reduced the attraction of non-target insects, identified with iNaturalist software, such as sap beetles (Carpophilus spp.), Mexican June beetles (Mayate), Hexagenia limbata, and common green lacewings (Chrysoperla spp.) The smart trap in treatment (A) attracted 96 insects (7.74%) of target insects with no non-target insect captures. In contrast, the non-automated trap, in treatment B) (non-automated trap treatment), captured 447 insects (36.05%) of target species and 30 insects (1.77%) of non-target species. In comparison, the INIFAP proposal captured 531 target insects (42.82%) and 77 non-target insects (6.21%).
According to Figure 11 and Figure 8A, treatment (A), which used the smart trap with the attractant solution proposed in [49], was the most selective in capturing pest insects. Additionally, it is observed in Figure 8B that treatment (B), which used the trap without automation but still employed the attractant solution from [49], captured the highest number of insects but lacked selectivity in its capture. On the other hand, treatment (C), the container with the attractant solution described in [39], captured the highest number of non-target insects in the environment, due to the absence of an insect control mechanism that selectively captures pest insects (Figure 8C).
Figure 13 illustrates the insect capture dynamics during the sampling period. Treatment (A) consistently captured fewer insects than treatment (C). However, treatment (A) is specifically designed to target insects from the order Lepidoptera, as it is optimized for the selective capture of nocturnal species within this order. This selectivity arises from the specificity of the pest, as well as the sensors and actuators integrated into the smart trap. In contrast, treatment (C) record the behavior of all captured insects, including both nocturnal and diurnal, target, and non-target species.
To evaluate the efficiency of the functional prototype under real environmental conditions, Figure 14 presents the number of non-target insects captured over the 21-day sampling period across the treatments described above. When comparing treatment (A) to treatment (C), the former captured 30 times fewer Coleoptera (beetles) and 77 times fewer Hymenoptera (lacewings). Similarly, in comparison to treatment (B), treatment (A) resulted in 8 times fewer Coleoptera captures and 22 times fewer Hymenoptera. Moreover, the capture of Lepidoptera with treatment (A) was 42 times lower compared to treatment (C) and 62 times lower compared to treatment B). Regarding Diptera, treatment (B) captured 22 times fewer insects than the solution used in [39].

5.2. Discussions

The results obtained in this study demonstrate that the smart trap achieves high selectivity in capturing nocturnal pest insects by combining environmental sensing, mechanical design, and behaviorally targeted stimuli. Figure 11 and Figure 12 clearly illustrate the comparative performance of the four treatments, showing that Treatment (A)—the fully smart trap—captured a significantly lower proportion of non-target insects than the other configurations, while still attracting pest species from the Lepidoptera and Diptera orders. These differences were not incidental; they are the outcome of the deliberate integration of biological, mechanical, and control principles.
Mechanically, the system leverages a servo-controlled gating mechanism driven by environmental conditions. The embedded control logic, implemented through a single-layer perceptron on the ATMEGA-2560 microcontroller, processes binary input from light and rain sensors to determine whether gates should open or remain closed. This means that insect access is constrained in real time to moments that match the circadian rhythms of nocturnal pests—specifically, during dark and dry periods. This temporally structured gating reduces the likelihood of capturing diurnal insects, such as beneficial Hymenoptera and Coleoptera, which were notably absent in the automated treatment (A) (Figure 12), but present in treatments (B) and (C), where the trap remained passively open.
The optical component also plays a crucial role in selectivity. The system integrates LEDs emitting in the green (500–570 nm) and yellow (570–590 nm) wavelengths ranges known to be attractive to Lepidoptera and Diptera, respectively. The literature confirms that many nocturnal moths are highly responsive to green light, while yellow light is particularly effective for attracting houseflies and related species. By combining both spectra, the trap maximizes its appeal to target pests while minimizing attraction to insects outside these visual sensitivity profiles. This is supported by the taxonomic breakdown shown in Figure 10, where the dominant groups captured by Treatment (A) correspond to species whose behavior aligns with the selected LED ranges.
Importantly, the trap’s mechanical architecture contributes to ecological filtering beyond electronic control. Its side entry configuration, serrated gate edges, and partially enclosed dome serve as physical constraints that direct insect movement through defined pathways, reducing the probability of random entry by large-bodied or erratic fliers. This spatial structure works in tandem with the attractant and lighting to guide only responsive insects into the trap, forming a behavioral-mechanical filter that is rarely addressed in conventional trap design.
The combination of these elements, optical tuning, environmental gating, and structural filtering, produces a selective interface that explains the performance differentials seen in Figure 11 and Figure 12. The Kruskal–Wallis test confirmed statistically significant differences in capture rates across treatments (e.g., H ( 3 ) = 158.23 , p < 0.001 ), underscoring the functional contribution of the automation logic and not just the attractant formulation. Treatment (A) also recorded zero non-target species from the Hymenoptera and Coleoptera orders, reinforcing that the mechanical and temporal controls are not merely passive but serve as real-time exclusion mechanisms.
From an engineering systems perspective, the trap functions as a low-cost, autonomous cyber-physical system, capable of operating without internet connectivity or human supervision. Its power-efficient logic, use of open source electronics, and modular 3D-printed structure make it a strong candidate for rural deployment in low-infrastructure agricultural settings. The integration of real-time environmental sensing and actuator control into a biologically informed decision-making framework positions this device as a next-generation monitoring tool within integrated pest management (IPM) strategies.
While many smart traps in the literature focus on image-based insect recognition or cloud-based analytics [18,19], they often require high power, stable connectivity, or complex image processing pipelines. In contrast, our approach emphasizes local intelligence, mechanical selectivity, and cost-accessibility. This difference is crucial in resource-constrained contexts, where producers require scalable, easy-to-maintain tools with minimal dependency on digital infrastructure.
Despite its advantages, the current system has limitations. It lacks onboard imaging, and insect classification is dependent on post-capture identification via iNaturalist, which may introduce uncertainty. Moreover, attractants were not benchmarked against commercial pheromone standards. These constraints are addressed in the Future Work section, which outlines planned upgrades such as visual classification modules, mobile data interfaces, and validation through expert entomology.
Finally, the improved selectivity of the smart trap documented in Figure 11 and Figure 12 is not incidental but emerges from the mechanistic interplay between sensing, logic, structure, and behavior. The trap serves as a scalable platform for selective pest monitoring that bridges the gap between conventional passive devices and high-cost commercial smart systems. Its contribution lies not only in the number of insects captured, but in the precision with which it targets ecologically relevant species, and in its engineering model for reproducible, autonomous deployment in sustainable agriculture.

6. Conclusions

The design and functionality of the smart trap for capturing pest insects, tested under real-world conditions at the University of Guadalajara’s experimental unit, demonstrated its capacity for effective and selective pest monitoring. The system integrates a DHT11 humidity and temperature sensor, a photosensitive light sensor, and a rain sensor to monitor environmental variables relevant to pest activity. Based on these inputs, the trap autonomously activates gates and LED lights (green: 500–570 nm, yellow: 570–590 nm), optimizing attraction during nocturnal, dry conditions—especially for insects from the Lepidoptera and Diptera orders. Control logic is implemented using an ATMEGA-2560 microcontroller.
Field trials conducted from June to August 2023 in La Barca, Jalisco, México, confirmed the system’s ability to capture target species such as Tetanolita floridiana, Synchlora spp., Estigmene acrea, Sphingomorpha chlorea, Gymnoscelis rufifasciata, and Musca domestica, while substantially reducing the presence of non-target insects such as Carpophilus spp., Mayate (Mexican June beetle), Hexagenia limbata, and Chrysoperla spp.
Treatment (A) (fully automated) captured 7.74% (96 individuals) of target species with zero non-target captures. In contrast, Treatment (B) (non-automated, same attractant) recorded 36.05% (447 individuals) of target and 1.77% (30 individuals) of non-target insects. The INIFAP-based attractant (Treatment C) captured 42.82% of target and 6.21% of non-target species. These results confirm the system’s superior selectivity and operational effectiveness.
Beyond these technical outcomes, the proposed smart trap contributes meaningfully to integrated pest management (IPM) by enabling real-time, species-specific monitoring without reliance on chemical insecticides. Its low-cost, modular architecture is particularly suitable for smallholder and rural agricultural settings where commercial solutions are economically inaccessible. In this context, the system supports sustainable agriculture practices and aligns with policy goals aimed at reducing pesticide dependency and promoting precision agriculture technologies.
As part of future work, we aim to enhance the efficiency of the smart trap and maximize its benefits for farmers by incorporating improvements in insect capture, identification, and counting through the use of artificial intelligence and neural networks. Additionally, we will develop a mobile application to enable farmers to access and monitor real-time data collected by the trap’s sensors. To further advance this area of research, a comprehensive database will be established to identify other insect species that may be attracted to the wavelengths utilized by the trap. A certified, quantitative identification of both target and non-target insect species captured by the system will also be conducted.
On the other hand, it is intended to commercialize the smart trap for the capture of insect pests. For this purpose, an exhaustive analysis of alternatives will be carried out to optimize the unit production costs per device. Among the options considered is the possibility of standardizing the necessary electronic components and establishing direct contact with the manufacturer, thus eliminating intermediaries such as external distributors or retailers. This strategy would reduce unit costs per component and, by buying in bulk, facilitate increased production, thereby reducing the cost of the final product. In addition, outsourcing the design and manufacture of the frame is proposed as a means of reducing the associated costs without the need to invest in specialized machinery for its production. This would allow the acquisition of molds in large volumes, thus achieving a reduction in the unit cost per injection. In addition, a market study will be carried out to evaluate the acceptance of the product in terms of its selling price and functionalities. This analysis will help determine the optimal demand and inform strategic decisions, such as increasing production capacity while maintaining the current price, preserving capacity and price, or reducing the price to expand production capacity. Finally, a competitive analysis of direct competitors and substitutes already available in the market will be performed in order to identify the product’s value proposition and define the most appropriate marketing strategies.

Author Contributions

J.H.-D.: Investigation, Formal analysis; M.Á.R.-G.: Methodology and Resources; M.G.-L.: Data curation and Resources; A.B.F.J.: Software and Hardware; C.A.L.: Writing—original draft, Writing—Review and editing and Resources. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Data Availability Statement

Data are contained within the article.

Conflicts of Interest

The authors declare no conflicts of interest.

Appendix A

The mixture described in [49], used in treatments (A) and (B), involved the separate germination of sorghum, alfalfa, and wheat seeds in the rotary germinator developed in [50]. The specific conditions for the rotary germinator were rotation speed of 2 RPM and a relative humidity of 99%, with a photoperiod of 16 h of white light (5.84 μmol m−2 s−2) and 8 h of darkness.
After six days, the sprouts were dried in a convection dryer at 45 °C for 10 h. The dried sprouts were stored in dark polystyrene bags to protect them from light and were then refrigerated until further use. A total of 250 g of each sprout were weighed and mixed with 250 g of conventional sugar, grinding the entire mixture to produce a flour. Subsequently, 100 g of this flour were placed in a 2 L Erlenmeyer flask, and distilled water was added to reach 1300 mL. The mixture was left to ferment for four days at 25 °C. After fermentation, the mixture was diluted to 90%, adding 9 L of water for every liter of the fermented mixture.
On the other hand, the feeding attractant solution proposed by [39] and mentioned in treatment (C) was prepared using 3 kg of molasses, 1 L of water, and half a ripe pineapple cut into small pieces, including the peel. The mixture was left to ferment for four days at 25 ºC. Once fermented, the attractant was diluted to 90% by mixing 9 L of water for each liter of the fermented mixture.
Furthermore, for treatment (D), distilled water was used as the control attractant solution.

References

  1. FAO. CABI: Community-Based Fall Armyworm (Spodoptera frugiperda) Monitoring, Early Warning and Management, Training of Trainers Manual, 1st ed.; Food and Agriculture Organization of the United Nations: Rome, Italy, 2019. [Google Scholar]
  2. Llorente-Bousquets, J.; Vargas-Fernández, I.; Luis-Martínez, A.; Trujano-Ortega, M.; Hernández-Mejía, B.C.; Warren, A.D. Biodiversity of lepidopterans in México. Rev. Mex. Biodivers. 2014, 85, 353–371. [Google Scholar] [CrossRef]
  3. Ávila-Martínez, D.; Cervantes-Ortiz, F.; Rodríguez-Pérez, G.; Gámez-Vázquez, A.J.; García-Rodríguez, J.G.; Mendoza-Elos, M. Damage and population dynamics of codling moth (Spodoptera frugiperda) in elite lines of maize. Agron. Mesoam. 2023, 34, 53809–53819. [Google Scholar]
  4. Ávila García, R.; Cano Ríos, P.; Orona Castillo, I.; Espinoza Arellano, J.J.; Ramírez Segoviano, R. Establishment of the baseline for the evaluation of the technical and socioeconomic impact of the campaign against regulated pests of the cotton crop (Gossypium Hirsutum) in the state of Coahuila, México. Mex. J. Agribus. 2017, 41, 720–731. [Google Scholar] [CrossRef]
  5. DGSV-CNRF: Gusano Soldado Spodoptera exigua (Hubner, 1808) (Lepidoptera: Noctuidae); SADER-SENASICA, Dirección General de Sanidad Vegetal-Centro Nacional de Referencia Fitosanitaria: Tecámac, Mexico, 2020; pp. 20–30.
  6. DGSV-DCNRF: Gusano Soldado Mythimna unipuncta; SADER-SENASICA, Dirección General de Sanidad Vegetal-Dirección del Centro Nacional de Referencia Fitosanitaria: Tecámac, Mexico, 2019; pp. 18–28.
  7. Angon, P.B.; Mondal, S.; Jahan, I.; Datto, M.; Antu, U.B.; Ayshi, F.J.; Islam, M.S. Integrated Pest Management (IPM) in agriculture and its role in maintaining ecological balance and biodiversity. Adv. Agric. 2023, 1, 5546373. [Google Scholar] [CrossRef]
  8. He, W.; Zhao, X.; Ge, S.; Wu, K. Food attractants for field population monitoring of Spodoptera exigua (Hübner). J. Crop Prot. 2021, 145, 105616. [Google Scholar] [CrossRef]
  9. Cardim Ferreira Lima, M.; Damascena de Almeida Leandro, M.E.; Valero, C.; Pereira Coronel, L.C.; Gonçalves Bazzo, C.O. Detección y monitoreo automático de plagas de insectos: Una revisión. Agricultura 2020, 10, 161. [Google Scholar]
  10. Murchie, K.A. Advances in techniques for trapping crop insect pests. In Burleigh Dodds Series in Agricultural Science; Fountain, M., Pope, T., Eds.; Burleigh Dodds Science Publishing: Cambridge, UK; NIAB-EMR: West Malling, UK, 2023; pp. 3–46. [Google Scholar]
  11. Preti, M.; Verheggen, F.; Angeli, S. Insect pest monitoring with camera equipped traps: Strengths and limitations. J. Pest Sci. 2021, 94, 203–217. [Google Scholar] [CrossRef]
  12. Sciarretta, A.; Calabrese, P. Development of automated devices for the monitoring of insect pests. Curr. Agric. Res. J. 2019, 7, 19–25. [Google Scholar] [CrossRef]
  13. Xie, C.; Zhang, J.; Li, R.; Li, J.; Hong, P.; Xia, J.; Chen, P. Automatic classification for field crop insects via multiple-task sparse representation and multiple-kernel learning. Comput. Electron. Agric. 2015, 119, 123–132. [Google Scholar] [CrossRef]
  14. Rigakis, I.I.; Varikou, K.N.; Nikolakakis, A.E.; Skarakis, Z.D.; Tatlas, N.A.; Potamitis, I.G. The E-Funnel trap: Automatic monitoring of Lepidoptera; a case study of tomato leaf miner. Comput. Electron. Agric. 2021, 185, 106154. [Google Scholar] [CrossRef]
  15. Tepa-Yotto, G.T.; Meagher, R.L.; Winsou, J.K.; Dahoueto, B.T.A.; Tamò, M.; Sæthre, M.G.; Nagoshi, R.N. Monitoring Spodoptera frugiperda in Benin: Assessing the influence of trap type, pheromone blends, and habitat on pheromone trapping. Fla. Entomol. 2022, 105, 71–78. [Google Scholar] [CrossRef]
  16. Chulu, F.; Nkunika, P.; Chiwamba, S. Developing an automatic identification and early warning and monitoring web-based system of fall army worm based on machine learning in developing countries. Zambia ICT J. 2019, 3, 13–20. [Google Scholar] [CrossRef]
  17. Jiménez, A.F.; Jiménez, F.R.; Garciía, D.Y.; Guevara, E.J.; Quiñones, A.J.P. Electronic IOT trap for monitoring Spodoptera frugiperda in corn crops. Pistas Educ. 2024, 147, 651–666. (In Spanish) [Google Scholar]
  18. Li, J.; Zhou, H.; Wang, Z.; Jian, F.; Jayas, D.S.; Cui, M. A method to estimate densities of Cryptolestes pusillus (Schonherr) adults captured in electronic probe traps in paddy based on deep neural networks. Comput. Electron. Agric. 2023, 209, 107819. [Google Scholar] [CrossRef]
  19. Liu, W.-L.; Wang, Y.; Chen, Y.-X.; Chen, B.-Y.; Lin, A.Y.-C.; Dai, S.-T.; Chen, C.-H.; Liao, L.-D. An IoT-based smart mosquito trap system embedded with real-time mosquito image processing by neural networks for mosquito surveillance. Front. Bioeng. Biotechnol. 2023, 11, 1100968. [Google Scholar] [CrossRef] [PubMed]
  20. Ciampi, L.; Zeni, V.; Incrocci, L.; Canale, A.; Benelli, G.; Falchi, F.; Amato, G.; Chessa, S. A deep learning-based pipeline for whitefly pest abundance estimation on chromotropic sticky traps. Ecol. Inform. 2023, 78, 102384. [Google Scholar] [CrossRef]
  21. Saradopoulos, I.; Potamitis, I.; Konstantaras, A.I.; Eliopoulos, P.; Ntalampiras, S.; Rigakis, I. Image-Based Insect Counting Embedded in E-Traps That Learn without Manual Image Annotation and Self-Dispose Captured Insects. Information 2023, 14, 267. [Google Scholar] [CrossRef]
  22. Tercel, M.P.T.G.; Veronesi, F.; Pope, T.W. Phylogenetic clustering of wingbeat frequency and flight-associated morphometrics across insect orders. Physiol. Entomol. 2018, 43, 149–157. [Google Scholar] [CrossRef]
  23. Santos, D.A.A.; Rodrigues, J.J.P.C.; Furtado, V.; Saleem, K.; Koroteav, V. Automated electronic approaches for detecting disease vectors mosquitoes through the wing-beat frequency. J. Clean. Prod. 2019, 217, 767–775. [Google Scholar] [CrossRef]
  24. Meagher, R.L., Jr.; Agboka, K.; Tounou, A.K.; Koffi, D.; Agbevohia, K.A.; Amouze, T.R.; Adjévi, K.M.; Nagoshi, R.N. Comparison of pheromone trap design and lures for Spodoptera frugiperda in Togo and genetic characterization of moths caught. Entomol. Exp. Appl. 2019, 167, 507–516. [Google Scholar] [CrossRef]
  25. Sun, G.; Liu, H.; Lou, H.; Feng, Z.; Yang, B.; Lou, J.; Tang, J.; Yao, Q.; Xu, J. Intelligent monitoring system of migratory pests based on searchlight trap and machine vision. Front. Plant Sci. 2022, 13, 897739. [Google Scholar] [CrossRef] [PubMed]
  26. He, W.; Wang, L.; Lv, C.; Ge, S.; Haowen, Z.; Jiang, S.; Chu, B.; Yang, X.; Wyckhuys, K.; Wu, K. Use of food attractants to monitor and forecast Spodoptera frugiperda (J. E. Smith) seasonal abundance in Southern China. J. Pest Sci. 2023, 96, 1509–1521. [Google Scholar] [CrossRef]
  27. Popescu, D.; Dinca, A.; Ichim, L.; Angelescu, N. New trends in detection of harmful insects and pests in modern agriculture using artificial neural networks. a review. Front. Plant Sci. 2023, 14, 1268167. [Google Scholar] [CrossRef] [PubMed]
  28. Jiang, L.; Xu, B.; Husnain, N.; Wang, Q. Overview of Agricultural Machinery Automation Technology for Sustainable Agriculture. Agronomy 2025, 15, 1471. [Google Scholar] [CrossRef]
  29. Yang, H.; Lu, J.; Zhu, P.; Sun, Y.; Hu, Z.; Li, D.; Huang, J. Blue light attracts more Spodoptera frugiperda moths and promotes their flight speed. J. Insects 2024, 15, 129. [Google Scholar] [CrossRef] [PubMed]
  30. Bates, A.J.; Sadler, J.P.; Everett, G.; Grundy, D.; Lowe, N.; Davis, G.; Baker, D.; Bridge, M.; Clifton, J.; Freestone, R.; et al. Assessing the value of the garden moth scheme citizen science dataset: How does light trap type affect catch? Entomol. Exp Appl. 2013, 146, 386–397. [Google Scholar] [CrossRef]
  31. Awuor Okello, E.; van Tol, R.W.H.M.; Watako, A.; Ariga, E.S. Evaluation of optimal light wavelength for the attraction of Spodoptera exigua, a model insect for mass trapping and control of Spodoptera frugiperda. Int. J. Entomol. Res. 2020, 5, 27–32. [Google Scholar]
  32. Nascimento, I.; Oliveira, G.; Souza, M.; Nunes, G.; Leite Alves, A.; Araújo, H.; Batista, J. Light-Emitting diodes (LED) as luminous lure for adult Spodoptera frugiperda (J.E. Smith, 1797) (Lepidoptera: Noctuidae). J. Expel. Agric. Int. 2018, 25, 1–8. [Google Scholar] [CrossRef]
  33. Belton, P.; Kempster, R. Some factors affecting the catches of Lepidoptera in light traps. Can. Entomol. 1963, 95, 832–837. [Google Scholar] [CrossRef]
  34. Singh, R.; Böttger, D.; Brehm, G. Moth light traps perform better with vanes: A comparison of different designs. J. Appl. Entomol. 2022, 146, 1343–1352. [Google Scholar] [CrossRef]
  35. Haftay, G.; Fissiha, G.G. Night-Time Light-Traps and Push-Pull integrated system enhanced the control of different life stages of fall armyworm, Spodoptera frugiperda, (Lepidoptera: Noctuidae). Cabi Agric. Biosci. 2024, 5, 104. [Google Scholar]
  36. Batallas, R.E.; Evenden, M.L. Fermented or floral? Developing a generalized food bait lure to monitor cutworm and armyworm moths (Lepidoptera: Noctuidae) in field crops. J. Insects 2023, 14, 106. [Google Scholar] [CrossRef] [PubMed]
  37. Landolt, P.J.; Pantoja, A.; Hagerty, A.; Crabo, L.; Green, D. Moths trapped in Alaska with feeding attractant lures and the seasonal flight patterns of potential agricultural pests. Can. Entomol. 2007, 139, 278–291. [Google Scholar] [CrossRef]
  38. Grocock, N.L.; Batallas, R.E.; McNamara, E.A.; Sturm, A.B.; Manson, J.S.; Evenden, M.L. Bumble bees (Hymenoptera: Apidae) respond to moth (Lepidoptera: Noctuidae) pheromone components, leading to Bee Bycatch in monitoring traps targeting moth Pests. Front. Ecol. Evol. 2020, 8, 576692. [Google Scholar] [CrossRef]
  39. Mena-Covarrubias, J.; Ramírez-Cabral, N.Y.Z.; Medina-García, G.; Sánchez-Gutiérrez, A. Food Trap for Agro-Ecological Management of Insect Pest in Staple Crops and Vegetables; National Institute for Forestry, Agriculture and Livestock Research (INIFAP): Mexico City, Mexico, 2021. [Google Scholar]
  40. Rojas, J.; Virgen, A.; Santiesteban-Hernández, A.; Cruz-Esteban, S. Los cebos azucarados no atraen a las hembras se Spodoptera frugiperda (J. E. Smith, 1797) (Lepidoptera: Noctuidae) pero si afectan la atracción de los machos a la feromona sexual. Ento. Agricola 2020, 145–151. Available online: https://www.researchgate.net/publication/344180071 (accessed on 25 June 2025).
  41. Pimm, S.L.; Jenkins, C.N.; Abell, R.; Brooks, T.M.; Gittleman, J.L.; Joppa, L.N.; Raven, P.H.; Roberts, C.M.; Sexton, J.O. The biodiversity of species and their rates of extinction, distribution, and protection. Science 2014, 344, 124675. [Google Scholar] [CrossRef] [PubMed]
  42. Callaghan, C.T.; Mesaglio, T.; Ascher, J.S.; Brooks, T.M.; Cabras, A.A.; Chandler, M.; Cornwell, W.K.; Cristóbal Ríos-Málaver, I.; Dankowicz, E.; Urfi Dhiya’ulhaq, N.; et al. The benefits of contributing to the citizen science platform iNaturalist as an identifier. PLoS Biol. 2022, 20, 1–6. [Google Scholar] [CrossRef] [PubMed]
  43. Michonneau, F.; Paulay, G. Using iNaturalist to learn more about Echinoderms. Figshare J. Contrib. 2015. [Google Scholar] [CrossRef]
  44. Thomas, R.L.; Fellowes, M.D.E. Effectiveness of mobile apps in teaching field-based identification skills. J. Biol. Educ. 2016, 51, 136–143. [Google Scholar] [CrossRef]
  45. Fraser, D.L.; Ironside, K.; Wayne, R.K. Connectivity of mule deer (Odocoileus hemionus) populations in a highly fragmented urban landscape. Landscape Ecol. 2019, 34, 1097–1115. [Google Scholar] [CrossRef]
  46. Nugent, J. Citizen Science: Summer Squash Citizen Science. Sci. Scope 2019, 42, 22–24. [Google Scholar] [CrossRef]
  47. Hinojosa–Dávalos, J.; Acosta Lúa, C. Automated Trap for Capturing Insect Pests. Patent NMX 5425 B, 6 December 2024. (In Spanish). [Google Scholar]
  48. Dutta Gupta, S.; Jatothu, B. Fundamentals and applications of light-emitting diodes (LEDs) in in vitro plant growth and morphogenesis. Plant Biotechnol. Rep. 2013, 7, 211–220. [Google Scholar] [CrossRef]
  49. Hinojosa–Dávalos, J.; Acosta Lúa, C. Food Composition Attractant of Pest Insects Affecting Agricultural Crops. Patent No.MX/a/2022/016260, 15 December 2023. (In Spanish). [Google Scholar]
  50. Hinojosa–Dávalos, J.; Mares Guzman, I.; Varela Hernandez, J.J.; Cardona López, M.A.; Sanchez Morales, M.E.; Acosta Lúa, C. Rotary germination device to produce safe sprouts. Patent No. 4551, 24 March 2021. (In Spanish). [Google Scholar]
Figure 1. The automated device for the capture of adult arthropod pests [47].
Figure 1. The automated device for the capture of adult arthropod pests [47].
Agriculture 15 01562 g001
Figure 2. Block diagram of the automated device for trapping arthropod pests.
Figure 2. Block diagram of the automated device for trapping arthropod pests.
Agriculture 15 01562 g002
Figure 3. General circuit diagram of the automated device for the capture of adult arthropod pests.
Figure 3. General circuit diagram of the automated device for the capture of adult arthropod pests.
Agriculture 15 01562 g003
Figure 4. Functional flow diagram of the automated arthropod trap-integrating sensor activation, data acquisition, signal processing, neural decision making, and actuator control.
Figure 4. Functional flow diagram of the automated arthropod trap-integrating sensor activation, data acquisition, signal processing, neural decision making, and actuator control.
Agriculture 15 01562 g004
Figure 5. University of Guadalajara in La Barca, Jalisco, México.
Figure 5. University of Guadalajara in La Barca, Jalisco, México.
Agriculture 15 01562 g005
Figure 6. Prototype of an automatic trap for capturing insects in crop fields.
Figure 6. Prototype of an automatic trap for capturing insects in crop fields.
Agriculture 15 01562 g006
Figure 7. Example of the operational parameters in the automatic trap for capturing insects in crop fields.
Figure 7. Example of the operational parameters in the automatic trap for capturing insects in crop fields.
Agriculture 15 01562 g007
Figure 8. Treatments implemented in the automatic trap: (A) Automatic trap using the attractant solution proposed in [49]; (B) Automatic trap without the use of sensors or an automatic system using the solution proposed in [49]; (C) Container incorporating the feeding attractant solution proposed in [39]; (D) Automatic trap without the use of the automatic system, adding distilled water.
Figure 8. Treatments implemented in the automatic trap: (A) Automatic trap using the attractant solution proposed in [49]; (B) Automatic trap without the use of sensors or an automatic system using the solution proposed in [49]; (C) Container incorporating the feeding attractant solution proposed in [39]; (D) Automatic trap without the use of the automatic system, adding distilled water.
Agriculture 15 01562 g008
Figure 9. Insects captured and identified as target and non-target.
Figure 9. Insects captured and identified as target and non-target.
Agriculture 15 01562 g009
Figure 10. Distribution of the orders of the total number of insects captured during a 21-day period.
Figure 10. Distribution of the orders of the total number of insects captured during a 21-day period.
Agriculture 15 01562 g010
Figure 11. Number of insects captured during the 21-day period using the different treatments.
Figure 11. Number of insects captured during the 21-day period using the different treatments.
Agriculture 15 01562 g011
Figure 12. Number of insects captured during the 21-day period using the different treatments, separated between target and non-target insects.
Figure 12. Number of insects captured during the 21-day period using the different treatments, separated between target and non-target insects.
Agriculture 15 01562 g012
Figure 13. Insect capture behavior over the sampling period.
Figure 13. Insect capture behavior over the sampling period.
Agriculture 15 01562 g013
Figure 14. Average number of insects captured by the treatments evaluated.
Figure 14. Average number of insects captured by the treatments evaluated.
Agriculture 15 01562 g014
Table 1. Examples of insect pests from the order Lepidoptera that could be attracted and caught by the smart trap.
Table 1. Examples of insect pests from the order Lepidoptera that could be attracted and caught by the smart trap.
OrderFamilyScientific NameCrop Affected
LepidopteraNoctuidaePeridroma sauciaFruit and vegetables
Spodoptera frugiperdaCorn, cotton, sorghum,
wheat
Spodoptera ornithogalliCorn, cotton, sorghum,
wheat
Spodoptera cosmioidesSoybean, corn, rice,
alfalfa
Spodoptera eridaniaSoybean
Dargida albilineaWheat
Estigmene acreaTomatoes, peppers,
eggplants, beans,
soybeans, corn, wheat
Sphingomorpha chloreaCorn, sorghum, wheat,
beans, soybeans, chickpeas
Tetanolita floridanaTomatoes, peppers,
eggplants
TortricidaeGrapholita molestaApple tree, plum tree,
pear, quince, peanut,
walnut, pine nuts
PhycitidaePlodia interpunctellaPeanuts, walnuts,
pine nuts
GeometridaeSynchlora spp.Lettuce, pepper,
eggplant, beans, soybeans
Gymnoscelis rufifasciataTomatoes, peppers,
pumpkins, apple trees,
pear trees, cherry trees
Table 2. Examples of insect pests from the order Diptera that could be attracted and caught by the smart trap.
Table 2. Examples of insect pests from the order Diptera that could be attracted and caught by the smart trap.
OrderFamilyScientific NameCrop Affected
DípteraTephritidaeBactrocera dorsalisApricot, peach, apple,
pear, tomato, aubergine,
loquat, and orange
Ceratitis capitataApricot, peach, apple,
pear, tomato, orange,
nectarine, and pitahaya
Bactrocera latrifonsTomato, potato, pepper,
and aubergine
DrosophilidaeDrosophila suzukiiCherry, strawberry,
raspberry, and grape
AnthomyiidaeDelia radicumCauliflower, broccoli,
cabbage, and strawberry
AgromyzidaeLiriomyza huidobrensisLettuce, tomato, pepper,
garlic, aubergine, courgette,
pea, kidney bean,
chrysanthemum, melon,
cucumber, watermelon,
beetroot, and spinach
MuscoideaMusca domesticaApples, pears, grapes, citrus,
banana, mango, papaya
Table 3. Electronic components for the attraction of adult arthropod pests.
Table 3. Electronic components for the attraction of adult arthropod pests.
NameDescriptionTechnical InformationFigure
LED 5 mm
High luminosity
(green)
by Epistar Corp.
(Hsinchu, Taiwan)
High luminosity
green LED.
Operating voltage: 1.8–3.4 V.
Operating current: 20 mA.
Luminous intensity: 12 cd.
Wavelengths: 500–570 nm.
Agriculture 15 01562 i001
LED 5 mm
High luminosity
(yellow)
by Epistar Corp.
(Hsinchu, Taiwan)
High luminosity
yellow LED.
Operating
Voltage: 1.8–3.4 V.
Operating current: 20 mA.
Luminous intensity: 12 cd.
Wavelengths: 570–590 nm.
Agriculture 15 01562 i002
Table 4. Direct current motor.
Table 4. Direct current motor.
NameDescriptionTechnical InformationFigure
Servomotor
Tower Pro
MG995
by JH Global Trading
(Shenzhen, China)
High torque
servo up to
11 kg cm.
Operating
voltage: 4.6–6.6 V.
Torque: 11 kgf.cm.
Weight: 55 g.
Operating current: 10 mA.
Maximum load current: 1200 mA.
Agriculture 15 01562 i003
Table 5. Sensor assembly on the support platform.
Table 5. Sensor assembly on the support platform.
NameDescriptionTechnical informationFigure
Photosensitive
light detection
sensor module
Sensor that, through
a photoresistor,
measures the amount
of incident light.
Operating voltage: 5 V.
Operating current: 15 mA.
Type of signal: digital or analog.
Sensitivity can be adjusted
using the onboard
potentiometer.
Agriculture 15 01562 i004
YL-83. Rain
drop sensor
A rain sensor
designed as a low-cost
electronic sensor
for detecting rainfall
or water drops.
Operating voltage: 5 V.
Operating current: 15 mA.
Type of signal: digital or analog
Sensitivity of rain
Detection: minimum
wet area: 0.05 cm2.
Agriculture 15 01562 i005
DHT11
humidity
and temperature
sensor
by ASAIR Co.
(Shenzhen, China)
Basic digital sensor for
temperature and
humidity measurement.
This sensor uses
a thermistor
to measure the
surrounding air
(temperature) and
implements an internal
capacitive sensor for
humidity measurement.
Operating voltage: 5 V.
Operating current: 2.5 mA.
Type of signal: digital.
Temperature measurement
range: 0–50 °C.
Temperature measurement
accuracy: ±2.0 °C.
Temperature
resolution: 0.1 °C.
Humidity measurement
range: 20–90% RH.
Humidity measurement
accuracy: 5%
Humidity resolution:
1% RH.
Agriculture 15 01562 i006
Table 6. Unit control.
Table 6. Unit control.
NameDescriptionTechnical InformationFigure
ATMEGA-2560
by Microchip
Technology Inc.
(Chandler, AZ, USA)Microcontroller
board based on
the ATMEGA-2560,
featuring 54 digital
input/output pins.
Operating voltage: 5 V.
Input voltage: 6–20 V.
Digital I/O pins: 54.
Flash memory: 256 KB.
SRAM: 8 KB.
EEPROM: 4 KB.
Clock speed: 16 Mhz.
Agriculture 15 01562 i007
Table 7. Electronic human/machine interface devices.
Table 7. Electronic human/machine interface devices.
NameDescriptionTechnical InformationFigure
Micro SD
TF card
storage
memory
module
The micro SD
Reader module
allows connection to
a microcontroller
or development board
via SPI communication.
It is ideal it works at a
voltage between 4.5 and 5 V.
Operating voltage: 4.5–5 V.
Operating current: 200 mA.
Memory: MicroSD.
Communication
protocol: SPI.
Agriculture 15 01562 i008
Display
LCD
16 × 2-character
alphanumeric
LCD display.
Resolution: 2 lines
of 16 characters
of 8 × 5 pixels each.
Operation voltage: 5 V.
Operation current: 1.1 mA.
Agriculture 15 01562 i009
LCD I2C
Module
Device that allows
control of a display
through the I2C bus,
using only two wires.
Operation voltage: 5 V.
Operation current: 50 mA.
Communication
protocol: I2C.
Agriculture 15 01562 i010
LoRa
Reyax
by REYAX Technology Co.
(Shenzhen, China.)
Features the Lora
long-range modem
provides long-range
spread spectrum
communication
and high interference
immunity while
minimizing power
consumption.
Operation voltage: 3.3 V.
Operation current: 25 mA.
Communication
protocol: RX-TX.
Frequency accuracy
±2 ppm.
Agriculture 15 01562 i011
Table 8. Components for the power supply of the automated device for the capture of adult arthropods pests.
Table 8. Components for the power supply of the automated device for the capture of adult arthropods pests.
NameDescriptionTechnical InformationFigure
2S LiPo Battery
7.4 Volts
The battery consists of two
cells connected in series
to provide a voltage of 7.4 V.
Voltage: 7.4 V.
Capacity: 2200 mAh.
Discharge: 50 C.
Agriculture 15 01562 i012
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Hinojosa-Dávalos, J.; Robles-García, M.Á.; Gutiérrez-Lomelí, M.; Flores Jiménez, A.B.; Acosta Lúa, C. Neural Network-Guided Smart Trap for Selective Monitoring of Nocturnal Pest Insects in Agriculture. Agriculture 2025, 15, 1562. https://doi.org/10.3390/agriculture15141562

AMA Style

Hinojosa-Dávalos J, Robles-García MÁ, Gutiérrez-Lomelí M, Flores Jiménez AB, Acosta Lúa C. Neural Network-Guided Smart Trap for Selective Monitoring of Nocturnal Pest Insects in Agriculture. Agriculture. 2025; 15(14):1562. https://doi.org/10.3390/agriculture15141562

Chicago/Turabian Style

Hinojosa-Dávalos, Joel, Miguel Ángel Robles-García, Melesio Gutiérrez-Lomelí, Ariadna Berenice Flores Jiménez, and Cuauhtémoc Acosta Lúa. 2025. "Neural Network-Guided Smart Trap for Selective Monitoring of Nocturnal Pest Insects in Agriculture" Agriculture 15, no. 14: 1562. https://doi.org/10.3390/agriculture15141562

APA Style

Hinojosa-Dávalos, J., Robles-García, M. Á., Gutiérrez-Lomelí, M., Flores Jiménez, A. B., & Acosta Lúa, C. (2025). Neural Network-Guided Smart Trap for Selective Monitoring of Nocturnal Pest Insects in Agriculture. Agriculture, 15(14), 1562. https://doi.org/10.3390/agriculture15141562

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop