#!./bin/python3 from RFXtrx import PySerialTransport import sys, datetime, os 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))