... | ... |
@@ -32,7 +32,8 @@ |
32 | 32 |
# Revision History |
33 | 33 |
# * v20 released 15 Sep 2015 by J L Owrey; first release |
34 | 34 |
# * v21 released 27 Nov 2017 by J L Owrey; bug fixes; updates |
35 |
-# * v22 released 03 Mar 2018 by J L Owrey; improved code readability |
|
35 |
+# * v22 released 03 Mar 2018 by J L Owrey; improved code readability; |
|
36 |
+# improved radmon device offline status handling |
|
36 | 37 |
# |
37 | 38 |
|
38 | 39 |
_MIRROR_SERVER = False |
... | ... |
@@ -50,9 +51,9 @@ _USER = os.environ['USER'] |
50 | 51 |
### DEFAULT WEATHER STATION URL ### |
51 | 52 |
|
52 | 53 |
# ip address of radiation monitoring device |
53 |
-_DEFAULT_RADIATION_MONITOR_URL = '{your radiation monitor device url}' |
|
54 |
+_DEFAULT_RADIATION_MONITOR_URL = '{your radmon device url}' |
|
54 | 55 |
# url if this is a mirror server |
55 |
-_PRIMARY_SERVER_URL = '{your primary server radmon data url}' |
|
56 |
+_PRIMARY_SERVER_URL = '{your primary server weather data url}' |
|
56 | 57 |
|
57 | 58 |
### FILE AND FOLDER LOCATIONS ### |
58 | 59 |
|
... | ... |
@@ -129,15 +130,8 @@ def setOfflineStatus(dData): |
129 | 130 |
if radiationMonitorOnline: |
130 | 131 |
print "%s: radiation monitor offline" % getTimeStamp() |
131 | 132 |
radiationMonitorOnline = False |
132 |
- |
|
133 |
- dData['UTC'] = '' |
|
134 |
- dData['Mode'] = '' |
|
135 |
- dData['uSvPerHr'] = '' |
|
136 |
- dData['CPM'] = '' |
|
137 |
- dData['CPS'] = '' |
|
138 |
- dData['status'] = 'offline' |
|
139 |
- |
|
140 |
- writeOutputDataFile(dData) |
|
133 |
+ if os.path.exists(_OUTPUT_DATA_FILE): |
|
134 |
+ os.remove(_OUTPUT_DATA_FILE) |
|
141 | 135 |
return |
142 | 136 |
##end def |
143 | 137 |
|