Skip to content

Instantly share code, notes, and snippets.

@KitWallace
Created August 30, 2012 07:51
Show Gist options
  • Save KitWallace/3523873 to your computer and use it in GitHub Desktop.
Save KitWallace/3523873 to your computer and use it in GitHub Desktop.
barometer reader
def baroReader(interval_secs) :
""" dummy reader until the chip is added to the RPi
generator
"""
station = Weather("horfield","http://www.martynhicks.co.uk/weather/clientraw.txt")
while True :
station.refresh()
if station.baro is None :
time.sleep(10)
else :
yield(station.baro)
time.sleep(interval_secs)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment