def main(args): # Read in the configuration file config = loadConfig(CONFIG_FILE) # Record some data and extract the bits on-the-fly bits = readRTL(int(config['duration'])) # Read in the most recent state db = Archive() tLast, output = db.getData() # Find the packets and save the output output = parseBitStream(bits, elevation=config['elevation'], inputDataDict=output, verbose=config['verbose']) # Save to the database db.writeData(time.time(), output) # Upload wuUploader(config['ID'], config['PASSWORD'], output, archive=db, includeIndoor=config['includeIndoor'], verbose=config['verbose'])
def main(args): # Validate arguments if len(args) != 1: raise RuntimeError("Invalid number of arguments provided, expected a filename") filename = args[0] # Read in the configuration file config = loadConfig(CONFIG_FILE) # Find the bits in the freshly recorded data and remove the file bits = readRTLFile(filename) # Find the packets output = parseBitStream(bits, elevation=config['elevation'], verbose=True) # Report print " " print generateWeatherReport(output)
def main(args): # Validate arguments if len(args) != 1: raise RuntimeError( "Invalid number of arguments provided, expected a filename") filename = args[0] # Read in the configuration file config = loadConfig(CONFIG_FILE) # Find the bits in the freshly recorded data and remove the file bits = readRTLFile(filename) # Find the packets output = parseBitStream(bits, elevation=config['elevation'], verbose=True) # Report print " " print generateWeatherReport(output)
#!/usr/bin/env python """ Script to check whether any supported sensors can be detected """ from decoder import readRTL from parser import parseBitStream print("Gathering data for 90 seconds") bits = readRTL(90) print("Time's up, decoding the data stream") output=parseBitStream(bits,verbose=True) print(output)