{"id":19738552,"url":"https://github.com/sensirion/raspberry-pi-i2c-svm4x","last_synced_at":"2026-05-19T14:04:40.778Z","repository":{"id":149346066,"uuid":"429113173","full_name":"Sensirion/raspberry-pi-i2c-svm4x","owner":"Sensirion","description":"C driver to work with the Sensirion's SVM41 sensor modules via I2C on Raspberry-Pi","archived":false,"fork":false,"pushed_at":"2024-05-23T18:20:30.000Z","size":1081,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-10-08T19:58:18.537Z","etag":null,"topics":["driver","evaluation-kit","humidity","i2c","nox","raspberry-pi","sek","sensirion","svm41","svm4x","temperature","voc"],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Sensirion.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","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":"2021-11-17T16:06:57.000Z","updated_at":"2024-05-23T18:20:33.000Z","dependencies_parsed_at":null,"dependency_job_id":"e9c8707b-4bd8-4bbd-bb0b-c3d6b05eba0a","html_url":"https://github.com/Sensirion/raspberry-pi-i2c-svm4x","commit_stats":null,"previous_names":["sensirion/raspberry-pi-i2c-svm4x","sensirion/raspberry-pi-i2c-svm41"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/Sensirion/raspberry-pi-i2c-svm4x","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sensirion%2Fraspberry-pi-i2c-svm4x","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sensirion%2Fraspberry-pi-i2c-svm4x/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sensirion%2Fraspberry-pi-i2c-svm4x/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sensirion%2Fraspberry-pi-i2c-svm4x/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Sensirion","download_url":"https://codeload.github.com/Sensirion/raspberry-pi-i2c-svm4x/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sensirion%2Fraspberry-pi-i2c-svm4x/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000659,"owners_count":26082805,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["driver","evaluation-kit","humidity","i2c","nox","raspberry-pi","sek","sensirion","svm41","svm4x","temperature","voc"],"created_at":"2024-11-12T01:14:29.294Z","updated_at":"2025-10-08T19:58:19.753Z","avatar_url":"https://github.com/Sensirion.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sensirion Raspberry Pi I2C SVM4x Driver\n\nThis document explains how to set up the [SEK-SVM4x](https://www.sensirion.com/my-sgp-ek/) sensor module to run on a\nRaspberry Pi using the provided code.\n\nThe SVM4x evaluation kit covers evaluation of the SGP40 and SGP41 sensors.\n\n[\u003ccenter\u003e\u003cimg src=\"images/SVM4x.png\" width=\"500px\"\u003e\u003c/center\u003e](https://www.sensirion.com/my-sgp-ek/)\n\n## Setup Guide\n\n### Connecting the Sensor\n\nYour sensor has the five different connectors: VCC, GND, SDA, SCL, SEL (the sixth connector will not be used for now).\nUse the following pins to connect your SVM4x:\n\n*SVM4x*  |    *Raspberry Pi*            |   *Jumper Wire*   |\n :------: | :-------------------------: | :---------------: |\nVCC    |        Pin 1 or 2 (3.3V or 5V) |   Red             |\nGND    |        Pin 6                   |   Black           |\nSDA    |        Pin 3                   |   Green           |\nSCL    |        Pin 5                   |   Yellow          |\nSEL    |        Pin 9 (GND for I2C)     |   Blue            |\n\n\u003ccenter\u003e\u003cimg src=\"images/GPIO-Pinout-Diagram.png\" width=\"900px\"\u003e\u003c/center\u003e\n\nIf you don't have a suitable cable at hand, please find the SEK-SVM4x technical description [here](https://www.sensirion.com/my-sgp-ek):\n\n| *Pin* | *Cable Color* | *Name* | *Description* | *Comments* |\n|-------|---------------|--------|---------------|------------|\n| 1     | Red           | VDD    | Supply Voltage | 3.3 or 5.0 V\n| 2     | Black         | Ground |\n| 3     | Green         | RX     | UART: Receiving pin for communication |\n|       |               | SDA    | I2C: Serial data, bidirectional |\n| 4     | Yellow        | TX     | UART: Transmission pin for communication |\n|       |               | SCL    | I2C: Serial clock |\n| 5     | Blue          | SEL    | Interface select | Leave floating or pull to VDD to select UART\n|       |               |        |  | Pull to GND to select I2C\n| 6     | Purple        | NC     | Do not connect |\n\n### Raspberry Pi\n\n- [Install the Raspberry Pi OS on to your Raspberry Pi](https://projects.raspberrypi.org/en/projects/raspberry-pi-setting-up)\n- [Enable the I2C interface in the raspi-config](https://www.raspberrypi.org/documentation/configuration/raspi-config.md)\n- Download the driver for the [Sensirion Github Page](https://github.com/Sensirion/raspberry-pi-i2c-svm4x) and extract\n  the `.zip` on your Raspberry Pi\n- Compile the driver\n    1. Open a [terminal](https://www.raspberrypi.org/documentation/usage/terminal/?)\n    2. Navigate to the driver directory. E.g. `cd ~/raspberry-pi-i2c-svm4x`\n    3. Run the `make` command to compile the driver\n\n       Output:\n       ```\n       rm -f svm41_i2c_example_usage\n       cc -Os -Wall -fstrict-aliasing -Wstrict-aliasing=1 -Wsign-conversion -fPIC -I. -o svm41_i2c_example_usage  svm41_i2c.h svm41_i2c.c sensirion_i2c_hal.h sensirion_i2c.h sensirion_i2c.c \\\n         sensirion_i2c_hal.c sensirion_config.h sensirion_common.h sensirion_common.c svm41_i2c_example_usage.c\n       ```\n- Test your connected sensor\n    - Run `./svm41_i2c_example_usage` in the same directory you used to compile the driver.\n\n      Output:\n      ```\n      Serial number: 0FA3F1F7000003392A3D0240\n      Firmware: 3.0 Debug: 0\n      Hardware: 3.0\n      Protocol: 1.0\n      Temperature Offset: 0.00 °C\n      Humidity: 47.34 % RH\n      Temperature: 28.95 °C\n      VOC index: 101.0 VOC index\n      NOx index: 1.0 NOx index\n      Humidity: 47.35 % RH\n      Temperature: 28.98 °C\n      VOC index: 101.0 VOC index\n      NOx index: 1.0 NOx index\n      ...\n      ```\n\n## Troubleshooting\n\n### Initialization failed\n\n- Ensure that you connected the sensor correctly: All cables are fully plugged in and connected to the correct pin.\n- Ensure that I2C is enabled on the Raspberry Pi. For this redo the steps on\n  \"Enable the I2C interface in the raspi-config\" in the guide above.\n- Ensure that your user account has read and write access to the I2C device. If it only works with user\n  root (`sudo ./svm41_i2c_example_usage`), it's typically due to wrong permission settings.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsensirion%2Fraspberry-pi-i2c-svm4x","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsensirion%2Fraspberry-pi-i2c-svm4x","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsensirion%2Fraspberry-pi-i2c-svm4x/lists"}