void loop() for (int i=0; i<3; i++) float val = analogRead(mqPins[i]); float ratio = val / baseline[i]; if (ratio > 1.15) // 15% rise Serial.print("Flying fish near sensor "); Serial.println(i); delay(500); // debounce
Date: April 14, 2026 Subject: Using MQ-2 / MQ-135 sensors to detect transient, moving gas plumes (“flying fish”) Prepared for: Hobbyists, environmental monitoring, and robotics developers 1. Objective To design a low‑cost, real‑time detection system that identifies and tracks a moving gas source (the “flying fish”) using one or more MQ sensors, with emphasis on sensitivity, response time, and false‑positive rejection. 2. Sensor Selection | Sensor | Target Gases | Best for “Flying Fish” | Response Time | Heating Current | |--------|--------------|------------------------|---------------|----------------| | MQ-2 | LPG, propane, smoke, methane | Yes – fast response to combustible gases | <10s | ~750 mA | | MQ-3 | Alcohol, ethanol vapor | Ideal for ethanol “flying fish” | <10s | ~750 mA | | MQ-135 | CO2, ammonia, benzene, smoke, alcohol | Wide range, good for indoor air plumes | <20s | ~800 mA | mh mq sensor flying fish
delay(100);
// Triangulation using peak times and amplitudes void loop() for (int i=0; i<3; i++) float
void loop() for (int i=0; i<numSensors; i++) current[i] = readSensor(i); delta[i] = (current[i] - baseline[i]) / baseline[i]; // relative change if (delta[i] > THRESHOLD && delta[i] < 0.8) // sharp rise // Flying fish detected near sensor i recordPeak(i, millis()); Sensor Selection | Sensor | Target Gases |
| Sensor | Distance from path | Peak voltage (V) | Peak time (ms) | |--------|-------------------|----------------|----------------| | S1 | 10 cm | 2.8 | 120 | | S2 | 30 cm | 1.9 | 320 | | S3 | 50 cm | 0.9 | 510 |