Skip to content

Instantly share code, notes, and snippets.

View amurfey's full-sized avatar
😎
learning new stuff

Alex Murfey amurfey

😎
learning new stuff
View GitHub Profile
@Jerry-Fix
Jerry-Fix / read dylospm2.5, pm10 data
Created May 2, 2015 06:11
read dylos pm2.5/pm10 data
import serial
import time
import sys
port = serial.Serial("/dev/ttyUSB0", 9600)
while True:
with open("data.txt", "a") as f:
data = time.ctime() + "," + port.readline()
print data