Mercurial > code > home > repos > homeauto
comparison service/reasoning/input/devices.n3 @ 1402:5373c5cc03c4
device configs
Ignore-this: 6e052d5533da601f72c6e7017b232e8c
darcs-hash:b179d80e8a1c78f71d851b78f2e54ab781d9d1e7
author | drewp <drewp@bigasterisk.com> |
---|---|
date | Tue, 23 Jul 2019 10:16:14 -0700 |
parents | |
children | 4bee03b708c7 |
comparison
equal
deleted
inserted
replaced
1401:2ec49c958f91 | 1402:5373c5cc03c4 |
---|---|
1 @prefix : <http://projects.bigasterisk.com/room/>. | |
2 @prefix lights: <http://projects.bigasterisk.com/room/lights/>. | |
3 @prefix device: <http://projects.bigasterisk.com/device/>. | |
4 @prefix control: <http://projects.bigasterisk.com/control/>. | |
5 @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . | |
6 @prefix slashport: <http://slash.bigasterisk.com/parport/3bc#> . | |
7 @prefix port: <http://bang.bigasterisk.com/parport/parport0#> . | |
8 @prefix onewire: <http://bigasterisk.com/onewire/> . | |
9 @prefix cmd: <http://bigasterisk.com/magma/cmd/> . | |
10 @prefix bang1: <http://bigasterisk.com/bang/arduino/pin/> . | |
11 @prefix cl: <http://bigasterisk.com/ns/command/v1#> . | |
12 @prefix bang: <http://bigasterisk.com/host/bang/> . | |
13 | |
14 :putUrl rdfs:comment "this pin can be set by calling PUT on the given url with a body of '0' or '1'" . | |
15 # no longer parport; needs upgrade to whatever the arduino pin is: | |
16 #device:frontLights a :ParportPin; :putUrl "http://slash:9014/otherBit?bit=1" . | |
17 | |
18 device:heater :putUrl "http://bang:9056/pin/d4" . | |
19 | |
20 # these are the bedroom red light, untested | |
21 bang1:d7 :putUrl "http://bang:9056/pin/d7" . | |
22 bang1:d8 :putUrl "http://bang:9056/pin/d8" . | |
23 | |
24 :pulse rdfs:comment "number of seconds this pin should stay high when it is set to 1. Then the pin automatically goes back to 0." . | |
25 | |
26 port:pin3 rdfs:label "heater power" . | |
27 | |
28 # .1 second pulse was too short for redlight, once | |
29 | |
30 device:deckLightOff :putUrl "http://bang:9056/pin/d5"; rdfs:label "outdoor off (x1)"; :pulse ".4" . | |
31 device:deckLightOn :putUrl "http://bang:9056/pin/d6"; rdfs:label "outdoor on (x2)"; :pulse ".4" . | |
32 | |
33 cmd:deckLightOff :oneShot device:deckLightOff . | |
34 cmd:deckLightOn :oneShot device:deckLightOn . | |
35 | |
36 #port:pin_d7 rdfs:label "bedroomred off? (y1)"; :pulse ".8" . | |
37 cmd:bedroomRedLightOff :oneShot device:bedroomRedLightOff . | |
38 #port:pin_d8 rdfs:label "bedroomred on? (y2)"; :pulse ".8" . | |
39 cmd:bedroomRedLightOn :oneShot device:bedroomRedLightOn . | |
40 | |
41 port:unfinished1 :putUrl "http://bang:9056/pin/d12"; rdfs:label "heater sense" . | |
42 | |
43 device:frontLights rdfs:label "front light" . | |
44 cmd:frontLightOff :clearPin device:frontLights . | |
45 cmd:frontLightOn :setPin device:frontLights . | |
46 | |
47 #drew's phone = friendly phone | |
48 #kelsi phone = friendly phone | |
49 #bluetooth senses friendly phone -> all doors are unlocked | |
50 #all locks = device:lock1 | |
51 :drewsPhone :bluetoothAddr "...." . | |
52 | |
53 # maybe each tool should have its own little graph, and it announces | |
54 # changes to that graph. the listener tools make a combined-graph of | |
55 # the sources, and draw their conclusions on that | |
56 | |
57 onewire:addr104F718D00080038 :graphiteName "sens1"; rdfs:label "downstairsCeiling" . | |
58 onewire:addr1014958D0008002B :graphiteName "sens2"; rdfs:label "downstairsFloor" . | |
59 onewire:addr10CB6CBE0008005E :graphiteName "sens3"; rdfs:label "bedroom" . | |
60 onewire:addr109AA2BE000800C7 :graphiteName "sens4"; rdfs:label "livingRoom" . | |
61 | |
62 device:theaterDoorOutsideMotion rdfs:label "theater door outside motion" . | |
63 device:theaterDoorOpen rdfs:label "theater door open" . | |
64 | |
65 device:theaterDoorLock rdfs:label "theater door lock"; | |
66 :putUrl "http://bang:9056/pin/d3"; :zeroValue "0". | |
67 | |
68 :unlocked :putValue "1" . | |
69 :on :putValue "on" . | |
70 :off :putValue "off" . | |
71 | |
72 | |
73 <http://bigasterisk.com/host/bang/monitor> :putUrl "http://bang:9095/monitor"; :zeroValue "off" . | |
74 <http://bigasterisk.com/host/dash/monitor> :putUrl "http://dash:9095/monitor" . | |
75 <http://bigasterisk.com/host/frontdoor/monitor> :putUrl "http://frontdoor:9095/monitor" . | |
76 | |
77 device:heater cl:valueMapping | |
78 [cl:value cl:on; cl:putUrl <http://bang:9056/pin/d4>; cl:putBody "1" ], | |
79 [cl:value cl:off; cl:putUrl <http://bang:9056/pin/d4>; cl:putBody "0" ] . | |
80 | |
81 device:frontLight cl:valueMapping | |
82 [cl:value cl:on; cl:putUrl <http://slash:9080/yardLight>; cl:putBody "true" ], | |
83 [cl:value cl:off; cl:putUrl <http://slash:9080/yardLight>; cl:putBody "false" ] . | |
84 | |
85 :storageCeilingLedCross | |
86 :putUrl <http://bang:9059/output?s=http://projects.bigasterisk.com/room/storageCeilingLedCross&p=http://projects.bigasterisk.com/room/brightness>; | |
87 :zeroValue 0.0 . | |
88 | |
89 :storageCeilingLedLong | |
90 :putUrl <http://bang:9059/output?s=http://projects.bigasterisk.com/room/storageCeilingLedLong&p=http://projects.bigasterisk.com/room/brightness>; | |
91 :zeroValue 0.0 . | |
92 | |
93 :garageOverhead | |
94 :putUrl <http://garage.vpn-home.bigasterisk.com:9059/output?s=http://projects.bigasterisk.com/room/garageOverhead&p=http://projects.bigasterisk.com/room/brightness> . | |
95 :headboardWhite | |
96 :putUrl <http://bed.vpn-home.bigasterisk.com:9059/output?s=http://projects.bigasterisk.com/room/headboardWhite&p=http://projects.bigasterisk.com/room/brightness> . | |
97 :bedLedStrip | |
98 :putUrl <http://bed.vpn-home.bigasterisk.com:9059/output?s=http://projects.bigasterisk.com/room/bedLedStrip&p=http://projects.bigasterisk.com/room/color> . | |
99 | |
100 :starTrekLight | |
101 :putUrl <http://frontbed:9059/output?s=http://projects.bigasterisk.com/room/starTrekLight&p=http://projects.bigasterisk.com/room/brightness> . | |
102 | |
103 :kitchenLight | |
104 :putUrl <http://bang:10008/output?s=http://projects.bigasterisk.com/room/kitchenLight&p=http://projects.bigasterisk.com/room/brightness> . | |
105 | |
106 :kitchenCounterLight | |
107 :putUrl <http://bang:10008/output?s=http://projects.bigasterisk.com/room/kitchenCounterLight&p=http://projects.bigasterisk.com/room/brightness> . | |
108 | |
109 :changingWhite | |
110 :putUrl <http://changing:9059/output?s=http://projects.bigasterisk.com/room/changingWhite&p=http://projects.bigasterisk.com/room/brightness> . | |
111 | |
112 :changingCamPost a :OneShotPost; :subject :changingCam; :predicate :grab . | |
113 bang: a :OneShotPost; :subject bang:; :predicate :postAction . | |
114 | |
115 :livingRoomLamp1 | |
116 :putUrl <http://living:9059/output?s=http://projects.bigasterisk.com/room/livingRoomLamp1&p=http://projects.bigasterisk.com/room/brightness> . | |
117 | |
118 :livingRoomLamp2 | |
119 :putUrl <http://living:9059/output?s=http://projects.bigasterisk.com/room/livingRoomLamp2&p=http://projects.bigasterisk.com/room/brightness> . | |
120 | |
121 :loftDeskStrip | |
122 :putUrl <http://frontbed:9059/output?s=http://projects.bigasterisk.com/room/loftDeskStrip&p=http://projects.bigasterisk.com/room/x> . | |
123 | |
124 | |
125 :frontDoorOled :putUrl <http://frontdoor:10013/output>; :putPredicate :state . | |
126 :frontWindow :putPredicate :line1; :putUrl <http://bang:10008/output> . | |
127 :frontWindow :putPredicate :line2; :putUrl <http://bang:10008/output> . | |
128 :frontWindow :putPredicate :line3; :putUrl <http://bang:10008/output> . | |
129 :frontWindow :putPredicate :line4; :putUrl <http://bang:10008/output> . | |
130 | |
131 # newer style, with distinct :putState. | |
132 :frontDoorLock | |
133 :matchPredicate :putState; | |
134 :putUrl <http://bang:10011/output>; | |
135 :putPredicate :state . |