annotate py/config.py @ 160:256505f98c4d

uploader works
author Matt Johnston <matt@ucc.asn.au>
date Thu, 03 Jan 2013 22:37:33 +0800
parents 0529f3527626
children d73077e8cd67
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
148
b32e5a11a4cb few updates, seems to run
Matt Johnston <matt@ucc.asn.au>
parents: 145
diff changeset
1
160
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
2 FRIDGE_SLEEP = 60
149
d686b111dab4 working better. logging works properly, cleanup fridge.off() happens.
Matt Johnston <matt@ucc.asn.au>
parents: 148
diff changeset
3 SENSOR_SLEEP = 15
160
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
4 UPLOAD_SLEEP = 80
148
b32e5a11a4cb few updates, seems to run
Matt Johnston <matt@ucc.asn.au>
parents: 145
diff changeset
5
160
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
6 FRIDGE_DELAY = 600 # 10 mins
149
d686b111dab4 working better. logging works properly, cleanup fridge.off() happens.
Matt Johnston <matt@ucc.asn.au>
parents: 148
diff changeset
7 FRIDGE_WORT_INVALID_TIME = 300 # 5 mins
145
6517ddee3187 few more bits
Matt Johnston <matt@ucc.asn.au>
parents: 144
diff changeset
8
160
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
9 # 12 hours
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
10 MAX_READINGS = 12*60*60 / SENSOR_SLEEP
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
11
148
b32e5a11a4cb few updates, seems to run
Matt Johnston <matt@ucc.asn.au>
parents: 145
diff changeset
12 PARAMS_FILE = './tempserver.conf'
b32e5a11a4cb few updates, seems to run
Matt Johnston <matt@ucc.asn.au>
parents: 145
diff changeset
13
b32e5a11a4cb few updates, seems to run
Matt Johnston <matt@ucc.asn.au>
parents: 145
diff changeset
14 SENSOR_BASE_DIR = '/sys/devices/w1_bus_master1'
149
d686b111dab4 working better. logging works properly, cleanup fridge.off() happens.
Matt Johnston <matt@ucc.asn.au>
parents: 148
diff changeset
15 FRIDGE_GPIO = '/sys/devices/virtual/gpio/gpio17'
153
0529f3527626 config for sensor IDs
Matt Johnston <matt@ucc.asn.au>
parents: 151
diff changeset
16 WORT_NAME = '28-0000042cf4dd'
0529f3527626 config for sensor IDs
Matt Johnston <matt@ucc.asn.au>
parents: 151
diff changeset
17 FRIDGE_NAME = '28-0000042cccc4'
0529f3527626 config for sensor IDs
Matt Johnston <matt@ucc.asn.au>
parents: 151
diff changeset
18 AMBIENT_NAME = '28-0000042c6dbb'
151
e114b38c8a55 internal temperature sensor
Matt Johnston <matt@ucc.asn.au>
parents: 149
diff changeset
19 INTERNAL_TEMPERATURE = '/sys/class/thermal/thermal_zone0/temp'
160
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
20
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
21 HMAC_KEY = "a key"
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
22 UPDATE_URL = 'https://matt.ucc.asn.au/test/templog/update'
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
23
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
24 try:
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
25 from localconfig import *
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
26 except ImportError:
256505f98c4d uploader works
Matt Johnston <matt@ucc.asn.au>
parents: 153
diff changeset
27 pass