From 21c793a41e94ec8b3f3df9364eca107a06239be8 Mon Sep 17 00:00:00 2001 From: Simon Albinsson Date: Mon, 23 Apr 2018 18:31:36 +0000 Subject: [PATCH] README: Fixes to RST and example code --- README.rst | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.rst b/README.rst index cb5ca8f..d488b98 100644 --- a/README.rst +++ b/README.rst @@ -1,13 +1,14 @@ RPI_SGP30 ========= -Program to read eCO_2 and TVOC from the `SGP30 sensor `_. Based on the smbus2 i2c library for ease of use. +Library to read |eCO_2| and TVOC from the `SGP30 sensor `_. Based on the smbus2 i2c library for ease of use. Quick usage-example: -------------------- :: + from smbus2 import SMBusWrapper from sgp30 import Sgp30 import time with SMBusWrapper(1) as bus: @@ -35,5 +36,6 @@ Features that are known to be missing (listing in rough order of importance): Hardware notices: ----------------- -If you have the AdaFruit board with built in level shifters and voltage regulator it is should work if you just plug in `SDA to pin 3, SCL to pin 5, VCC to pin 17 and GND to pin 20 `_. You should then be able to find the SGP30 an address 0x58 using `i2cdetect -y 1`. If you get an error message you probbably need to enable i2c in the kernel using `raspi-config and reboot `_ +If you have the Adafruit board with built in level shifters and voltage regulator it is should work if you just plug in `SDA to pin 3, SCL to pin 5, VCC to pin 17 and GND to pin 20 `_. You should then be able to find the SGP30 an address 0x58 using `i2cdetect -y 1`. If you get an error message you probably need to enable i2c in the kernel using `raspi-config and reboot `_ +.. |eCO_2| replace:: eCO\ :sub:`2`