MEMS Gas Sensor Drift Correction for Indoor Air
ISEF Category: Embedded Systems
Ready to Turn This Idea Into a Real Project?
This guide was put together with the help of AI research tools to give you a solid starting point. But a competitive science fair project lives in the details: refining your research question, fine-tuning your variables, analyzing your data, and presenting your findings like a seasoned scientist.
For next steps tailored to your interests, skill level, and timeline, work one-on-one with a MehtA+ mentor. Learn more about MehtA+ Science & Engineering Research Mentorship →
Subcategory: Sensors · Difficulty: Advanced · Setup: School Lab · Time: Full Year
The Hook
Low-cost gas sensors can look smart on day one, then quietly get worse over time. That matters if you want to track indoor air quality in a bedroom, classroom, or lab. Your job is to teach the sensor to stay honest when temperature, humidity, and age all push its readings around.
What Is It?
MEMS gas sensors are tiny electronic noses. They do not identify gases with perfect precision, but they do respond to changes in the air around them. Many low-cost parts, like MQ-series sensors and the SGP30, drift over time, which means the same air can produce different readings on different days.
Think of the sensor like a student taking a test in a noisy room. Temperature and humidity are the noise. Drift is the student getting tired or distracted over time. A drift-correction algorithm tries to separate the real air-quality signal from those extra effects, so the readings become more stable and useful.
Transfer learning helps when you have more than one sensor unit. You can train a model on one unit or one environment, then adapt it to a new unit with less data. That matters because cheap sensors vary a lot from one device to the next.
Why This Is a Good Topic
This is a strong science fair topic because you can measure a real problem, sensor drift, and test a clear fix. You can compare raw readings against corrected readings and ask whether the model works better across days, rooms, or sensor units. The topic connects to indoor air quality, smart homes, and low-cost environmental monitoring. You can learn data cleaning, calibration, feature selection, and model evaluation without needing a university lab.
Research Questions
- How does adding temperature and humidity as covariates change the accuracy of a low-cost gas sensor model?
- What is the effect of transfer learning across sensor units on prediction error?
- Does a drift-correction model stay more stable than a raw sensor baseline over multiple days?
- To what extent does sensor warm-up time affect drift correction performance?
- Which model, linear regression, random forest, or neural network, best corrects drift for a low-cost gas sensor?
- How does training on one room and testing in another change corrected sensor accuracy?
Basic Materials
- MQ-series gas sensor or SGP30 sensor module
- Microcontroller board such as Arduino Uno or ESP32
- USB cable and laptop
- Breadboard and jumper wires
- Temperature and humidity sensor such as DHT22 or SHT31
- Digital notebook or spreadsheet for logging data
- Fan, window, or safe household odor sources for controlled air changes
- Sealed container or small test chamber for repeatable measurements
Advanced Materials
- Multiple MQ-series or SGP30 sensor units for cross-device testing
- Calibrated reference air-quality instrument or data from a nearby reference monitor
- Environmental chamber or controlled test box
- Temperature and humidity logger
- Microcontroller board with time-stamped data logging
- Air sampling tubing and flow control hardware
- Lab notebook or electronic log for synchronization records
Software & Tools
- Python: Cleans sensor logs, builds features, and trains drift-correction models.
- Pandas: Organizes time-series data and aligns sensor, temperature, and humidity records.
- Matplotlib: Plots raw readings, corrected readings, and error over time.
- scikit-learn: Trains and compares regression models for calibration and transfer learning.
- Jupyter Notebook: Keeps code, plots, and notes in one place for analysis and reporting.
Experiment Steps
- Define the target gas signal, the sensor units, and the reference you will treat as ground truth.
- Choose one drift source to study first, such as time, temperature, humidity, or sensor-to-sensor variation.
- Plan a data collection schedule that captures both normal conditions and intentional changes in the environment.
- Build a baseline model, then design a corrected model that adds environmental covariates and transfer learning.
- Decide how you will score success with error metrics, cross-validation, and holdout tests across days or units.
- Compare raw and corrected outputs, then check whether the model still works in a room or on a sensor it has not seen before.
Common Pitfalls
- Trusting raw MQ readings without a reference, which makes you mistake drift for air-quality change.
- Changing temperature and humidity at the same time as gas exposure, which makes the model unable to tell causes apart.
- Training and testing on the same sensor day, which hides how badly the model fails across time.
- Mixing up sensor warm-up drift with true gas response, which corrupts the dataset from the start.
- Using one room or one sensor only, which leaves you with a model that looks good but does not generalize.
What Makes This Competitive
A competitive project would go beyond a simple before-and-after calibration. You would test whether the correction works across different sensor units, different rooms, and different days. Strong analysis would compare several model types, report error bars, and show when the model breaks. The best versions also explain why the model fails in certain conditions, not just when it succeeds.
Project Variations
- Test whether the same correction model works for VOC-rich indoor air versus cleaner classroom air.
- Compare transfer learning across different MQ-series sensor units instead of only one SGP30 device.
- Add feature engineering from humidity change rate and temperature trend, then see whether it improves drift correction.
Learn More
- NIH PubMed: Search for review articles on low-cost gas sensors, drift correction, and indoor air quality.
- NASA Earthdata: Explore sensor calibration ideas and time-series methods used in environmental monitoring.
- NOAA National Centers for Environmental Information: Find background on temperature, humidity, and environmental data handling.
- MIT OpenCourseWare: Use free courses in machine learning, signal processing, or embedded systems for model and data collection ideas.
- scikit-learn User Guide: Read the free documentation for regression, model selection, and cross-validation methods.
Embedded Systems Category Guide
How to Do Real Embedded Systems Research at Home: A High School Student’s Guide to Free Tools, Affordable Kits, and Public Datasets →For next steps tailored to your interests, skill level, and timeline, work one-on-one with a MehtA+ mentor. Learn more about MehtA+ Science & Engineering Research Mentorship →
To discover more projects, visit the MehtA+ Science Fair Project Discovery Hub →
