{
  "id": "solderedelectronics/Soldered-MQSensors-MicroPython-Library",
  "name": "Soldered-MQSensors-MicroPython-Library",
  "prettyName": "Soldered-MQSensors-MicroPython-Library",
  "description": "MicroPython library for Soldered's MQ-series gas sensor breakouts.",
  "version": "",
  "author": "solderedelectronics",
  "license": "GPL-3.0",
  "tags": [
    "gas",
    "i2c",
    "mq",
    "qwiic",
    "sensor"
  ],
  "status": "VALID",
  "official": false,
  "source": "https://github.com/solderedelectronics/Soldered-MQSensors-MicroPython-Library",
  "updatedAt": "2026-08-18T12:45:58.388Z",
  "page": "https://checkmim.com/packages/solderedelectronics+Soldered-MQSensors-MicroPython-Library",
  "createdAt": "2026-08-18T12:45:52.299Z",
  "submittedBy": "SolderedElectronics",
  "install": {
    "mpremote": "mpremote mip install github:solderedelectronics/Soldered-MQSensors-MicroPython-Library",
    "mip": "import mip; mip.install(\"github:solderedelectronics/Soldered-MQSensors-MicroPython-Library\")"
  },
  "readme": "# Soldered MQSensors MicroPython Library\n\nThis library drives Soldered's currently-sold MQ-series gas sensor breakouts (each pairs an MQ sensor element with native analog/digital GPIO output; some also have a Qwiic/I2C variant with an onboard ATtiny404). One `MQSensor` base class handles the shared read/calibration/regression logic; per-gas behavior (Rs/R0 ratio, regression coefficients) is set via constructor args.\n\n| Gas | Breakout (Native) | Breakout with Qwiic |\n| --- | --- | --- |\n| MQ7 (CO) | ![CO Sensor MQ7 Breakout](https://cms.soldered.com/products/333107/media/333107_featured-photo_2266b2.jpg) [333107](https://solde.red/333107) | ![CO Sensor MQ7 Breakout with Qwiic](https://cms.soldered.com/products/333121/media/333121_featured-photo_fcee01.jpg) [333121](https://solde.red/333121) |\n| MQ8 (Hydrogen) | ![Hydrogen Sensor MQ8 Breakout](https://cms.soldered.com/products/333108/media/333108_featured-photo_7b29c0.jpg) [333108](https://solde.red/333108) | — |\n| MQ9 (CO, flammable gases) | ![CO, Flammable Gasses Sensor MQ9 Breakout](https://cms.soldered.com/products/333109/media/333109_featured-photo_63e464.jpg) [333109](https://solde.red/333109) | — |\n| MQ131 (Ozone) | ![Ozone Sensor MQ131 Breakout](https://cms.soldered.com/products/333110/media/333110_featured-photo_acbd11.jpg) [333110](https://solde.red/333110) | ![Ozone Sensor MQ131 Breakout with Qwiic](https://cms.soldered.com/products/333124/media/333124_featured-photo_473cf3.jpg) [333124](https://solde.red/333124) |\n| MQ137 (Ammonia) | ![Ammonia Sensor MQ137 Breakout](https://cms.soldered.com/products/333113/media/333113_featured-photo_bd885c.jpg) [333113](https://solde.red/333113) | ![Ammonia Sensor MQ137 Breakout with Qwiic](https://cms.soldered.com/products/333127/media/333127_featured-photo_aa9645.jpg) [333127](https://solde.red/333127) |\n| MQ138 (VOC) | ![VOC Sensor MQ138 Breakout](https://cms.soldered.com/products/333114/media/333114_featured-photo_748144.jpg) [333114](https://solde.red/333114) | ![Benzene, Toluene, Acetone, Formaldehyde Sensor MQ138 Breakout With Qwiic](https://cms.soldered.com/products/333128/media/333128_featured-photo_fff417.jpg) [333128](https://solde.red/333128) |\n\nMQ2, MQ3, MQ4, MQ5, MQ6, and MQ135 variants exist in this driver's `Examples/` for backward compatibility, but those boards are discontinued and no longer sold by Soldered. MQ8 and MQ9 don't have a dedicated Qwiic board, but I2C mode still works through a generic ATtiny404 I2C bridge board.\n\n## How to install\n\n---\n\nAfter [**installing the mpremote package**](https://docs.micropython.org/en/latest/reference/mpremote.html), install the library on your board using the following command:\n\n```sh\n  mpremote mip install github:SolderedElectronics/Soldered-MQSensors-MicroPython-Library\n```\nOr, if you're running a Windows OS:\n\n```sh\n  python -m mpremote mip install github:SolderedElectronics/Soldered-MQSensors-MicroPython-Library\n```\n\n### Repository Contents\n\n- **MQSensor.py** - MicroPython driver class (base class for all MQ variants, Native + Qwiic/I2C)\n- **Qwiic.py** - shared I2C base class this driver depends on\n- **package.json** - mip install manifest\n- **/Examples** - Native and I2C examples per MQ variant (MQ2/3/4/5/6/7/8/9/131/135/137/138), plus calibration and digital-input examples\n\n### Hardware design\n\nYou can find hardware design for these boards in each MQ variant's own hardware repository.\n\n### Documentation\n\nAccess library documentation [here](https://docs.soldered.com).\n\n### About Soldered\n\n![Soldered Logo](https://raw.githubusercontent.com/SolderedElectronics/Soldered-Generic-Arduino-Library/dev/extras/Soldered-logo-color.png)\n\nAt Soldered, we design and manufacture a wide selection of electronic products to help you turn your ideas into acts and bring you one step closer to your final project. Our products are intented for makers and crafted in-house by our experienced team in Osijek, Croatia. We believe that sharing is a crucial element for improvement and innovation, and we work hard to stay connected with all our makers regardless of their skill or experience level. Therefore, all our products are open-source. Finally, we always have your back. If you face any problem concerning either your shopping experience or your electronics project, our team will help you deal with it, offering efficient customer service and cost-free technical support anytime. Some of those might be useful for you:\n\n- [Web Store](https://www.soldered.com/shop)\n- [Tutorials & Projects](https://soldered.com/learn)\n- [Documentation](https://docs.soldered.com)\n\n### Open-source license\n\nSoldered invests vast amounts of time into hardware & software for these products, which are all open-source. Please support future development by buying one of our products.\n\nCheck license details in the LICENSE file. Long story short, use these open-source files for any purpose you want to, as long as you apply the same open-source licence to it and disclose the original source. No warranty - all designs in this repository are distributed in the hope that they will be useful, but without any warranty. They are provided \"AS IS\", therefore without warranty of any kind, either expressed or implied. The entire quality and performance of what you do with the contents of this repository are your responsibility. In no event, Soldered (TAVU) will be liable for your damages, losses, including any general, special, incidental or consequential damage arising out of the use or inability to use the contents of this repository.\n\n## Have fun!\n\nAnd thank you from your fellow makers at Soldered Electronics.\n"
}