diff options
| author | Luke Hoersten <[email protected]> | 2018-01-30 09:22:57 -0600 |
|---|---|---|
| committer | Luke Hoersten <[email protected]> | 2018-01-30 09:22:57 -0600 |
| commit | 6fb4e588335916350d002bf7296644017ad37c7b (patch) | |
| tree | 0926dc7205f3323bf088b0879ba15906e08067b8 | |
| parent | 2b578ce9283a8d2b7d57a5e220d047f51ef917e1 (diff) | |
Added doorbell value debug logging.
| -rwxr-xr-x | src/doord.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/doord.py b/src/doord.py index 4cde487..400c11d 100755 --- a/src/doord.py +++ b/src/doord.py @@ -42,6 +42,9 @@ def read_doorbell(thread_local): analog_value = automationhat.analog.one.read() doorbell_on_state = 6.0 < analog_value and analog_value < 6.3 + if doorbell_on_state: + print("doorbell analog value: {}".format(analog_value)) + if doorbell_on_state != thread_local.doorbell_on_state: thread_local.doorbell_on_state = doorbell_on_state print("doorbell_on") if doorbell_on_state else print("doorbell_off") |
