From: Bernhard Tittelbach Date: Wed, 9 Oct 2013 22:32:50 +0000 (+0000) Subject: --bugs X-Git-Url: https://git.realraum.at/?a=commitdiff_plain;h=565b834fd55e0a145099a728c12493cf26c29362;p=svn42.git --bugs --- diff --git a/go/r3-netstatus/webstatus.go b/go/r3-netstatus/webstatus.go index c3b3f2d..7bd292e 100644 --- a/go/r3-netstatus/webstatus.go +++ b/go/r3-netstatus/webstatus.go @@ -106,7 +106,7 @@ func EventToWeb(ps *pubsub.PubSub) { } spaceapidata.MergeInSensor(spaceapi.MakeTempCSensor(fmt.Sprintf("Temp%d",event.Sensorindex),tempsensorlocation, event.Value)) case r3events.IlluminationSensorUpdate: - spaceapidata.MergeInSensor(spaceapi.MakeIlluminationSensor("Photodiode","MHR","1024V/5V", event.Value)) + spaceapidata.MergeInSensor(spaceapi.MakeIlluminationSensor("Photodiode","HHL","1024V/5V", event.Value)) } } } diff --git a/sensorvalues-to-json-zmq.py b/sensorvalues-to-json-zmq.py index aec3fef..b6cd17c 100755 --- a/sensorvalues-to-json-zmq.py +++ b/sensorvalues-to-json-zmq.py @@ -255,6 +255,17 @@ if __name__ == "__main__": except Exception, e: logging.debug(e) + + for k in set(sensor_store.keys()).difference(set(uwscfg.zmq_subscribe.split(" "))): + del sensor_store[k] # del old sensordata of sensor we do not subscribe to + + for k in sensor_store.keys(): + try: + if len(sensor_store[k][0]) > 1: + sensor_cols_num_[k] = len(sensor_store[k][0]) -1 + except: + pass + while True: try: #Start zmq connection to publish / forward sensor data