Skip to content

Commit

Permalink
Rename 7201 to 7021 (typo)
Browse files Browse the repository at this point in the history
  • Loading branch information
seblucas committed Sep 4, 2018
1 parent 682779e commit 4e7ca81
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions i2c2mqtt.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

import bh1750
import bme280
import si7201
import si7021
import time, json, argparse
import paho.mqtt.publish as publish # pip install paho-mqtt

Expand All @@ -47,11 +47,11 @@ def getI2cSensors(devices):
newObject['lum'] = int (lux)
debug ("Light Level : " + str(newObject['lum']) + " lx")

if 'si7201' in devices:
###### Get temperature & humidity from si7201 ##
T = si7201.readTemperature()
if 'si7021' in devices:
###### Get temperature & humidity from si7021 ##
T = si7021.readTemperature()
newObject['temp'] = round (T, 1)
RH = si7201.readHumidity()
RH = si7021.readHumidity()
newObject['hum'] = int (RH)
debug ("Temperature : " + str(newObject['temp']) + " °C")
debug ("Humidity : " + str(newObject['hum']) + " %")
Expand Down
File renamed without changes.

0 comments on commit 4e7ca81

Please sign in to comment.