summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormanuel <manuel@mausz.at>2021-03-03 12:27:21 +0100
committermanuel <manuel@mausz.at>2021-03-03 12:27:21 +0100
commit92ea621db67b45225e3ded586dd996e79ce20df0 (patch)
treebec90b04ffb15b9fdb10339ceccaf508015ae93a
parentd3dd8913bdf41e38bbc75b1f5dbe7159650ba80b (diff)
downloadarduino-92ea621db67b45225e3ded586dd996e79ce20df0.tar.gz
arduino-92ea621db67b45225e3ded586dd996e79ce20df0.tar.bz2
arduino-92ea621db67b45225e3ded586dd996e79ce20df0.zip
Update martin
-rw-r--r--martin/door/src/hcs200.cpp7
-rw-r--r--martin/door/src/main.cpp3
2 files changed, 9 insertions, 1 deletions
diff --git a/martin/door/src/hcs200.cpp b/martin/door/src/hcs200.cpp
index 661380a..d7e914f 100644
--- a/martin/door/src/hcs200.cpp
+++ b/martin/door/src/hcs200.cpp
@@ -165,7 +165,12 @@ void HCS200_Keycode::print(Print &stream)
165 stream.print("\n"); 165 stream.print("\n");
166} 166}
167 167
168#define PULSE_WIDTH 440 168// pulse width according to chip datasheet
169//#define PULSE_WIDTH 440
170
171// pulse width according to rtl_433 implementation
172// run width: rtl_433 -R 131
173#define PULSE_WIDTH 370
169 174
170inline void HCS200_Keycode::send(bool value, std::function<void(int)> setOutput) 175inline void HCS200_Keycode::send(bool value, std::function<void(int)> setOutput)
171{ 176{
diff --git a/martin/door/src/main.cpp b/martin/door/src/main.cpp
index 6a6eed3..223180e 100644
--- a/martin/door/src/main.cpp
+++ b/martin/door/src/main.cpp
@@ -34,6 +34,9 @@ CC1101 radio(D0 /* GDO0 */, D2 /* GDO2 */, D8 /* SS */);
34#define PIN_HCS200_ENABLE D3 34#define PIN_HCS200_ENABLE D3
35#define PIN_HCS200_DATA D1 35#define PIN_HCS200_DATA D1
36//#define HCS200_TEST 36//#define HCS200_TEST
37#if defined(HCS200_TEST)
38#warning HCS200 testmode is enabled!
39#endif
37HCS200 hcs200; 40HCS200 hcs200;
38 41
39const int ping_delay = 60000; 42const int ping_delay = 60000;