Mercurial > code > home > repos > homeauto
comparison service/reasoning/actions.py @ 1052:2434e88d8bb0
add bed buttons
Ignore-this: 912a92f7a8e173fe64aa4c1df9ef7dba
darcs-hash:2e4031a9cacedb28f57c36708d69d6ec3610ef9d
author | drewp <drewp@bigasterisk.com> |
---|---|
date | Mon, 08 Feb 2016 23:48:29 -0800 |
parents | e3d77b7f16ca |
children | ba1149814877 |
comparison
equal
deleted
inserted
replaced
1051:cfc9c9f48824 | 1052:2434e88d8bb0 |
---|---|
27 :zeroValue ?val) for the value and PUT that. | 27 :zeroValue ?val) for the value and PUT that. |
28 """ | 28 """ |
29 | 29 |
30 self._oneShotPostActions(deviceGraph, inferred) | 30 self._oneShotPostActions(deviceGraph, inferred) |
31 for dev, pred in [ | 31 for dev, pred in [ |
32 # the config of each putUrl should actually be in the | 32 # the config of each putUrl should actually be in the |
33 # context of a dev and predicate pair, and then that would | 33 # context of a dev and predicate pair, and then that would |
34 # be the source of this list | 34 # be the source of this list |
35 #(DEV.theaterDoorLock, ROOM.state), | 35 #(DEV.theaterDoorLock, ROOM.state), |
36 #(URIRef('http://bigasterisk.com/host/bang/monitor'), ROOM.powerState), | 36 #(URIRef('http://bigasterisk.com/host/bang/monitor'), ROOM.powerState), |
37 (URIRef('http://bigasterisk.com/host/dash/monitor'), ROOM.powerState), | 37 (URIRef('http://bigasterisk.com/host/dash/monitor'), ROOM.powerState), |
38 (URIRef('http://projects.bigasterisk.com/room/storageCeilingLedLong'), ROOM.brightness), | 38 (URIRef('http://projects.bigasterisk.com/room/storageCeilingLedLong'), ROOM.brightness), |
39 (URIRef('http://projects.bigasterisk.com/room/storageCeilingLedCross'), ROOM.brightness), | 39 (URIRef('http://projects.bigasterisk.com/room/storageCeilingLedCross'), ROOM.brightness), |
40 (URIRef('http://projects.bigasterisk.com/room/headboardWhite'), ROOM.brightness), | |
41 (URIRef('http://projects.bigasterisk.com/room/bedLedStrip'), ROOM.color), | |
40 ]: | 42 ]: |
41 url = deviceGraph.value(dev, ROOM.putUrl) | 43 url = deviceGraph.value(dev, ROOM.putUrl) |
42 | 44 |
43 if url and dev == DEV.theaterDoorLock: # ew | 45 if url and dev == DEV.theaterDoorLock: # ew |
44 self._put(url+"/mode", payload="output") | 46 self._put(url+"/mode", payload="output") |