summaryrefslogtreecommitdiff
path: root/examples/toggle_lights.py
blob: 191cf36de7947f5d7c1336c3a1e6af0595765b5f (plain)
1
2
3
4
5
6
import ShellyPy

device = ShellyPy.Shelly("192.168.0.5") # try connecting to the Shelly device under that ip

device.relay(0, turn=True) # turn the relay at index 0 on
device.relay(0, turn=False) # same as bove but turn it off