update to read from db
This commit is contained in:
@@ -68,27 +68,3 @@ def parse_timestamp(filename):
|
||||
return f"{year}-{month}-{day}T{hour}:{minute}:{second}"
|
||||
|
||||
|
||||
def parse_elapsed_time(time_str):
|
||||
match = re.match(r"^(\d+):(\d{2}):(\d{2})\.(\d+)$", time_str)
|
||||
if not match:
|
||||
return None
|
||||
|
||||
hours, minutes, seconds, fraction = match.groups()
|
||||
return int(hours) * 3600 + int(minutes) * 60 + int(seconds) + float(f"0.{fraction}")
|
||||
|
||||
|
||||
def parse_tput_rssi(line):
|
||||
match = re.search(
|
||||
r"STA(\d+) over angles >> AVG IxChariot TPUT: (\d+) Mbps, AVG DL RSSI: (-?\d+) dBm, AVG UL RSSI: (-?\d+) dBm",
|
||||
line,
|
||||
)
|
||||
if not match:
|
||||
return None
|
||||
|
||||
station, tput, dl_rssi, ul_rssi = match.groups()
|
||||
return {
|
||||
"station": int(station),
|
||||
"tput": int(tput),
|
||||
"dlRssi": int(dl_rssi),
|
||||
"ulRssi": int(ul_rssi),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user