simple python script to run on pi that polls state