summaryrefslogtreecommitdiff
path: root/v1/receive-test.py
diff options
context:
space:
mode:
authorpks <pks@pks.rocks>2021-05-01 06:17:55 +0200
committerpks <pks@pks.rocks>2021-05-01 06:17:55 +0200
commitf461190e22a97bde985b067ce01c4ed9c74f7e62 (patch)
tree0c2c48d1933765f83d083241df2dd74c6603f2bc /v1/receive-test.py
parent63fbf0f3aadb4b6d037a8164b501fe836d9c361d (diff)
v1
Diffstat (limited to 'v1/receive-test.py')
-rwxr-xr-xv1/receive-test.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/v1/receive-test.py b/v1/receive-test.py
new file mode 100755
index 0000000..c1d9783
--- /dev/null
+++ b/v1/receive-test.py
@@ -0,0 +1,15 @@
+#!/usr/bin/env python3
+
+from RFXtrx import PySerialTransport
+import sys, datetime, os
+
+
+if __name__ == "__main__":
+ transport = PySerialTransport('/dev/ttyUSB0')
+ transport.reset()
+ while True:
+ if os.path.isfile('./stop'):
+ break
+ timestamp = datetime.datetime.timestamp(datetime.datetime.now())
+ recv = transport.receive_blocking()
+ print(str(recv))