Login | ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/alarming/trunk/Server/daemon.py
(Generate patch)

Comparing trunk/Server/daemon.py (file contents):
Revision 6 by daniel-marschall, Mon Jun 10 17:40:51 2019 UTC vs.
Revision 8 by daniel-marschall, Sun Jul 7 22:02:12 2019 UTC

# Line 186 | Line 186 | function onload() {
186                          print "ALERT {0}, but nobody is listening!".format(server_targets)
187  
188          if pvget(postvars, "action")[0] == "motion_on": # 1.3.6.1.4.1.37476.2.4.1.100
189 +                # TODO: Actually, we should call this API "alarm_on" instead of "motion_on", since we also enable a doorbell checker
190                  print "Motion start"
191                  if config.enable_motion_detect:
192                          os.system(os.path.dirname(os.path.abspath(__file__)) + "/motion/motion_start_safe")
193                  if config.enable_doorbell_listener:
194 <                        g_bellListenerProc = sp.Popen(['python3',os.path.dirname(os.path.abspath(__file__)) + "/doorbell/bell_listener.py"])
194 >                        g_bellListenerProc = sp.Popen([os.path.dirname(os.path.abspath(__file__)) + "/doorbell/bell_listener.py"])
195          if pvget(postvars, "action")[0] == "motion_off": # 1.3.6.1.4.1.37476.2.4.1.101
196 +                # TODO: Actually, we should call this API "alarm_off" instead of "motion_off", since we also disable a doorbell checker
197                  print "Motion stop"
198                  if config.enable_motion_detect:
199                          os.system(os.path.dirname(os.path.abspath(__file__)) + "/motion/motion_stop_safe")

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines