{"id":20594969,"url":"https://github.com/hackuarium/gas-sensor","last_synced_at":"2026-04-21T01:02:56.893Z","repository":{"id":84232740,"uuid":"160395789","full_name":"Hackuarium/gas-sensor","owner":"Hackuarium","description":"Arduino compatible gas sensor","archived":false,"fork":false,"pushed_at":"2019-05-31T21:16:18.000Z","size":53205,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-06T14:53:26.282Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Hackuarium.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-12-04T17:39:17.000Z","updated_at":"2019-05-31T21:16:20.000Z","dependencies_parsed_at":"2023-06-17T21:30:58.574Z","dependency_job_id":null,"html_url":"https://github.com/Hackuarium/gas-sensor","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Hackuarium/gas-sensor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hackuarium%2Fgas-sensor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hackuarium%2Fgas-sensor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hackuarium%2Fgas-sensor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hackuarium%2Fgas-sensor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hackuarium","download_url":"https://codeload.github.com/Hackuarium/gas-sensor/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hackuarium%2Fgas-sensor/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32072323,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T21:26:33.338Z","status":"ssl_error","status_checked_at":"2026-04-20T21:26:22.081Z","response_time":94,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T08:11:07.446Z","updated_at":"2026-04-21T01:02:56.864Z","avatar_url":"https://github.com/Hackuarium.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gas-sensor\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/images/PCB3D.png\" width=\"480\" /\u003e\n\u003c/p\u003e\n\nThe goal is to create a box allowing the determination of the gas composition of a bioreactor. The sensor that will be available are: CO2 (MH-Z19), H2 (MQ-8) and methane (MQ-4) as well as temperature (DS18B20) and humidity (DHT-22).\n\nThe board will be compatible with arduino Lilapad Pro using a dedicated PCB.\n\nNeed to compensate for humidity and temperature ???\n\n- https://forum.arduino.cc/index.php?topic=433045.0\n\n## Cloning the project\n\nThis project uses SUBMODULES\n\nIn order to clone use:\n\n`git clone --recurse-submodules https://github.com/hackuarium/gas-sensor`\n\nTo update the submodules\n\n`git submodule update --recursive --remote`\n\n## Sensors\n\n| name_pin | function    | model   |                             | Arduino library                                |\n| -------- | ----------- | ------- | --------------------------- | ---------------------------------------------- |\n| CH4      | CH4         | MQ-4    |                             |                                                |\n| H2       | H2          | MQ-8    |                             |                                                |\n| CO2      | CO2         | MH-Z19  | 3.3v (for RX / TX) + 5v!!!! | https://github.com/crisap94/MHZ19              |\n| TEMP     | temperature | DS18B20 |                             |                                                |\n| HUM      | humidity    | DHT-22  |                             | https://github.com/adafruit/DHT-sensor-library |\n\nGaz sensor: http://www.china-total.com/Product/meter/gas-sensor/Gas-sensor.htm\n\nGaz sensor on sparkfun:\nhttps://www.sparkfun.com/products/8891\nhttps://www.sparkfun.com/products/9404\n\nGaz sensor on mysensors: https://www.mysensors.org/build/gas\n\nDrying the air / pumping\nParticulate or Coalescing Filters\nhttp://www.pneumaticplus.com/pneumaticplus-saf4000-series-particulate-air-filter-1-2-npt-with-bracket/\nhttps://www.aliexpress.com/item/15L-M-12V-dc-electric-diaphragm-brush-small-air-compressor-pump/1790013118.html\n\nFans\n\nhttps://www.pelonistechnologies.com/micro-fans\n\nPneumatic\nhttps://www.alibaba.com/product-detail/A102-China-sup\n\n## Pinout\n\n| n° Arduino | port | pin      |                  |     |\n| ---------- | ---- | -------- | ---------------- | --- |\n| A0         | PC0  | A0       | H2               |     |\n| A1         | PC1  | A1       | H2_ON            |     |\n| A2         | PC2  | A2       | CO2_RX           |     |\n| A3         | PC3  | A3       | CO2_TX           |     |\n| A4         | PC4  | SDA      | Slave I2C        |     |\n| A5         | PC5  | SCL      | Slave I2C        |     |\n| A6         | ADC6 | A6       | CH4              |     |\n| A7         | ADC7 | A7       | CH4_ON           |     |\n| 0          | PD0  | RX       | FTDI             |     |\n| 1          | PD1  | TX       | FTDI             |     |\n| 2          | PD2  | D2       | /                |     |\n| 3          | PD3  | D3       | PWM_MH-Z19       | PWM |\n| 4          | PD4  | D4       | TEMPERATURE      |     |\n| 5          | PD5  | D5       | HUMIDITY         | PWM |\n| 6          | PD6  | D6       | LCD RS           | PWM |\n| 7          | PD7  | D7       | /                |     |\n| 8          | PB0  | D8       | LCD E            |     |\n| 9          | PB1  | D9       | LCD LED          | PWM |\n| 10         | PB2  | D10      | LCD1             | PWM |\n| 11         | PB3  | MOSI D11 | LCD2             | PWM | mh |\n| 12         | PB4  | MISO D12 | LCD3             |     |\n| 13         | PB5  | SCK D13  | LCD4             |     |\n\nn.b: Two pins (PD2 and PD7) are free and could be used to add a fourth sensor.\n\n## Power supply\n\n- plug for 5V\n- MCP1703-33 for µC power supply\n\n## Schematic\nHere is the schematic of the main components of the project:\n\nATMega328P:\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/images/schematic/ATMega328.png\" width=\"600\" /\u003e\n\u003c/p\u003e\nSensors:\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/images/schematic/MQ4.png\" width=\"220\" /\u003e\n  \u003cimg src=\"/images/schematic/MQ8.png\" width=\"220\" /\u003e\n  \u003cimg src=\"/images/schematic/MHZ19.png\" width=\"400\" /\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/images/schematic/Hum.png\" width=\"220\" /\u003e\n  \u003cimg src=\"/images/schematic/Temp.png\" width=\"220\" /\u003e\n\u003c/p\u003e\nOthers (LCD, crystal and voltage regulator):\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"/images/schematic/LCD.png\" width=\"300\" /\u003e\n  \u003cimg src=\"/images/schematic/Quartz.png\" width=\"200\" /\u003e\n  \u003cimg src=\"/images/schematic/VoltageRegul.png\" width=\"500\" /\u003e\n\u003c/p\u003e\n\n## List of components\n| Type           | Value | Quantity | Footprint                   |\n|----------------|-------|----------|-----------------------------|\n| Resistor       | 1M    | 1        | 0805 Handsolder             |\n| Resistor       | 10k   | 2        | 0805 Handsolder             |\n| Resistor       | 4.7k  | 2        | 0805 Handsolder             |\n| Resistor       | 4.7   | 1        | 0805 Handsolder             |\n| Potentiometer  |       | 1        | TRIM_3362R-1-222            |\n| Capacitor      | 10µF  | 2        | 0805 Handsolder             |\n| Capacitor      | 100nF | 3        | 0805 Handsolder             |\n| Capacitor      | 18pF  | 2        | 0805 Handsolder             |\n| Diode Shottky  |       | 3        | D_SOD-123                   |\n| BSP75          |       | 2        | SOT-223-3_TabPin3           |\n| Crystal        | 8Mhz  | 1        | Crystal_SMD_5032 Handsolder |\n| MCP-1703A      |       | 1        | SOT-23                      |\n| ATMega328P-AU  |       | 1        | TQFP-32_7x7mm_P0.8mm        |\n| 5V power source|       | 1        | BarrelJack_Horizontal       |\n| RJ12           |       | 1        | RJ12_Amphenol_54601         |\n| LCD Screen     |       | 1        | WC1602A                     |\n| MHZ-19 (CO2)   |       | 1        | footprints: MHZ-19          |\n| MQ-4 (CH4)     |       | 1        | footprints: MQ-4            |\n| MQ-8 (H2)      |       | 1        | footprints: MQ-8            |\n| DHT22 (Hum)    |       | 1        | footprints: DHT-22_HOR      |\n| DS18B20 (Temp) |       | 1        | TO-92_Inline                |\n\n\n\n## Inspiration for PCB\n\n* https://github.com/Hackuarium/esp-12e/tree/master/kicad\n\n  - ICSP - TAG connect - take care of pin mapping !\n  - RJ12 - 6P6C\n  - FTDI232\n  - LCD: WC1602A\n\n## Get inspired from scale board\n\n- https://github.com/Hackuarium/beemos/tree/master/scale-i2c/eagle\n- https://github.com/Hackuarium/esp-12e/tree/master/kicad/libs\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhackuarium%2Fgas-sensor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhackuarium%2Fgas-sensor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhackuarium%2Fgas-sensor/lists"}